Shop OBEX P1 Docs P2 Docs Learn Events
BS2SX and STAMPmem — Parallax Forums

BS2SX and STAMPmem

ArchiverArchiver Posts: 46,084
edited 2001-10-19 20:03 in General Discussion
Hello,

I am looking some help..

Actually I have an aplication where using BS2SX, read data from
STAMPMEM.

Look at the lines below. In the BASIC PROGRAM when remark the
line SLEEP 1, the program transmit wrong data.

Using the SLEEP instruction work well, but the time consumed to
read the entire STAMPMEM is too long.

I will appreciate you help.

Thank you.
JL


Read_Access_Char: ' Cmd = 5 Get IDMMDDHHMM
SEROUT RXmem,N9600T,[noparse][[/noparse]1,Addr.HighByte,Addr.LowByte,5] ' position
SERIN RXmem,N9600T,[noparse][[/noparse]STR SerString\5] ' Get data
SEROUT TXpc,N9600,[noparse][[/noparse]STR SerString\5] ' Send to PC


A$ = "" <-- clear te receiver variable
WHILE LEN(A$)= "" <-- while no data is received
PRINT #1, B$ <-- send command to stamp (Cmd = 5)
A$=INPUT$(LOC(1),#1) <-- waiting the input buffer data
SLEEP 1 <-- sleep 1 second
WEND
Sign In or Register to comment.