Is this correct?

Because I can't show pictures here, i'm gonna copy my Blink example sketch, and paste it here. Because I don't think it's correct.

/* Blink Turns on an LED on for one second, then off for one second, repeatedly.

Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN takes care of use the correct LED pin whatever is the board used. If you want to know what pin the on-board LED is connected to on your Arduino model, check the Technical Specs of your board at https://www.arduino.cc/en/Main/Products

This example code is in the public domain.

modified 8 May 2014 by Scott Fitzgerald

modified 2 Sep 2016 by Arturo Guadalupi */

// the setup function runs once when you press reset or power the board void setup() { // initialize digital pin LED_BUILTIN as an output. pinMode(LED_BUILTIN, OUTPUT); }

// the loop function runs over and over again forever void loop() { digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level) delay(1000); // wait for a second digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW delay(1000); // wait for a second }

Because I can’t show pictures here …

Good, because I don’t want to see pictures anyway.

… i’m gonna copy my Blink example sketch,

Non sequitur

, and paste it here

You’ve left out the CODE TAGS. Read How to post code properly

Because I don’t think it’s correct

And you’re not going to bother to tell us why?

Pete
P.S. It works for me.

Looking at your other post today, you ask what kind of board you have. It is a UNO clone.

Has it worked before or is it brand new?

As you give no clue to what is wrong, only suggestion is that you read sticky thread How to use this forum - please read.

Click the link in first sentence and scroll down. Look closely to paragraph 11. Tips for getting the most out of your post.

Why do you think it’s not correct? Does it compile (verify)?

Hello

Because I can't show pictures here, i'm gonna copy my Blink example sketch

Because I don't think it's correct.

Hey, it's a free and open world here - if that rocks your boat don't paste pictures and you are free to think what you want... :)

Now if what you need is an answer, then asking a specific question can help avoid sarcastic/amusing answers making fun of you (in a very gentle way, we don't take ourselves seriously here, don't take that to the letter but do read the how to use the forum section)

:)

/* am I posting notes correctly? I'm trying to blink the on-board LED. But that code has no variables. I was expecting a variable to blink pin 13. */

Comment in the code you posted.

Most Arduinos have an on-board LED you can control. On the UNO, MEGA and ZERO it is attached to digital pin 13, on MKR1000 on pin 6. LED_BUILTIN takes care of use the correct LED pin whatever is the board used.

LED_BUILTIN is a variable, and compiler assigns the right pin number for the different boards.

LED_BUILTIN is defined for the board that you are using as part of the Arduino installation. Try printing it.

UKHeliBob: LED_BUILTIN is defined

++

Gabriel_swe: Looking at your other post today, you ask what kind of board you have. It is a UNO clone.

Is your issue that the actual on-board LED doesnt seem to flash. If so, since it is a clone, sometimes it is better to address the pin directly. If it is an UNO change LED_BUILTIN to 13 to check that the LED works.

D

/* am I posting notes correctly? I'm trying to blink the on-board LED. But that code has no variables. I was expecting a variable to blink pin 13. The LED on the board works, because when I plug it in to the computer, it stays lit. */

what board are you using, then?

But that code has no variables

That isn't a problem. It doesn't need any.

Pete

TBIsurvive:
/* am I posting notes correctly? */

No. I’m not a C compiler.

Try this in your setup() function

Serial.begin (9600);
Serial.println (LED_BUILTIN);

Not tested. What does it print?

One does not necessarily need to declare a variable; LED_BUILTIN is defined somewhere in a file thay one usually does not see as a const int variable or a #define; not behind a computer at this moment to check or test.

sterretje: Try this in your setup() function

Serial.begin (9600);
Serial.println (LED_BUILTIN);

Not tested. What does it print?

One does not necessarily need to drclare a variable; LED_BUILTIN is defined somewhere in a file thay one usually does not see as a const int variable or a #define; not behind a computer at this moment to check or test.

Tested. 13.

BulldogLowell: what board are you using, then?

A picture posted in another thread show a (if I remember correct) WDLduino UNO. One of those clones with a small square surface mounted Atmega chip.

TBIsurvive:
/* am I posting notes correctly?
I’m trying to blink the on-board LED. But that code has no variables. I was expecting a variable to blink pin 13. The LED on the board works, because when I plug it in to the computer, it stays lit. */

What is your operating system on the computer?
Which version of the IDE are you using?
Is your uno detected correctly? (device manager in windows)
Does the code upload without problem?
Is this a brand new uno or has you successfully used it before?

There is usually an onboard power LED. It is on all the time.