Controlling a strip of NeoPixel LEDs with LabVIEW, RoboRIO, and RIOduino via I2C

Hello Everyone,

I was inspired by a recent district event to learn how to interface FRC control systems with micro-controllers to implement visual feedback with LEDs.

Through brief interviews with a few of the teams that had LEDs flashing interesting patterns in a range of colors, I gathered the parts and set to work.

Though the process wasn’t very difficult, considerable time was spent struggling to find documentation and move beyond multiple sticking points. I created a comprehensive guide to help others that may be interested in taking a similar journey.

I’ve posted the guide on NI’s new LabVIEW Makerhub here and attached the guide to this post.

I’ve never created a white paper and welcome feedback on how to better distribute the content. I figured this to be a good start and will clarify the guide where necessary as well as the example code & script.

Left to - do:

  1. Record a demonstration video & link
  2. Create a demonstration script
  3. Test demonstration script
  4. Add additional use cases

The link to the sample code directory is here via OneDrive (make sure to view the ReadMe), though I am open to more permanent methods of hosting.

To those that attempt to use this content in projects, good luck, and let me know if you run into any trouble!

The Arduino and RoboRIO are both controllers running programs on their respective processors. Both are capable of reading sensors, making decisions, and outputting results to output ports. Useful bundles of code have been written for both platforms (some only on RoboRIO, others only on Arduino). The question is, how can we extract the most power from each? Can we make decisions in one, while outputting results in the other? Absolutely, and we do this by having both platforms agree to exchange information using a common language, or protocol, such as I2C or UART.

This guide is comprehensive because its goal is not only success with the tools utilized, but a deeper understanding of why the tools work and how to build on the knowledge to tackle more complex projects. Many lessons learned have been compiled to save you time in your own learning journeys.
Project Goals
• Complete control an individually addressable LED strip, driven by an Arduino, from the LabVIEW Environment
• Introduction to I2C, how to use it to establish communication between two different hardware and software platforms

Controlling a strip of NeoPixel LEDs with LabVIEW.pdf (1.24 MB)

Controlling a strip of NeoPixel LEDs with LabVIEW.pdf (1.24 MB)

Cool. Thanks for putting this together.