Hi all. I have a problem with my shift registers (74hc 595) The "Hello World" sketch is working fine. But if I want to upload the "one by one" sketch nothing hapens. Sometimes the LEDs freeze.
So how have you wired it up? Link to the code you have used?
I have wired it up like in this tutorial: http://www.arduino.cc/en/Tutorial/ShiftOut
This one works: http://arduino.cc/en/Tutorial/ShftOut11
This one not: http://arduino.cc/en/Tutorial/ShftOut12
Got irritated of this line:
- 74HC595 shift register attached to pins 2, 3, and 4 of the Arduino,
Sorry!
Got irritated of this line:
Why did that line irritate you? If you mean that the compiler didn't like it, you need to post the EXACT error message.
This is one big comment section
/*
Shift Register Example
for 74HC595 shift register
This sketch turns reads serial input and uses it to set the pins
of a 74HC595 shift register.
Hardware:
* 74HC595 shift register attached to pins 2, 3, and 4 of the Arduino,
as detailed below.
* LEDs attached to each of the outputs of the shift register
Created 22 May 2009
Created 23 Mar 2010
by Tom Igoe
*/
If you are missing the start of the comment, the / * , then you may get odd errors.
Maybe it's that the comments say connected to pins 2, 3 & 4 but the sketch actually uses 8, 11 & 12.
MrMcChicken: I have wired it up like in this tutorial: http://www.arduino.cc/en/Tutorial/ShiftOut
This one works: http://arduino.cc/en/Tutorial/ShftOut11
This one not: http://arduino.cc/en/Tutorial/ShftOut12
The third sketch takes serial input and uses it to light the LEDs. Are you inputting anything into the serial console? If not it won't do much.