Pages: [1]   Go Down
Author Topic: shift register code info  (Read 655 times)
0 Members and 1 Guest are viewing this topic.
Down Under (Australia), SA
Offline Offline
Jr. Member
**
Karma: 0
Posts: 83
Newbie is an understatement
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i need help, i plan on making a 10x10 led matrix using the 74HC595 shift register. i was looking at the info on http://www.arduino.cc/en/Tutorial/ShiftOut but the code is still confusing me. so i would like to know if anyone can explain better or put a link up to a good tutorial.
Logged

St. Louis, Missouri
Offline Offline
Sr. Member
****
Karma: 0
Posts: 278
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The way I have been learning Arduino-craft (including shift registers) is to simply build what is shown in the tutorials (yes, and make mistakes). You will learn that way. I really don't think I've seen an easier to follow tutorial than the one you pointed to. Just take it one step at a time until you understand enough to reach your goal.
Logged

Central MN, USA
Online Online
Tesla Member
***
Karma: 65
Posts: 6939
Phi_prompt, phi_interfaces, phi-2 shields, phi-panels
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I might be more inclined to do 8X8 since a 595 shift resistor has 8 outputs and 8X8 needs two of them. The tutorial is pretty good. What part of it confuses you?
Logged


Kuala Lumpur, Malaysia
Offline Offline
Full Member
***
Karma: 4
Posts: 176
Anything is possible
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I got a 8x8 LED Matrix but the size is too big to fit into a breadboard and too small for two breadboard combined..

Try to get those that can fit easily into the breadboard for testing/learning..



Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 4
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hey you can make the same without shift registers,if you  wish to do it just for fun. watch my blog
sattarnoonari.blogspot.com
 i can help you with my code, i made that as simple as possible.
Logged

my own world
Offline Offline
Newbie
*
Karma: 0
Posts: 26
We are all geeks!
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The 8x8 rgb matrix i use with my breadboard, I got from e-bay which is 60mm by 60mm square...
It is a hard shape to fit on the 2 breadboards, but at my local electronics shop I got a 40 pin pin socket/header
like the ones used on shields.  I cut 2 sections of 16 pins. The extra long pins can be bent slightly to fit on 2 breadboards no problem..
this also allows room under the matrix for the wires to be placed.


Another alternative  it to use 2 PC ide ribbon cables but you will have to figure out which wires to use at the connector.
Logged

Signatures are stupid!

Global Moderator
Boston area, metrowest
Online Online
Brattain Member
*****
Karma: 446
Posts: 23864
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

So, you want to make something like this, but in a 10x10 array, yes?
http://www.mpja.com/download/18460op.pdf
Wire up the LEDs, don't forget the current limit resistor.
To use it, shift out 2 bytes for the Y with 0 = LED on & 1 = LED off.
Then shift out 2 bytes for X, but the data will only be 0x80 - as the 1 marches down the output bits, the Columns with Y = 0 will turn on briefly.
If it is too dim, then do the shift out in software with small delay per clock:

shiftout Y9-16 data
shiftout Y1-8 data

digitalWrite Shift_data = 1 // prep a 1 go out
digitalWrite RCK LOW  // prep the 2nd stage clock
digitalWrite SRCK LOW // prep the 1st stage clock
digitalWrite  SCLR LOW  // clear theregister
digitalWrite SCLR HIGH//

For X = 1 to 10{  // start a loop for 10 bits
digitalWrite SRCK HIGH  // clock bits into 1st stage
digitalWrite RCK HIGH  // clock bits into 2nd stage
digitalWrite SRCK LOW  // prep for next clock
digitalWrite RCK LOW // prep for next clock
Shift_data = 0  // prep for next bit
delay(display_time) // if needed
next x}

repeat for next & column


* 10x10array_shifts.jpg (114.11 KB, 960x720 - viewed 9 times.)
« Last Edit: February 17, 2011, 12:39:52 am by CrossRoads » Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Pages: [1]   Go Up
Jump to: