Go Down

Topic: About 74HC595 Shift Register (Read 857 times) previous topic - next topic


Aug 17, 2012, 12:22 am Last Edit: Aug 17, 2012, 12:25 am by Pancra85 Reason: 1
On a 74HC595 Shift Register is it mandatory to use the latchPin??
On the examples it says that you need to put it LOW so the output doesnt changes while you are sending info on it.

Code: [Select]
    // take the latchPin low so
    // the LEDs don't change while you're sending in bits:
    digitalWrite(latchPin, LOW);
    // shift out the bits:
    shiftOut(dataPin, clockPin, MSBFIRST, numberToDisplay); 

    //take the latch pin high so the LEDs will light up:
    digitalWrite(latchPin, HIGH);

but what if I don't care about sending gibberish until the last byte has been sent? Could I set the latch PIN on the Shift Reg to +5v so it is always receiving data? Would that work?


I think the RCLK, or "latch", is edge-triggered.
It doesn't have latched and unlatched states.
When it gets a low to high (transition), the shift register contents are then transferred to the output/s.

"Who is like unto the beast? who is able to make war with him?"
When all else fails, check your wiring!


Ok, so three pins is obligatory

Go Up