Skip to content

Latest commit

 

History

History
44 lines (33 loc) · 2.08 KB

File metadata and controls

44 lines (33 loc) · 2.08 KB

DiscoSkirt

An Arduino sketch for a skirt that had RGB LEDs and can respond to motion or sound.

The hardware consists of

Build instructions can be found at [http://www.gregington.com/2013/10/disco-skirt.html].

Libraries

The sketch needs to have the following libraries installed in the Arduino IDE:

Code

The code is designed to make it easy to add and remove modes. Each mode is stored in a separate file. To change modify the modes array to add or remove the required mode. Each entry in the array mist be a function pointer to a function that takes no arguments. The specified function will be executed continually in an infinite loop.

As an interrupt is used to trigger mode changes, use for the delay() function is discouraged. A DELAY macro is available as a convenience that breaks larger delays into smaller ones, checking for a mode change every 10ms. If a mode change has been detected, then control will be returned to the main loop which will advance the mode.

Credits

This project has built upon the work of others: