Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Why does "blink" show as a command?

Status
Not open for further replies.

Fintek

Member
I tried using the word "blink" in the Arduino IDE (1.8, not 2.0) and it turns red as if it was a command. But it isn't.... was it at one time? What would be the syntax?
 
So it does, very strange, any idea what it does?
blink.png


Mike.
 
Command was used over here :



Regards, Dana.

As far as I could see 'blink' is just used as an array in that example, and not a command.

Blink is the standard test program for Arduino's, and usually comes pre-loaded to prove it works - so it 'migt' be a reserved word because of that?.

However, there's a text file "lib/keywords.txt" which is used to colour reserved words etc. but 'blink' isn't listed there. Perhaps it may be used somewhere in one of the libraries?, or it's reserved elsewhere?.

From the link above, if you enter blink as an array it's also highlighted as a reserved word, but seems to compile fine. Whereas blank isn't highlighted. Presumably it must be listed 'somewhere', so I would advise not using it - as it might cause an issue if it clashing with something - however, as it compiles OK then it 'might not' be an issue, but why risk it?.

blink_test.png
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top