Receive into pic2 as an array, then forward the array. ?
Receive into pic2 as an array, then forward the array. ?
Dave
Always wear safety glasses while programming.
wait, sorry. My enter key is messing up, wasn't finished
Last edited by Muller; - 2nd September 2008 at 22:26.
To receive an array you need to HSERIN something like this
Code:[WAIT("A"),STR NUMS\8]
Dave
Always wear safety glasses while programming.
sorry, again.. I wish I could delete the messages. My enter key, instead of jumping a line, sends the message earlier. sorry![]()
And when I want to send it, why do I get that error?
ERROR: Macro HSEROUTSTRN?W not found in macro file.
Isn't <code> hserout [STR nums\8] </code> right?
We are passing each other
Can you post the whole code. Something is missing.
Dave
Always wear safety glasses while programming.
OK, I found out what I was doing wrong.. THe array I was trying to send was a word, not a byte.. Sorry..
Thats what was missing![]()
Dave
Always wear safety glasses while programming.
OK, I tried that Dave. With bad results, here's my code:
Pic2 code
<code>
RXIn:
if RCIF then
@ INT_DISABLE TMR0_INT
for index = 0 to 3
hserin [serialdata]
dataA(index) = serialdata
next index
usbservice
gosub dousbout
@ INT_ENABLE TMR0_INT
endif
@ INT_RETURN
</code>
pic1 code:
<code>
hserout [var1(0), var1(1), var1(2), var1(3)] 'it only has 4 bytes now
</code>
I tried:
<code>
hserout [STR var1\4]
</code>
but it gave me an error (ERROR: Macro HSEROUTSTRN?W not found in macro file.)
Last edited by Muller; - 2nd September 2008 at 22:31.
Bookmarks