Tri state buffer and Bus Questions

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
Hi all,

I have a question please. If we have a couple of registers say, connected to a bus, and each register is tri stated, only one of them active at a time. And at each positive clock edge, the active ones changes, The question is, will a Short happen at any time ?

Because to my mind, when two buffers are changing, that is, one becoming active and the other inactive, there must be a small moment when both are active, and so will a short happen there?

Thanks a lot!
 

Deleted member 115935

Joined Dec 31, 1969
0
technically, you are correct.

But

in the real world, No problem.

For a start, the on and off timings on most / all devices are different, so the buffer turns off faster than on.
So if both buffers are the same type, the action is limited or eliminated.

Also the switch over time is fast, the time when one could be on and the other on , is short.
The inductance / capacitance of the trace between the pins means limits seriously the current that can flow in such a short time to near to zero.

Its the heating of the output drivers that is the concern, and again as the time of clash is very small, the heating effect is also small and the devices are designed to cope.

I have seen in VERY conservative designs, series output resistors used on each device, of the order of 22 ohms.
this adds to the output time, which you will have to calculate / measure and build into your bus timing,
and does make a nice termination, to minimise ringing / over under shoot problems,

Some tri state devices with high drive capabilities designed for bus driving have these resistors built into them
 

RichardO

Joined May 4, 2013
2,270
Looking at the data sheet I have attached you will see that the output enable time is the same as the output enable time. This says to me that there _will_ be a time where both buffers are on at the same time. And, yes, this is very bad. When both buffers are on at the same time there is a momentary short across the power supply. This can cause a lot of power supply noise. In the extreme case the noise will cause signals to be corrupted causing a circuit malfunction.

Note that the short is not a zer0-ohm short and is for a very short period of time so the buffers will not be damaged.

Good circuit design dictates that there be a time period when all buffers are in the tri-state condition when switching between drivers on a bus.
 

Attachments

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
technically, you are correct.

But

in the real world, No problem.

For a start, the on and off timings on most / all devices are different, so the buffer turns off faster than on.
So if both buffers are the same type, the action is limited or eliminated.

Also the switch over time is fast, the time when one could be on and the other on , is short.
The inductance / capacitance of the trace between the pins means limits seriously the current that can flow in such a short time to near to zero.

Its the heating of the output drivers that is the concern, and again as the time of clash is very small, the heating effect is also small and the devices are designed to cope.

I have seen in VERY conservative designs, series output resistors used on each device, of the order of 22 ohms.
this adds to the output time, which you will have to calculate / measure and build into your bus timing,
and does make a nice termination, to minimise ringing / over under shoot problems,

Some tri state devices with high drive capabilities designed for bus driving have these resistors built into them

Thank you both for the complete replies.

I am building an 8bit computer using 74HC series of chips, and all my registers are connected to the data bus by tristate buffers, and this is why I am concerned.

But as per your reply, I shouldnt be concerned then. Will it probably work fine ? There are so many devices connected to my bus that it would be a nightmare to add resistors to all of those.

However, only around 2 registers will be on at any time. So the clash will be between only 2 of them at a time if at all.

I am a bit worried :(
 

Deleted member 115935

Joined Dec 31, 1969
0
One note.

you ARE using good decoupling ?

Driving a bus with more than two or three chips , gives a lovely capacitance.
when you drive that capacitance , your moving a lot of charge.

So the power supplies take a heck of a kick on every switch high / low.

I've done a few processor designs in an FPGA, good luck with real gates.
 

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
One note.

you ARE using good decoupling ?

Driving a bus with more than two or three chips , gives a lovely capacitance.
when you drive that capacitance , your moving a lot of charge.

So the power supplies take a heck of a kick on every switch high / low.

I've done a few processor designs in an FPGA, good luck with real gates.

Yes I have one 100nF capacitor per IC. And a few electrolytics. I am doing everything on a few breadboards, with LOTS of wires...

I'm not sure it will work because it is on breadboards and so on. But I'm trying...


I am interested in knowing about termination resistors, I have no idea where to put them, I just know they are needed. Would you be able to advise me on this?

Thanks a lot
 

RichardO

Joined May 4, 2013
2,270
I am building an 8bit computer using 74HC series of chips, and all my registers are connected to the data bus by tristate buffers, and this is why I am concerned. I am a bit worried :(
You should be. The last thing you need is to have a computer that works "most" of the time. Make sure that your design does not turn 2 buffers on at the same time even for a short period. This can be done as part of the state machine that executes the instructions. In one state you turn off the selected buffer and at least 2 states later you turn on the next buffer.

Yes I have one 100nF capacitor per IC. And a few electrolytics. I am doing everything on a few breadboards, with LOTS of wires...
I'm not sure it will work because it is on breadboards and so on. But I'm trying...

I am interested in knowing about termination resistors, I have no idea where to put them, I just know they are needed. Would you be able to advise me on this?
Your bypassing scheme sounds good as long as the 100 nF caps have leads short leads, preferably less than about 1/2".

Be sure to keep the wires as short as possible. If you keep the wires less than a few inches total on any given signal then you should not need termination. 74HC logic is not terribly fast and the propagation time of the signals is long compared to the propagation time of the wires. So, if you are not running the clock right at the absolute maximum possible then there will be plenty of time for the signals to settle.
 

ScottWang

Joined Aug 23, 2012
7,397
If you upload the circuit then we can see more details in the real circuit.

Sometimes if you want to avoid the timing conflict then you can use a decoder as 74HC138 or 74HC139 or 74HC4028, it depends on how many registers you have, and the logic signal needs high or low, the first is to send the decoder selection signal to select(enable) one register and send the trigger clock.
 

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
I dont have the schematics. I am building it from my mind. The part that is of concern is just a few registers connected to an 8bit bus through buffers.

I think that like the replies above, there won't be problems because the time is too short for any current to short the circuit..... I will have to try and see what happens....

I am concerned also about the fact that i am building it on cheap breadboards..........
 

Deleted member 115935

Joined Dec 31, 1969
0
by bread board, do you mean this type ?

as for your termination question, a world in itself, whats your experience ?

 

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
Andy, my breadboards are not as small as those :p They are larger.... and come from China :) They are cheap but work well.

I am not an electronics engineer so I dont have experience with termination but I want to learn!

I heard that a 22Ohm resistor suffices, but my worry is where exactly are they needed? At clock lines ? Or at signals themselves from output through the bus through the inputs ?
 

ScottWang

Joined Aug 23, 2012
7,397
I dont have the schematics. I am building it from my mind. The part that is of concern is just a few registers connected to an 8bit bus through buffers.

I think that like the replies above, there won't be problems because the time is too short for any current to short the circuit..... I will have to try and see what happens....

I am concerned also about the fact that i am building it on cheap breadboards..........
Now, you are discuss in public forum, you can't just keep the circuit in mind, so let our members have the same target to discuss and not just guessing, please draw a circuit or block diagram, thank you.

Find datahseet of ee parts 1
Find datahseet of ee parts 2
 

ClassOfZero

Joined Dec 28, 2016
114
If the select signals are coming from your CPU, I think you may find that the problem you describe may be a non issue. Have a look at the timing signals from the CPU.

I never heard of this issue being raised when a memory read happens in one physical device and the next read comes from a different memory device. I will qualify my experience was with Z80 systems.
 

Deleted member 115935

Joined Dec 31, 1969
0
Andy, my breadboards are not as small as those :p They are larger.... and come from China :) They are cheap but work well.

I am not an electronics engineer so I dont have experience with termination but I want to learn!

I heard that a 22Ohm resistor suffices, but my worry is where exactly are they needed? At clock lines ? Or at signals themselves from output through the bus through the inputs ?


Ok,

so those boards are terrible for more than one or two IC's .

the connections are VERY un-reliable .

They work great for a play around, but if you end up with a rats nest of wires, your going to be fighting un reliability BIG time.

These boards are also fantastic at BAD power / ground delivery. you WILL get horrendous glitches. causing un reliability.

Your idea of building a 8 bit cpu out of logic chips on these boards as a none start
 

Thread Starter

PauloConstantino

Joined Jun 23, 2016
266
So you using the logic ICs and ram to built an ALU and CPU and computer?

Yes that's right.... I can't wait till it is complete so I can write an operating system for it, assemblers and so on... I need to learn how to generate composite video signals for it before... I have only a vague idea of how to do it. Alternatively I am thinking of creating a screen made of small LED's and then controlling it rather than using a TV. It will also play 8bit music !

This project was supposed to be built with a wirewrap technique, and I will redo it when it's functional... I just need to see if working fast before I build the final one. But the end product will be a fully functional 8 bit computer built with wirewrap techniques.. Kind of like the magic1 homebrew computer that is on the net somewhere...

I am sorry I forgot to post a photo of the capacitors on each iC... here it goes...



I am worried about terminating resistors... Where to put them and what value they should have.,..
 
Top