HI Folks, i was trying to verify this code which I am actually copying and learning at the same time, however it will not verify and keeps on saying that a ":" is missing.
Any advice would be much appreciated. Thanks
The first 4 lines are good and then the error code:
Users\chris\OneDrive\Documents\Arduino\blink_example\blink_example.ino: In function 'void setup()':
blink_example:8:8: error: expected ';' before '{' token
pinMode{myled1, OUTPUT}; //assign pin 4 as output
^
blink_example:9:8: error: expected ';' before '{' token
pinMode{myled2, OUTPUT}; //assign pin 5 as output
^
C:\Users\chris\OneDrive\Documents\Arduino\blink_example\blink_example.ino: In function 'void loop()':
blink_example:14:13: error: expected ';' before '{' token
digitalWrite{myled1, HIGH};
^
exit status 1
expected ';' before '{' token
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
`int myled1 = 4; //declare myled1 as the first led`
`int myled2 = 5; //declare myled2 as the second led`
`int onTime1 = 1000; //declare ontime as 1 second`
`int offTime = 1500; //declare offtime as 1.5 seconds`
void setup() {
pinMode{myled1, OUTPUT}; //assign pin 4 as output
pinMode{myled2, OUTPUT}; //assign pin 5 as output
}
`void loop() {`
`digitalWrite{myled1, HIGH};`