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

1-wire RS232
Goto page Previous  1, 2
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
SherpaDoug



Joined: 07 Sep 2003
Posts: 1640
Location: Cape Cod Mass USA

View user's profile Send private message

PostPosted: Fri Dec 28, 2007 1:35 pm     Reply with quote

RS232 driver chips don't usually support the tri-state output so you have to do something yourself to let multiple slaves in parallel talk to a singe master RS232 input. Often RS232 networks are daisy-chain instead of parallel for this reason. But that means one dead node kills the whole network.
_________________
The search for better is endless. Instead simply find very good and get the job done.
gjs_rsdi



Joined: 06 Feb 2006
Posts: 476
Location: Bali

View user's profile Send private message Send e-mail

1 wire rs232
PostPosted: Fri Dec 28, 2007 2:40 pm     Reply with quote

max have rs232 with tx enable
http://www.maxim-ic.com/quick_view2.cfm/qv_pk/1798
alternatively, analog rail to rail switches like DG411/DG412/DG413 to handle the rs232 negative signal
joseph
RLScott



Joined: 10 Jul 2007
Posts: 465

View user's profile Send private message

PostPosted: Sat Dec 29, 2007 6:53 am     Reply with quote

apl01 wrote:
...What do you mean by passive pull up system?


As others have pointed out, you need to have a resistor that connects the bus to +Vcc so that the bus does not float randomly when nothing is being transmitted.

Quote:
I was thinking of making both master and slaves always in the receiving state by making the Tx pins as inputs i.e input(Tx). When the slave or master wants to send data the Tx pin becomes active sends data then resorts back to an input. Being new to comms would this work?


I don't know. For this to work you would need to force the Tx pin to an input. TRIS settings may not be enough to do this. There are cases where the enabling of a peripheral overrides the TRIS settings. Looking at one of the PIC datasheets, I see only the SPEN bit being used to set the input/output state of the Tx pin. The TXEN bit does not seem to be involved in the input vs. output decision. It may be that you would have to disable the entire serial port (Tx and Rx) to force Tx to be an input, which would, of course, defeat the purpose. In any case, it might be safer not to depend on this ability. Instead, use an external transisitor to convert the Tx output into an open collector/drain. If you do this in the most straightforward way, it will result in a logic inversion. Therefore you should include another inverter so that the idle state on the Tx pin (which is high) corresponds to the transisitor being in the "off" state.

Robert Scott
Real-Time Specialties
Embedded Systems Consulting
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page Previous  1, 2
Page 2 of 2

 
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