Wow this doesn't want to go in??
I keep getting a
"core.a(main.cpp.o): In function `main':
C:\Program Files\ARDUINO\arduino-0022\hardware\arduino\cores\arduino/main.cpp:10: undefined reference to `loop'
Cant see where its gone wrong?
I have read you right Mike Void (display) instead of Void (loop)?
//**************************************************************//
// Name : shiftOutCode, Hello World
// Author : Carlyn Maw,Tom Igoe, David A. Mellis
// Date : 25 Oct, 2006
// Modified: 23 Mar 2010
// Version : 2.0
// Notes : Code for using a 74HC595 Shift Register //
// : Display specified value
//****************************************************************
//Pin connected to ST_CP of 74HC595
int latchPin = 8;
//Pin connected to SH_CP of 74HC595
int clockPin = 12;
////Pin connected to DS of 74HC595
int dataPin = 11;
void setup() {
//set pins to output so you can control the shift register
pinMode(latchPin, OUTPUT);
pinMode(clockPin, OUTPUT);
pinMode(dataPin, OUTPUT);
Serial.begin(9600);
Serial.println("reset");
}
void display(unsigned int numberToDisplay){
digitalWrite(latchPin, LOW);
shiftOut(dataPin, clockPin, MSBFIRST, numberToDisplay % 256); //lower byte
shiftOut(dataPin, clockPin, MSBFIRST, numberToDisplay / 256); // higher byte
digitalWrite(latchPin, HIGH);
display(43690);
}
Thanks
Geoff