I've just started this journey . I've completed some of the projects in the starter kit with no problems .
I found some tutorials on youtube , I've follwed the exact details of code and keep getting an error notice ...
int LEDPin=13;
int waitTimeOn=500;
int waitTimeOff=500;
you've been using '{' and '}'in place of '(' and ')' in many places.
functions use round brackets to take in (or not!) parameters.
curly brackets are to enclose the function's code
please see fixed code below (I've commented out the incorrect curly braces for your understanding)
int LEDPin = 13;
int waitTimeOn = 500;
int waitTimeOff = 500;
void setup() {
pinMode(/*{*/LEDPin, OUTPUT/*}*/);
}
void loop() {
digitalWrite(/*{*/LEDPin, HIGH/*}*/);
delay(/*{*/waitTimeOn/*}*/);
digitalWrite(/*{*/LEDPin, LOW/*}*/);
delay/*{*/(waitTimeOff/*}*/);
}
Success ... Cheers .
So , I'm building a turntable. which needs a tachometer and also the capabilty read the platter speed and adjust itself to maintain a constant RPM . There are off the shelf solutions ,but that doesnt feel right as I've made everthing else by aquiring other skills . This is tons of fun for an old man playing in his little workshop .
I really appreciate your kind patience .
Richard