5% OFF Over $19, Code: Elephant5; 10% OFF Over $59, Code: Elephant10



EASY plug Ultimate Starter Learning Kit Project 2: LED Light

Posted by Fiona Su on

Overview

To start off the EASY Plug sensor module, we will work on an LED. That’s right - it is as simple as turning a light on and off. It might not seem like much, but establishing this important baseline will give you a solid foundation as we work toward more complex experiment.

Component Required

  • EASY plug control board*1
  • EASY plug LED Module *3
  • RJ11 cable*1
  • USB cable*1

Component Introduction:
The LED light modules have shiny colors, ideal for Arduino starters. It can be easily connected to IO/Sensor shield.
Note: this module needs to be used together with EASY plug control board. You can also choose other LED to emit different color of light like blue, green, yellow and red.

  • Sensor type: Digital
  • Interface: Easy plug
  • PH2.54 socket

Connect It Up
Connect the EASY Plug LED module to control board using an RJ11 cable.

thumb

Example 1: Light up LED
Upload the Code
Below is an example code for lighting up an LED.

thumb

What You Should See
The LED is turned on. If it doesn’t, make sure you have assembled the circuit correctly and verified and uploaded the code to your board.

thumb

Example 2: LED Blink
Upload the Code
Below is an example code for LED blinking.

thumb

What You Should See

thumb

The LED will flash on for one second, then blink off for one second.

thumb

If it doesn’t, make sure you have assembled the circuit correctly and verified and uploaded the code to your board.
Little Knowledge:
If you want to make the LED flash on and off more quickly or slowly, you can modify the Delay time here.

thumb

Thank you! Enjoy the following programming.
Example 3: LED Breath
Here do you know how to connect the LED module? Check the code.
Test Code
Below is an example code for one LED breathing.

thumb

Little Knowledge:
Here no connection diagram, which port should you choose? Yeah, Pin 5.
See the code, you can modify the connection pin here.

thumb

What You Should See
The LED gradually becomes brighter for one second, then gradually dimming for one second.

thumb

If it doesn’t, make sure you have assembled the circuit correctly and verified and uploaded the code to your board.
Example 4: Brighten and Dim
Hookup Guide
Connect the three EASY Plug LED modules to control board using RJ11 cables. Connect a red LED to D9, white LED to D6, blue LED to D5.

thumb

Upload the Code
Below is an example code for three LED modules experiment.

thumb

thumb

What You Should See
The three LEDs are gradually brighter then gradually off one by one, circularly.
If it doesn’t, make sure you have assembled the circuit correctly and verified and uploaded the code to your board.

thumb

thumb

thumb

Troubleshooting

  • LED Not Lighting Up?

If upload the code successfully, but LED still not lights up. Make sure your board and LED module are connected correctly.

  • Program Not Uploading?

This happens sometimes, the most likely case is a confused Board and serial port, you should firstly select your proper board and port.

thumb

All Tutorials

Buy >> EASY plug Ultimate Starter Learning Kit 

0 comments

Leave a comment

Please note, comments must be approved before they are published