How fast can a CD4028 change state?

Discussion in 'General Electronics Chat' started by TheButtonThief, Sep 4, 2015.

  1. TheButtonThief

    Thread Starter Active Member

    Feb 26, 2011
    219
    38
    I want to multiplex a numeric display using an ATmega328 and BCD to decimal decoder (but not a seven segment display). I want the display to refresh as fast as the micro can allow, will something like the CD4028BEE4 keep up with the 16Mhz ATmega?

    Cheers
    Jay
     
  2. Alec_t

    AAC Fanatic!

    Sep 17, 2013
    5,813
    1,105
    Should do. Check the datasheet.
     
  3. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,073
    3,856
    First, the 16MHz is the oscillator frequency, not the instructions per second.

    Many instructions on the ATMega take only one clock cycle but many don't. If you are using assembly language, you can count the steps and look up how many clock cycles are needed for each instruction.

    If you are using arduino, then there is a lot going on below the surface and the whole thing can be very slow - depending on what you are doing.

    I also assume that you will do something with your program besides update the CD4028 - so you will not need that to update with every instruction. Maybe every 10th instruction. Assume you use 10 clock cycles (5 to 7 instructions), between updates, then you will only need the CD4028 to react 1.6 M times per second. I think 2 is the limit but check the datasheet.

    Also, just because you update the cd4028 quickly, doesn't mean that your LED or LCD will update that quickly. Check the datasheet did rise/fall times, etc.
     
    absf likes this.
  4. ScottWang

    Moderator

    Aug 23, 2012
    4,858
    768
    74HC4028 -- 4.5V, Pd=46nS~24nS(21.7Mhz~41.67Mhz).
     
  5. OBW0549

    Well-Known Member

    Mar 2, 2015
    1,328
    890
    Why do you need to multiplex the display any faster than the minimum rate needed to avoid visual display flicker? 30 updates/second ought to be ample, and no challenge for either your ATMega328 or your CD4028B.
     
    Roderick Young likes this.
  6. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,546
    1,252
    If by display you mean a visual indicator to be seen by Earth-type humans, then updating it more often than 20 times per second is meaningless. Yes, most people can perceive flicker at 20 Hz, but that's not the same as understanding correctly what is being displayed. 20 Hz is mush, 40-50 Hz is a blur, and 100 Hz is completely indistinguishable.

    ak
     
    absf likes this.
  7. TheButtonThief

    Thread Starter Active Member

    Feb 26, 2011
    219
    38
    Cheers bud
     
  8. TheButtonThief

    Thread Starter Active Member

    Feb 26, 2011
    219
    38
    It's a 10x100 matrix of little lamps, I want the frequency to be as high as possible so to keep the display as bright as possible.
     
  9. crutschow

    Expert

    Mar 14, 2008
    13,056
    3,245
    The brightness of the lamps will be determined by the duty-cycle of the signal, not its frequency. You just need the frequency high enough to prevent flicker, which is about 100Hz or so.
     
    absf likes this.
  10. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,546
    1,252
    Also note that, depending on how the multiplexing is done, every time the display is updated it loses a little brightness compared to being on continuously. So it is possible that the more frequently the display is updated, the less bright it appears. Here is an extreme example.

    Let's assume an absolute maximum CPU refresh rate of 1 MHz with zero latency between lamps. For 1000 lamps, each one is blinked every 1 millisecond for 1 microsecond. If the refresh rate is decreased to 100 KHz, now each lamp is blinked for 10 us, a 10:1 increase in lamp energy.

    ak
     
  11. crutschow

    Expert

    Mar 14, 2008
    13,056
    3,245
    I don't follow. :confused:
    If the refresh rate is reduced to 100 kHz, then the duty cycle would still be the same (10μs/10ms versus 1μs/1ms) so the lamp energy would be the same.
     
  12. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,546
    1,252
    No, the processor can be off doing other things or just plain sitting there waiting for the next 100 Hz tick, and power is sitting on the last lamp until it is told to move. Note zero latency between moves. My example, my rules.

    ak
     
  13. TheButtonThief

    Thread Starter Active Member

    Feb 26, 2011
    219
    38
    Love it

    Helpfull, great stuff. Thanks chaps
     
  14. crutschow

    Expert

    Mar 14, 2008
    13,056
    3,245
    Fine. Then the rules need to be stated.
     
  15. AnalogKid

    Distinguished Member

    Aug 1, 2013
    4,546
    1,252
    Private conversation?
     
  16. crutschow

    Expert

    Mar 14, 2008
    13,056
    3,245
    About what? :confused:
     
Loading...