Shop OBEX P1 Docs P2 Docs Learn Events
does serin reset? — Parallax Forums

does serin reset?

ArchiverArchiver Posts: 46,084
edited 2004-05-30 16:40 in General Discussion
hi!

what is wrong with this program?
when i start it it reads the temp(tc) etc.
but when i want to tell the stamp to light a led it start flashing..
i want the led to light until when i press light button and turned
of as i tell and the same time read the tc,ljus etc.



here is a part of the program
SEROUT
16,16780,tc.HIGHBYTE,tc.LOWBYTE,rct.HIGHBYTE,rct.LOWBYTE,ljus.HIGHBYT
E,ljus.LOWBYTE,temp.HIGHBYTE,temp.LOWBYTE]

SERIN 16,16780,1000,starta, [noparse][[/noparse]WAIT(255), PinState]

starta:
pinstate=pinstate
IF pinstate=1 THEN gohigh
IF pinstate=0 THEN golow


PAUSE 1000

GOTO start

gohigh:
HIGH 8
GOTO start


golow:
LOW 8
GOTO start
Sign In or Register to comment.