The BS1 code:
SERIN Rx, T2400,($0A)
SERIN Rx, T2400, tag0, tag1, tag2, tag3, tag4
SERIN RX, T2400, tag5, tag6, tag7, tag8, tag9
I read through the datasheet and here is how I would do it in PICBasic:
tag var BYTE[10] ' Creates a byte array of 10 bytes
SERIN Rx, N2400,[WAIT ($0A),STR tag\10\$0D]
The above will wait for $0A then recieve either 10 bytes of data or stop once it recieves $0D, which ever comes first.
This should work great and same you tons of code space. Enjoy.
Bookmarks