Hi, I'm trying to create an application that sends commands over the serial port. A command in my case is a short string (1 or 2 characters followed by a \n). I wrote code to do this that calls SerOpen(...), SerSend(...), SerSendWait(...), SerClose(...) in that order. The problem I'm having is that the last character sent (the \n in the case described above) is not sent, and instead a (random(?)) character is.
Some of my commands have responses, and as a result I don't always send, wait & close instantly. For these commands I call SerReceive after the wait (before the close). They seem to function correctly. Only for the commands that send, wait and close one after the other do I have problems.
I have ErrFatalDisplayIf's after all of the calls to check the return code so I know none of the functions are failing (in particular, I thought SerSendWait might have been timing out). The code functions as I'd expect it to (i.e. it works) in the Palm OS Emulator but it does not work on my m100.
Any help is much appreciated; please Cc / email replies to firstname.lastname@example.org.