PDA

View Full Version : Hserin small question



Filproject
- 5th November 2013, 12:18
Hello,

Just a small question concerning the Hserin command. Could not find the answer to my question on the forum or the manual.

If you use the Hserin with the STR command : Hserin [STR received_text\8\10]

It stoppes receiving when all 8 places of the array are filled or when a LF (10) takes place. Now is my question lets say only 6 characters are send followed by a LF. The LF will end de Hserin command BUT is this LF(10) also stored in the array or not(on location received_text[6]? In other words is the ending character also stored when it is encountered or not?

Luckyborg
- 6th November 2013, 23:21
I am almost sure it does not store the line feed, but it should be easy enough to check. Just send 6 characters then a line feed and check received_text[6]. if it = 10 then blink an LED or transmit something.

I mostly use the serin2 command and it does not store the end character.

David

Filproject
- 8th November 2013, 17:43
Okay, thanks for the info. Seems a simple question but funny enough most people don't exactly know the answer. Maybe somthing to add in the manual :-)