so the code will look like:
will it repeat main: if ACK\r doesnt appear?.. like when it recieves NCK\rDim tc_mx As Byte
Dim tc_my As Byte
Dim tc_x1 As Byte
Dim tc_y1 As Byte
Dim tc_x2 As Byte
Dim tc_y2 As Byte
Dim tc_p0 As Byte
Dim tc_c0 As Byte
main:
HSerOut ["TC",13]
HSerIn 500, main,[WAIT("ACK\r"), SKIP 1, tc_mx, tc_my, tc_x1, tc_y1, tc_x2, tc_y2, tc_p0, tc_c0, SKIP 2]
and how about #1?
if i enter like HSEROUT ["AG 0",13] the cmucam4 will return either ACK\r or NCK\r
Dim B1 As Byte
test_ag:
HSerOut ["ag 0",13]
HSerIn [B1]
'if the data received is NCK\r it will repeat test_ag:
'while if its ACK\r it will move to the next part of the code




Bookmarks