PDA

View Full Version : Serial Question



penelopepug
- 20th January 2006, 01:57
Hi. Can someone please tell me the operational difference between serial setting of for example N9600 compared to ON9600? I understand that "ON9600" is meant for use on an open collector port but how would it operate differently than N9600?

Dave
- 20th January 2006, 12:02
penelopepug, The use of "open collector" circuits is for "ORING" other devices attached to the bus. The bus would have a passive pullup resistor to source the current required to drive the bus high. That way any device on the bus could pull it low by an open collector transistor or fet there by sending the signal to all devices that are listening. On a bipolar driven bus each of the devices will "sink or source" current at any time so you can have only 1 device in this mode, otherwise you would have bus contention meaning 1 device would be "sourcing" current and 1 device would be "sinking" current at the same time. HTH

Dave Purola,
N8NTA

penelopepug
- 20th January 2006, 12:46
Thanks Dave. I understand the use of an open collector output however what I do not understand is if for example; If I use Porta.4 of a PIC16F877 as my serial output, since it is an open collector output, how would setting the baud to ON1200 differ from N9600? A pull-up is required on the open collector so would N9600 not act exactly the same as ON9600? What does the open collector designation "O" do?

keithdoxey
- 20th January 2006, 14:43
Just guessing that instead of the pin having the two states

OUTPUT HIGH
OUTPUT LOW

it achieves Open Collector functionality by having the two states

INPUT (high impedance so effectively open collector)
OUTPUT LOW

Regards

penelopepug
- 20th January 2006, 16:23
Keithdoxy, you may be right! That's interesting because what you suggest says that ON1200 may instantly change the pin to an input when the bit needs to be high (1) and then changes back to an output to go low (0) in sending the bit stream. Therefore emulating an open collector via the input state when a high (1) is needed. That would help me out because in some programs (using N1200 for example) I have been making the pin an input after sending serial data out because of parallel serial lines. The "O" may take care of that at a bit level.