Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronic Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Register Log in

using shift register for extend output is Safe ?

azadfalah

Advanced Member level 4
Joined
Aug 13, 2016
Messages
103
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Activity points
765
Hi friends

To increase the output of the microcontroller on a board, I have to use the shift register 74HC595

Assuming compliance with design tips
Is it still possible to activate the output of the register shift due to noise?
Is the use of microcontroller i/o directly is safer than using shift register ?
Is it safer to use transparent latch (74HC573) than shift registers (74HC595) ?
How can I be sure that the output will not turn on without my control?


thank
 

barry

Advanced Member level 5
Joined
Mar 31, 2005
Messages
5,036
Helped
1,103
Reputation
2,216
Reaction score
1,088
Trophy points
1,393
Location
California, USA
Activity points
27,586
A shift-register, a latch and a microcontroller are different things.

What are you trying to do? What do you mean "increase the output"?

What do you mean "activate the output of the register shift due to noise"? Do you mean will noise trigger the shift register? Yes, it can.

How can a latch be "safer" than a shift register? That's like asking if an orange is safer than a banana.

I think you are trying to ask questions about noise susceptibility, but it's not clear. Maybe you should rephrase your questions.
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
18,933
Helped
4,212
Reputation
8,427
Reaction score
4,159
Trophy points
113
Activity points
124,467
Hi,

* activated by noise: yes, on a bad design, almost No on a good design
* safer in which regard?
* safer in which regard?
* by a good circuit. Useful RESET for example.

Klaus
 

azadfalah

Advanced Member level 4
Joined
Aug 13, 2016
Messages
103
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Activity points
765
I need extend outputs of STM32 MCU

-> The risk of accidentally ( Due to noise ) trigger the output should be very low
-> If the outputs have unwanted behavior , there is a risk of endangering someone's life
--> Of course, there are some protections, but I have to be sensitive in this area

In general, I have two options , use the latch to expand the output or use shift registers to expand the output
Using shift registers is better for me because they require fewer pins and routing

In which case is the system more sensitive to noise 74HC573 vs 74HC595 ?


Expend 74HC573.png
* I could not find a better image for 74hc573 in my plan STR710 replaced by STM32 MCU


Expend 74Hc595.png
 
Last edited:

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
18,933
Helped
4,212
Reputation
8,427
Reaction score
4,159
Trophy points
113
Activity points
124,467
Hi,

-> The risk of accidentally ( Due to noise ) trigger the output should be very low
A good PCB layout is most important. In case you expect heavy noise: shield it (with a metal enclosure, shielded wires...) and use filters on the critical signals.
-> If the outputs have unwanted behavior , there is a risk of endangering someone's life
Consider methods to increase safety. Write the registers periodically. Let's say every 10ms. Then in case of a "wrong" bit it will be corrected automatically. Read about watchdog and redundacy checks
In which case is the system more sensitive to noise 74HC573 vs 74HC595 ?
In case of inappropriate PCB layout, EMC filtering, to high external noise..
I don't think it's a problem of the used devices (ICs).
Signal quality is what matters.

And this starts with proper power supply decoupling capacitors ... I miss them on your schematics.
In case you already have them, then show them. Otherwise we will never know...

Klaus
 

barry

Advanced Member level 5
Joined
Mar 31, 2005
Messages
5,036
Helped
1,103
Reputation
2,216
Reaction score
1,088
Trophy points
1,393
Location
California, USA
Activity points
27,586
Just to expand on what Klaus has said, if you're worrying about killing someone, there's A LOT MORE you need to be concerned with. What if your microprocessor software has a hidden bug and outputs the wrong data? All the EMC filtering in the world isn't going to fix that. You might need some external hardware just to prevent, for example, two signals being active at the same time. (I once destroyed an expensive amplifier in a radar because the transmitter and receiver were enabled at the same time. A simple logic gate would have prevented that from ever happening.) You also need software checks in place to prevent dangerous situations from happening. You can also use methods like triple-redundancy to mitigate noise problems.

As far as which of your latch or shift-register approaches is less susceptible to noise? They're identical. For a given process (CMOS, TTL) the susceptibility to noise is pretty much the same for all inputs. For example, for TTL less than 0.8 V is a logic zero; greater than 2V is a logic one. Anything in between those levels is indeterminate. If you have noise spike of greater than 2V on a clock line or a latch-control line, you've got a problem. Even if you have a spike of, say, 0.9V, you might have a problem.
 

betwixt

Super Moderator
Staff member
Joined
Jul 4, 2009
Messages
14,712
Helped
4,808
Reputation
9,633
Reaction score
4,590
Trophy points
1,393
Location
Aberdyfi, West Wales, UK
Activity points
125,319
Consider a cheap I2C expander such as the PCF8754T - they cost virtually nothing, easy to use as inputs OR outputs, expandable (3 address lines = 8 combinations * 8 bits = 64 I/O lines), give you interrupt on change capability and outputs are unlikely to get stuck at indeterminate states as long as I2C rules are followed. Only two connections needed to the MCU.

Brian.
 

barry

Advanced Member level 5
Joined
Mar 31, 2005
Messages
5,036
Helped
1,103
Reputation
2,216
Reaction score
1,088
Trophy points
1,393
Location
California, USA
Activity points
27,586
Consider a cheap I2C expander such as the PCF8754T - they cost virtually nothing, easy to use as inputs OR outputs, expandable (3 address lines = 8 combinations * 8 bits = 64 I/O lines), give you interrupt on change capability and outputs are unlikely to get stuck at indeterminate states as long as I2C rules are followed. Only two connections needed to the MCU.

Brian.
This doesn't solve the problem of killing someone because of an inadvertent bit-flip. A glitch on the clock or data line is still going to be a problem.
 

azadfalah

Advanced Member level 4
Joined
Aug 13, 2016
Messages
103
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Activity points
765
I think it is better to connect important I/Os directly to the MCU and extend less important I/Os with the shift registers
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
18,933
Helped
4,212
Reputation
8,427
Reaction score
4,159
Trophy points
113
Activity points
124,467
Hi,

not necessarily ... noisy environment, bad layout, no filters ... may be more critical

Klaus
 

    azadfalah

    points: 2
    Helpful Answer Positive Rating

azadfalah

Advanced Member level 4
Joined
Aug 13, 2016
Messages
103
Helped
1
Reputation
2
Reaction score
1
Trophy points
18
Activity points
765
The purpose of my question was the risks at worst case when we use I/O extenders

Yes, design tips definitely have a lot of impact and without design considerations there is no guarantee of performance
But using this type of output extender creates a risk that does not already exist

Thanks friends
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
18,933
Helped
4,212
Reputation
8,427
Reaction score
4,159
Trophy points
113
Activity points
124,467
Hi,

What I tried to say:
It's not a (main) problem of port extender IC or microcontroller. If you don't have a good design your signals will get corrupted, it does not matter whether they come from/to the microcontroller or bus extenders. But I agree that "latched" devices may latch an erroneous state, and keep them.
Thus my recommendation to update the registers regurarily to automatically correct erroneous states.

Klaus
 

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top