Thanks again Richard 
Code:
'======= VARIABLES ================================================================================
InString VAR BYTE[3]
LED VAR RC2
Counter VAR BYTE
Blinks VAR BYTE
'======= INITIALIZE VARIABLES =====================================================================
InString[0] = 0
InString[1] = 0
InString[2] = 0
LED = 0
Counter = 0
Blinks = 0
'======= PROGRAM ==================================================================================
' Wait for strings:
' *AAA# = 1 blink
' *BBB# = 2 blinks
' *CCC# = 3 blinks
START:
Blinks = 0
DEBUGIN 1000,START,[WAIT("*"), STR InString\3\35] ' InString starts with "*" and ends with "#"
if InString[0] = 65 then
if InString[1] = 65 then
if InString[2] = 65 then
Blinks = 1
ENDIF
ENDIF
ENDIF
if InString[0] = 66 then
if InString[1] = 66 then
if InString[2] = 66 then
Blinks = 2
ENDIF
ENDIF
ENDIF
if InString[0] = 67 then
if InString[1] = 67 then
if InString[2] = 67 then
Blinks = 3
ENDIF
ENDIF
ENDIF
BLINK:
FOR Counter = 1 to Blinks
LED = 1
PAUSE 500
LED = 0
PAUSE 500
NEXT Counter
GOTO START
END
Bookmarks