Page 1 of 1

RS-232 returns 0xFF

Posted: Mon Feb 25, 2008 4:02 pm
by BITIT
Hi

I have a problem I would like to know if there where an easy way to avoid.

When I in simulation mode in Flowcode put in let's say 0x55, it receives it
okay and puts in down in a variable I have made. But the second time the
loop runs, and I have not putted a new byte in the "characters in queue", it
returns 0xFF.

Actually it returns 0xFF all the time You don't put anything in the “characters
in queue”.

It would be nice if it was possible to say that it should only return bytes
to my variable, if there is new data in RCREG from the external connection to the
RS-232.

\BITIT

Re: RS-232 returns 0xFF

Posted: Mon Feb 25, 2008 4:07 pm
by Benj
Hello

A return value of 255 means there is no data available. This means that you cannot send a value of 255 over the RS232 connection.

A typical usage of this would be to read in a byte and if the byte is not 255 then you know you have received a new byte of data.

Re: RS-232 returns 0xFF

Posted: Tue Feb 26, 2008 8:03 am
by BITIT
Hi Ben

Thanks for a quick reply !

\BITIT