I'm trying set up my Arduino Microboard to simulate fireflies turning on and off.
For those living in certain parts of the US you know what I'm trying to accomplish.
Hoping someone can help me write the sketch for about 9 LEDS to do this.
I'm still struggling how to program in C+. Ive tried using some of the samples but it keeps getting kicked back as an error.
Any help greatly appreciated.
I think you are in the right place but you've come in without a real question.
Without knowing exactly what you have tried (What was the code that the Arduino IDE couldn't compile) how can we help?
Without knowing how your 9 leds are going to be wired up, we can't help by writing the code (it could compile but then your LEDS wouldn't work because they aren't in the right pins.
Rather than starting out to get 9 leds all fading separately have you tried just getting your board to do a blink sketch?
If you try a blink sketch on a digital pin, maybe you could try it on an analogue pin. Now maybe you could control the output of that pin?
There are a million ways we can help, but you aren't giving us the information needed to be able to do so.
Thanks so much. I understand. My apologies.
Ive used the sample analogue sketch for a fading LED on pin 9 and its pretty close to what I want. I guess what I want is to just copy and paste that sketch to include another 8 of them. I would like for them to light up randomly one at a time. A few short bursts by some. A little longer for others but never longer than about 2 seconds. I know the mistake Im making is in the void loop and probably very simple fix.
I only need to set up a board about once a year and whatever I learn the year before is forgotten. This is something I know I should be doing a lot if I'm going to get it down. Time is always my problem.
One problem I see is that Arduino Micro has only 7 PWM pins, and it sounds like you need 9. But if you truly mean you only need one of them to light at a time, then you will actually need only one PWM pin and 9 ordinary digital pins, which the Micro does have.
Let's see your attempted code and the error messages. Don't forget to read the guide before you post them.