evive has 1 single-colour and 2 dual-colour programmable LEDs, along with fix LEDs for serial communication, power indication and battery charging status.
Single Colour Programmable LED
A single colour LED is connected to digital pin 13 of Arduino Mega, which is programmable and can be controlled via digitalWrite() or analogWrite() functions.
The following code illustrates the use of digitalWrite() to control LED:
The following code illustrates the use of analogWrite() to control LED:
Dual-colour Programmable LED
Two dual-colour programmable LEDs are attached to digital pins 28 and 29 for first LED and digital pin 30 and 31 for the second LED. By controlling the output of one of the pin, you can control one colour of the LED and by controlling the second colour. Both the LEDs are common cathode LEDs, which means that the common terminal is GND and when the other pins are given HIGH, the LED glows.
The following program illustrates how to use dual-colour LED.
- Serial Communication LED: evive has 4 serial communication channels. For the first channel, a dual-colour LED is connected, which glow when the communication happens from the channel.
- Power Indication LED: This LED glows when evive is powered via any source (Internal battery or external power source).
- Power Indication LED: This LED constantly glows when the internal battery is charging and blinks when there is no internal battery connected to evive.
Introduction In this tutorial you will be turning on and off the led Pin-13 on evive via smartphone. For this smartphone will be connected to
Introduction You must have played Air Hockey! Pay few $$dollars$$ to the gaming zone and just start scoring goals to beat your friends. Isn’t it