I'm a bit confused ;-(
I want to do some background serial in on a 40X1 (16MHz resonator) receiving from a PC, so do I:
1) Use HSERSETUP B_19200_16, %00000001
2) Connect tx on my PC to pin 26 (In c7/Out c7/ser rx)..
- ...via a MAX232 to get the polarity correct
3) Either use SETINTFLANGS %1000000, %10000000 to go to my interrupt routine every time a character is received (and what happens if they arrive really, really fast?)..
-...or check the hserinflag at an appropriate point in my code (and how do I check it?)
Is there any example code around that puts all this together into a simple, but not too simple, snippet from a real application?
TIA, Martin
I want to do some background serial in on a 40X1 (16MHz resonator) receiving from a PC, so do I:
1) Use HSERSETUP B_19200_16, %00000001
2) Connect tx on my PC to pin 26 (In c7/Out c7/ser rx)..
- ...via a MAX232 to get the polarity correct
3) Either use SETINTFLANGS %1000000, %10000000 to go to my interrupt routine every time a character is received (and what happens if they arrive really, really fast?)..
-...or check the hserinflag at an appropriate point in my code (and how do I check it?)
Is there any example code around that puts all this together into a simple, but not too simple, snippet from a real application?
TIA, Martin