using the folo\lowing chip etc:
#chip 16F916, 4 'mhz
#config OSC=INTOSC, MCLRE=off, WDT=off
#mem 256 'Chip has 256 bytes
dir portc.0 in 'serial
#define RecAHigh portc.0 off
#define RecAlow portc.0 on
Initser 1,r2400, 1+waitforstart, 8, 1, none, invert
i need to have my program running including wait times, but have the serReceive set so that if i send it a command from the pc that it gets it right away and then goes back to where it was when it got interrupted, is this possible? and how do I set that up
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
using the folo\lowing chip etc:
#chip 16F916, 4 'mhz
#config OSC=INTOSC, MCLRE=off, WDT=off
#mem 256 'Chip has 256 bytes
dir portc.0 in 'serial
#define RecAHigh portc.0 off
#define RecAlow portc.0 on
Initser 1,r2400, 1+waitforstart, 8, 1, none, invert
i need to have my program running including wait times, but have the serReceive set so that if i send it a command from the pc that it gets it right away and then goes back to where it was when it got interrupted, is this possible? and how do I set that up
i think you should use harware usart and enable receive interrupt this way:
On Interrupt UsartRX1Ready call your_sub
Sub your_sub
do_somewthing
End Sub
So i just add this to where in my program?
and is that wording right?
On Interrupt UsartRX1Ready call serial-in
Sub serial-in
SerReceive 1, temp
SerReceive 1, temp2
EPWrite temp, temp2
End Sub
do i need to defiene rx1? or anything else?