int shiftdatapin = 48;
int shiftclockpin = 50;
int RCK = 52;
int shiftregdata;
byte numbers[10] =
{
B00111111, // 0
B00000110, // 1
B01010011, // 2
B01001111, // 3
B01100110, // 4
B01101101, // 5
B01111101, // 6
B00000111, // 7
B01111111, // 8
B01101111 // 9
};
void setup() {
//set pins to output so you can control the shift register
pinMode(shiftdatapin, OUTPUT);
pinMode(shiftclockpin, OUTPUT);
pinMode(RCK, OUTPUT);
}
void loop() {
shiftregdata = B11111111;
shiftOut(shiftdatapin, shiftclockpin, MSBFIRST, shiftregdata); // puts the bits into the input register
digitalWrite (RCK, LOW);
digitalWrite (RCK, HIGH); // puts the bits into the output register.
shiftregdata = B00000110;
shiftOut(shiftdatapin, shiftclockpin, MSBFIRST, shiftregdata); // puts the bits into the input register
digitalWrite (RCK, LOW);
digitalWrite (RCK, HIGH); // puts the bits into the output register.
}
Well actually the first number just shows up on both