Page 1 of 1
When I send color map I get ACKNCK, not just ACK
Posted:
Thu Mar 01, 2007 11:06 pm
by catalin_cluj
Somehow this is not shown in the PC application provided (AVRcamVIEW), but it shows in mine...
The AVRcam seems to accept the color map, but... is this a "side effect"?
Thanks,
Cat
Posted:
Tue Mar 06, 2007 6:23 am
by johno
Hmm...in the thread you posted in the AVRcamVIEW forum, it sounds like the AVRcamVIEW app is sending:
<16-bytes of colorMap>\r\n
Yes, the first portion of the command (<colorMap><\r>) would cause a successful programming of the colorMap, and the subsequent \n would be read as an invalid command and a NCK would be sent.
I don't recall seeing AVRcamVIEW doing this in the past, but it is possible. I'll ping the author of the app and see what his thoughts are.
The proper way to send a color map is <16-bytes of colorMap>\r, as shown in the User's Manual as well as UIMgr.c (remember, going to the source code is ALWAYS the definitive answer...and thus the beauty of open-source).
"\r\n"
Posted:
Tue Mar 06, 2007 11:07 am
by catalin_cluj
Thanks John,
My application (I just realized) may send "\r\r" (because I made the line-end to be '\r' and I may also include a '\r' with the string... I'll have to fix that, but the supplied AVRcamVIEW does send "\r\n"...
but MORE IMPORTANTLY: when it's doing nothing, does the AVRcam code "sleep" somewhere, or does it keep looping the Exec_run loop?
Thanks,
Cat
Posted:
Tue Mar 06, 2007 5:03 pm
by johno
The AVRcam just loops in Exec_run() waiting for events to be generated by the system. It does this forever.
Remember, use the source
Executive.c shows the details.