Andrei_D12
Active Member
But my question is: in which language is this module (Arduino) programmed??? Is it C or BASIC???
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
/*
Blink
Turns on an LED on for one second, then off for one second, repeatedly.
This example code is in the public domain.
*/
// Pin 13 has an LED connected on most Arduino boards.
// give it a name:
int led = 13;
// the setup routine runs once when you press reset:
void setup() {
// initialize the digital pin as an output.
pinMode(led, OUTPUT);
}
// the loop routine runs over and over again forever:
void loop() {
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
Thank you very much!
As for programming a LED sequence... I have seen that is soooo simple. Ex: we use PORTB for controlling 8 leds. All its pins are set to outputs by putting 0000 0000 in TRISB from Bank1 (then we return to Bank0 to manipulate the data). After this we need to place binary values in the PORTB register in order to control the outputs and call a delay subroutine for every step (which makes the result visible for our eyes ) . But it remains to be programmed...
This is my RGB LED Christmas tree (it doesn't look really like a Christmas Tree), made out of a piece of transparent plastic sheet, a matrix board, a 3 x AA battery holder, and the brain of my ''design'', a PIC16F628A. I'm sorry because I didn't post it earrlier, but I was a bit busy with the Holiday preparations.
Anyway, this is my little toy in action. Hope you like it!
(Ignore the sound of the video, because I forgot the TV turned on while making the video)
hi Al,
Like the Xmas tree.
For anyone who cannot get a micro this could be a budget alternative.
E
https://www.amazon.co.uk/gp/product...&redirect=true&ref_=oh_aui_detailpage_o04_s00