Are you even allowed to reply to your own thread. Seems like talking to yourself..Oh well....
Tried successfully to make MAX chars to word, although all you can have 500, 1000 or 2000 array depending on ram (I think),
Code:;**************************************************************** ;* ARRAYREAD : Read char from array * ;* * ;* Input : R5 = pointer to next char in array * ;* : R6 = number of chars left in array (timeout) * ;* Output : W * ;* * ;* Notes : C clear if timed out. * ;**************************************************************** ifdef ARRAYREADTO_USED LIST ARRAYREADTO movf R6, F ; Check for no chars left in array bcf STATUS, C ; Preset for timed out (C clear) btfsc STATUS, Z movf R6+1, F bz arrayreaddone ; No chars left movf R6, F ; Set "Z" if LOW "Reg" == 0 btfsc STATUS, Z decf R6+1, F ; If Low byte is Zero, Decrement High decf R6, F ; Count down the characters left and fall through to ARRAYREAD NOLIST ARRAYREAD_USED = 1 endifDonCode:arrayread arr1,500,done,[wait("123qwe")]
(does anyone see redundent code ?)




Bookmarks