2
\$\begingroup\$

In my application, I need to use a common line shared between two peripherals, I have to indicate to the devices whenever the bus is free or not, hence I can't have push-pull output where the output is either 0 or 1 , as these states are generally used for data transmission.

Instead, I would prefer to have an open-drain scenario, where the output "floats", to indicate to the device that the bus is free.

Now to achieve this, I want to use a transmission gate, where the third state(open) is used by controlling the enable pin if enable is on (the normal 2- state logic, 0 or 1 where input flows to output), else the output pin floats.

Now my question is if this setup is similar to the way 3 state logic is used in microcontrollers/microprocessors, where an internal pull-up resistor controls the logic of the output pin if it is different then in what way does it differ?

Also, have I missed something? Do I have to read anything more to complete my understanding?

The Line is driven by a totem pole output, where only logic 1 (5 V), and Logic 0 (0V), signals are driven.

\$\endgroup\$
3
  • 1
    \$\begingroup\$ It is difficult to tell what is being asked here, especially without a schematic. What happens to the line when nothing is driving it? If it will be pulled fully high or low, then how can you distinguish between that and actively pulled high or low? If you intend to float it in the middle then you'll need a window comparator to detect that case, but you have to think about every transition going thru that voltage range. \$\endgroup\$ Commented May 6, 2013 at 12:08
  • \$\begingroup\$ @OlinLathrop I apologize for the question not being clear, as my knowledge level on the subject of the question is not upto mark, however i've edited the question and added a detail which may slightly improve the question \$\endgroup\$ Commented May 6, 2013 at 13:40
  • \$\begingroup\$ Open drain buses do not indicate to any device that they are free! Devices must detect a conflict and resolve it. Whenever a 1 is being transmitted on the bus, that is done by releasing it (not pulling down the resistor). But the bus is not free whenever a 1 is being transmitted. \$\endgroup\$
    – Kaz
    Commented May 6, 2013 at 19:31

2 Answers 2

4
\$\begingroup\$

The question seems rather confused in several respects...

1) It is unclear whether you want to implement 3-state logic or an open-drain interconnection.

In the former, the driving device DOES use a push-pull output, driving 0 or 1 onto the bus. The other devices, meanwhile, must abstain from driving until some separate system signals that it is their turn.

In the latter, the bus is always pulled to '1' by a resistor, and any device may pull it to '0'. In this case, there is no harm done if several devices drive the bus simultaneously, though any messages may be corrupted.

2) You say you want a "floating" bus to indicate that the bus is free. In neither case is this normally possible (there is no logic primitive that can detect that a bus is floating). This is why in tri-state logic there must be another system (bus arbitration logic) to keep track of who has the bus, and give each device a turn.

Now as to the specific question of transmission gates : either of these systems can be trivially implemented using transmission gates, though there are other and sometimes better ways.

Tri-state logic can be implemented using a normal push-pull (totem-pole) output, and a transmission gate between the push-pull output and the bus. The bus arbiter simply switches the transmission gate on or off. It is often more economical to turn off both transistors in the push-pull output instead.

Open drain logic can be implemented with a transmission gate by simply connecting one side of it to ground, and the other to the bus. Now simply turn it on to pull the bus low.

\$\endgroup\$
7
  • \$\begingroup\$ i apologize that my question is not clear , because i am weak in this area, hence my question reflects my lack of clarity, +1 for giving a complete answer to an incomplete question.............One thing is i am certain that i want to implement 3-state logic....I have a question ,if "float" state logic can't be interpreted , then what is the purpose of it , and where does it have its applications \$\endgroup\$ Commented May 6, 2013 at 13:33
  • \$\begingroup\$ Its purpose is simply to disconnect a driver to allow other devices to drive a shared bus! \$\endgroup\$
    – user16324
    Commented May 6, 2013 at 13:36
  • \$\begingroup\$ Does the float state force the driver to disconnect , or the state changes to "float" , when the driver disconnects of its own accord ? \$\endgroup\$ Commented May 6, 2013 at 13:41
  • \$\begingroup\$ Turning off the transmission gate disconnects the driver. "Float" or "high impedance" or "Z" are just names given to this condition. It isn't really a separate state, if you observe the voltage on the bus you might see '0' or '1' (if another driver is active) or any voltage in between. \$\endgroup\$
    – user16324
    Commented May 6, 2013 at 13:46
  • 1
    \$\begingroup\$ what else would you call it? Actually you could call it a separate state of the driver circuit - i.e. disconnected - but it is not an observable state of the bus. \$\endgroup\$
    – user16324
    Commented May 6, 2013 at 13:51
3
\$\begingroup\$

Have a look at IIC communications between chips here. I think this will help complete your understanding. It's an industry standard way of implementing a multi-peripheral system using common lines such as clock and data. Open-drain outputs are used with pull-up resistors to prevent power-issue problems when one device wants to drive low whilst the other is driving high.

\$\endgroup\$
2
  • \$\begingroup\$ +1 for your response, but was looking specifically for info on transmission gates \$\endgroup\$ Commented May 6, 2013 at 12:35
  • \$\begingroup\$ @BarathBushan transmission gates can be used as switches therefore they have an "open circuit" impedance which can be used to inhibit them and allow other gates to drive a line just like in a multiplexer. \$\endgroup\$
    – Andy aka
    Commented May 6, 2013 at 12:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.