A little history to get you started...
http://www.picbasic.co.uk/forum/show...highlight=idle
let us know if the above helps.
A little history to get you started...
http://www.picbasic.co.uk/forum/show...highlight=idle
let us know if the above helps.
Dave
Always wear safety glasses while programming.
Hi Dave
thanks for the history lesson re serin ..very informative ...
The posting was a little confusing in that (unless I missed it!) it is not clear on how to get the port to dile low IDLE high or IDLE low.
Is is as simple as somthing like
portX.Y low or high after the serin line ?
Note that I am not sending anything over RF yet ... the two PIC's are just wired together at this stage.
Should I rather try DEBUG or serin/out 2 ?
Do they suffer from the same issues?
I would like to make sure I get everything ready before I attach the wireless RF and TX , maximizing both power and rate on the TX/RX pairs, other wise why bother ...not so ?
Any further help would be much appreciated :-)
Kind regards
Dennis
For PIC to PIC Debug is not the way. SERIN is good for basic stuff. SERIN2 has a whole lot more options and uses the same syntax as HSERIN when you need it. The nice thing about the SERIN/2 is it can be set for TRUE or INVERTED while HSERIN is TRUE only requiring an inverter to connect to things like a PC, but that is a minor thing with the other benifits of hardware serial.
http://www.melabs.com/resources/samples.htm
Scroll down to the ser2mod examples for...examples....
When it comes time to idle low or high that can be done with a resistor 100K. Or in your code.
Dave
Always wear safety glasses while programming.
SERIN2
or
HWSER right ?
You mentioned being able to set the IDLE in software if I am going to be using SERIN...
That's what I was asking in the last post :-)
In the post you pointed me to it mentions the issues/problems with SERIN and to set it IDLE ...
SO my question is how do you set the IDLE using software ?
Is there a document regarding the IDLE setting methods ?
Kind regards
Dennis
Normally the mode takes care of the idle state
http://www.picbasic.co.uk/forum/show...92&postcount=7
Dave
Always wear safety glasses while programming.
I hate to sound like a broken record - but... Always use the hardware serial port if your device has one. You will be glad you did.
Charles Linquist
Thanks Dave and Charles :-)
But where do I start with hardware ports?
I got the impression reading through the forums that software serin/out and serin2/serout2 and debug would be easier to play around with.
I ssetting up the hardware option just as easy ?
I also read somewhere that serin needs to be setup to look for something first before it starts accepting data ? Is this why I after one keypress, nothing else appears on the LCD ?
Is there a some code I could use just to test the TX/RX function between 2 PIC's using wires ( see my diagram in earlier posts) , once I have that working I can then move onto TX and RX using wireless
Something like setup PIC A to send a string or a byte to PIC B and then have PIC B send the same byte to hyperterminal(pc).
Could I use serin2 first then serout (not serout2) to send the string or byte to hyperterminal(pc).
Have I made the correct choice for send and receive ports ..on both pics PORTC.6 and PORTC.7
Any help or advice would really be appreciated.
Kind regards
Dennis
Bookmarks