Introduction: DragonBoard 410c and LED Strip 5050 (Beginners)

When I started working on a DragonBoard 410c, I had so many difficulties to find simple things tutorials, because the makers assume that you already know how to do the basics, then in this tutorial, I will explain in detail how to connect and use a LED strip RGB 5050 with the DragonBoard 410c (DB 410c). This method you can use for others things like DC motors, etc.

Step 1: Materials

1 - Keyboard;

1 - Mouse;

1 - Monitor with HDM;

1 - Protoboard;

1 - LED Strip RGB 5050;

3 - Tip 122;

Some jumpers.

Step 2: Install Debian

Follow this tutorial to install the Debian System: 96 Boards Tutorial

Step 3: Step 3: Start the DragonBoard 410c

Connect a monitor, keyboard, and mouse. It can be used as a normal Linux desktop computer if you attach a keyboard, mouse, and monitor. Use the “Terminal” application to get a command prompt.

Step 4: Connect to the Internet

On the bottom right side, has an option to connect the DB 410c to the internet, like a Linux.

Step 5: Update Debian

Make sure all of the Debian packages are up to date before trying to install the packages.

Put on LXTerminal:

sudo apt-get update
sudo apt-get dist-upgrade -u
Do you want to continue? [Y/n] y

Step 6: Install Extra Tool Packages

To run these demos, we’ll install the Debian packages for the standard Linux development tools, the Python environment, and the Arduino toolchain. Then we'll install the MRAA and UPM packages from source.

Put on LXTerminal:

sudo apt-get install arduino-mk arduino git build-essential autoconf libtool swig3.0 python-dev nodejs-dev cmake pkg-config libpcre3-dev
sudo apt-get clean

Step 7: Configure the Software

The last step is to install some configuration files so that the development tools know which devices to use. Fetch the 96boards-tools package and install the provided configuration files:

Put on LXTerminal:

sudo adduser linaro i2c # Allow the normal user to perform i2c operations
git clone https://github.com/96boards/96boards-tools
sudo cp 96boards-tools/70-96boards-common.rules /etc/udev/rules.d/
cat | sudo tee /etc/profile.d/96boards-sensors.sh << EOF
export JAVA_TOOL_OPTIONS="-Dgnu.io.rxtx.SerialPorts=/dev/tty96B0"
export MONITOR_PORT=/dev/tty96B0
export PYTHONPATH="$PYTHONPATH:/usr/local/lib/python2.7/site-packages"
EOF
sudo cp /etc/profile.d/96boards-sensors.sh /etc/X11/Xsession.d/96boardssensor

Now reboot the system to pick up all the changes:

Put on LXTerminal:

sudo reboot

Step 8: Fetch the Sample Code for Projects in This Guide

Put on LXTerminal:

git clone <a href="https://github.com/96boards/Sensor_Mezzanine_Getting_Started"> https://github.com/96boards/Sensor_Mezzanine_Gett...</a>

Now, on Downloads folder, you have so many examples files to help you on future projects.


Now, let's start to get the hands dirty

Step 9: The Hardware

The LED Strip work with 12v, and the Dragonboard with 1.8v. But, the strip works with a common positive, and individual GND for triggering the colors. The Tip 122 work triggering GNDs with the 1.8v from DB 410c.

The only thing you need to do is connect the common positive from LED Strip to the 12v(positive of the DC Power), and the negative from the DC power to the emitter of Tip 122. To turn on the LEDs, connect the individual GNDs to the Tip 122 collector. The base, you connect to DragonBoard GPIO pins. Follow the image attached.

(Attached image with DragonBoard and Tip 122 pin out)

Step 10: The Software

On the DragonBoard open the folder would you like to save your project and with the right button click on a blank space, and select "New File", put the name of the project and the extension ".py" like this: "ledStrip.py"

Open the file and paste the attached code that was taken from one of the examples in the UPM library. (This case I use pins 27, 29 and 31 on DB 410c)

Step 11: Execution

Now, after saving the code, you should open the LXTerminal (On system tools) and the two commands with you most use: "ls" to list all items in the folder, and "cd" to get in a folder, and you should go to the folder you saved the code file to.

Ex: If my code file (ledStrip.py) are in a "Codes" folder on Downloads, I type this on LXTerminal:

cd Downloads
cd Codes

Now, when I'm in the folder, I open the code file with the command:

sudo python ledStrip.py
And the code is executed. If have an error, it will show on the LXTerminal

Step 12: References

Comments

About This Instructable

184views

6favorites

More by Roberto Pinheiro:DragonBoard 410c and LED Strip 5050 (Beginners)DragonBoard 410c and LED (Beginners)DragonBoard 410c and PushButton (Beginners)
Add instructable to: