|
|
View previous topic :: View next topic |
Author |
Message |
Pontus Guest
|
RS485 & STISR.C, SISR.C |
Posted: Thu Nov 13, 2008 2:34 pm |
|
|
Hi
I've found a very useful SISR.C and STISR.C (including bkbhit(),bgetc() functions etc...) as examples for sending and receiving buffers over UART in my compiler (4.057), and I've already used them to write a protocol for sending data (2 bytes ) between two PICs over RS232.
I'm looking for the same thing but with RS485. Is it possible to use those routines with just a little modification ?
thanks. |
|
|
Ttelmah Guest
|
|
Posted: Fri Nov 14, 2008 3:23 am |
|
|
No modification at all....
The chip, does not develop either RS232, or RS485. It generates TTL async serial, which can be made into RS232, by adding a transceiver like the MAX232, or into RS485, by adding a MAX485. It is a 'pity', that CCS elected to call their routines and setup 'RS232'.
The code used is identical for RS232, or RS485, except for adding things like direction control to the RS485 transceiver, if operating in half-duplex mode if needed.
Best Wishes |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|