I got from sparkfun (7-Segment Display - 4-Digit (Yellow) - COM-09480 - SparkFun Electronics) and (Shift Register 8-Bit - SN74HC595 - COM-13699 - SparkFun Electronics). I don't understand how to get the A-G pins to the shift register and the 4 Anode pins to the other pins on the arduino. So far in my code I have:
const int latch = 3
const int serial = 4
const int clock = 5
const int done = 6
const int dtwo = 7
const int dthree = 8
const int dfour = 9
int numone = 0
int numtwo = 0
int numthree = 0
int numfour = 0
void setup(){
pinMode(latch, OUTPUT)
pinMode(serial, OUTPUT)
pinMode(clock, OUTPUT)
pinMode(done, OUTPUT)
pinMode(dtwo, OUTPUT)
pinMode(dthree, OUTPUT)
pinMode(dfour, OUTPUT)
dataArray[1] = B00010010
dataArray[2] = B01111100
dataArray[3] = B01011110
dataArray[4] = B00011011
dataArray[5] = B01001111
dataArray[6] = B01101111
dataArray[7] = B00010110
dataArray[8] = B01111111
dataArray[9] = B00011111
dataArray[0] = B01110111
}
void loop(){
}
From this point I'm stuck. I have no idea how to get the dataArrays to output to the shift register. So any help would be appreciated.