Programmable LEDs

June 2, 2017

Introduction

evive has 1 single-color and 2 dual-color programmable LEDs, along with fix LEDs for serial communication, power indication, and battery charging status.

Single Colour Programmable LED

A single color LED is connected to digital pin 13 of Arduino Mega, which is programmable and can be controlled via digitalWrite() or analogWrite() functions.

evive Single Colour Programmable LED

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-color 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 color of the LED and by controlling the second color. 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.

 
evive Dual Colour LED

The following program illustrates how to use a dual-color LED.

Non-Programmable LEDs:

  1. 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.
  2. Power Indication LED: This LED glows when evive is powered via any source (Internal battery or external power source).
  3. Power Indication LED: This LED constantly glows when the internal battery is charging and blinks when there is no internal battery connected to evive.

evive non-programmable LED

Share this Documentation
Share on facebook
Facebook
Share on twitter
Twitter
Share on google
Google+
Share on pinterest
Pinterest
Share on reddit
Reddit
Share on print
Print
Related Tutorials & Projects
Flashing-LED-Cube

DIY Flashing LED Cube

IntroductionChristmas is coming! So is the time to decorate homes! This year, how ‘bout taking…
All articles loaded
No more articles to load
Featured Projects
Arcade-Basketball-Game

DIY Arcade Basketball Game

Introduction“We don’t stop playing because we grow old; we grow old because we stop playing.”…
All articles loaded
No more articles to load

Leave a Reply

Close Menu
×

Cart