CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

RS485 & STISR.C, SISR.C

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Pontus
Guest







RS485 & STISR.C, SISR.C
PostPosted: Thu Nov 13, 2008 2:34 pm     Reply with quote

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







PostPosted: Fri Nov 14, 2008 3:23 am     Reply with quote

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
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
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