This might get you started.
Read all data from the PC into an array in the PIC.
Code:
[WAIT("?"),STR NUMS\8]
The above will wait for "?" (could be whatever you want) and the next part will put the rest of the data in an array that has 8 places.
The array will start at 0, so if you wrote it out it would look like this:
NUMS[0]
NUMS[1]
NUMS[2]
NUMS[3]
NUMS[4]
NUMS[5]
NUMS[6]
NUMS[7]
Now you can make each part a variable that is a bit easier to work with:
X1 = NUMS[0]
X2 = NUMS[1]
X3 = NUMS[2]
X4 = NUMS[3]
X5 = NUMS[4]
X6 = NUMS[5]
X7 = NUMS[6]
X8 = NUMS[7]
Now lets say X1 is equal to 1 and you want to start display at line 1 position 2.
Code:
LCDOUT $FE, $80 + X1
$80 is line 1 position 1. (refer to the manual for more)
Now to display some of the other data:
Code:
LCDOUT $FE,$80 + X1,X2,X3,X4
X2 = D
X3 = O
X4 = G
Something like that maybe.
Bookmarks