Shift Register(74HC595) Showing garbage iniatially!

Go To Last Post
7 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ATmega64 drive Three Shift Register(74HC595) and 74HC595 drive nine seven segment display.

Initially when circuit power-up seven segments show unexcepted garbage with a blink!Then it's work fine.

Showing correct data on seven segments display.

 

 

 

How to fix such problem?

Regards,

eRony

 

শূন্য  - The ZeRo

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

eRony wrote:
Initially when circuit power-up seven segments show unexcepted garbage with a blink!Then it's work fine.

 

What exactly did you expect ?   By default, the internal registers are not defined.

How are you driving the /MR pin & STCP ? - and how long after power up, before those apply ?

 

Check the internal drawing of 595 - the MR is on the shifter and the STCP is edge activated

 

An alternative is to shift in a blank, before enabling /OE, but I see your OE is GND.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

This "unexpected garbage" is actually the expected behaviour.

The 595 has internal flipflops, and when power is first applied these turn on in a "random" state.

 

Some possible solutions:

1). Simply ignore it.

2). Disable the outputs untill the AVR has intitialized the 595's ( Tie ~OE to an AVR pin with a pullup resistor)

3). Disable the Displays untill the AVR has inititialized the 595's.

4). Write all zero's into the 595's as the first thing in your AVR program.

 

 

With option 2). you can use a PWM pin to control the brightness of the displays.

Doing magic with a USD 7 Logic Analyser: https://www.avrfreaks.net/comment/2421756#comment-2421756

Bunch of old projects with AVR's: http://www.hoevendesign.com

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I exactly want to show 3 temperature values on display.

MR Pin is always kept high.

After power-up, it requires 5ms to give a Low to High pulse to STCP pin.

 

 

শূন্য  - The ZeRo

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Lots of thanks Paulvdh

It's really awesome option 2). you can use a PWM pin to control the brightness of the displays.

শূন্য  - The ZeRo

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

eRony wrote:
It's really awesome option 2).
You do realise that it was Who-Me in #2 who first said:

Who-me wrote:
An alternative is to shift in a blank, before enabling /OE, but I see your OE is GND.

Credit, where credit is due!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

clawson wrote:
Credit, where credit is due!
Maybe we can share the fame ?

I (almost) always need > 5min to gobble up the text for a post.

And OP seems more impressed by the simple idea of PWM dimming than by the initial blanking of the screen.

WhoMe also didn't mention the pullup resistor to keep the outputs disabled before the AVR is initialized.

Doing magic with a USD 7 Logic Analyser: https://www.avrfreaks.net/comment/2421756#comment-2421756

Bunch of old projects with AVR's: http://www.hoevendesign.com