Hi,
Since your IF-THEN statements are actually GOTOs (if evaluated true) all you need to do is add GOSUB (or GOTO) WRONG after the three IF statements.Now the WRONG subroutine will only execute if none of the three IF statements evalutate true.Code:IF Serial[1]=$15 AND Serial[2]=$D3 AND Serial[3]=$7D AND Serial[4]=$16 AND Serial[5]=$00 AND Serial[6]=$00 THEN correct1 '<----This will GOTO correct1 IF Serial[1]=$68 AND Serial[2]=$36 AND Serial[3]=$4F AND Serial[4]=$17 AND Serial[5]=$00 AND Serial[6]=$00 THEN correct2 IF Serial[1]=$1E AND Serial[2]=$1A AND Serial[3]=$2C AND Serial[4]=$17 AND Serial[5]=$00 AND Serial[6]=$00 THEN correct3 GOSUB WRONG GOTO mainloop
/Henrik.






Bookmarks