LED Sequence project

Status
Not open for further replies.

eric.martin

New member
Hi,

I am embarking on a little project and am kind of fuzzy on the software side of things/ in over my head with this part, so I would appreciate any guidance from the pros here!

I am trying to fire 12 LEDs in a sequence, and simultaneously fire a cameras shutter release each time one of these LEDs goes off. I want to do this with one push of a button. I will need to be able to control in the software the time in between each LED going off so I can use the fastest shutter speed possible.

If anyone can refer me to similar projects with LEDs or any articles to help me get started I would really appreciate it!

Cheers
Eric
 
Welcome, Eric!

Here's a simple project that lights up some LEDs.

Somethings to note: LEDs can easily draw more current than a Teensy can safely supply. It's up to you to make an appropriate circuit to drive the LEDs safely. If the LEDs are very small as in my case, the code only illuminates one LED at a time and there's a resistor in series with the LEDs. If the LEDs are more like a camera flash, you'll need something more powerful, e.g. separate power supply for the LEDs and an LED driver IC or some transistors capable of handling higher power, etc.

Regarding timing, my project didn't need precision, so I just used simple blocking delays. If you need high speed and high precision, it's definitely possible, but before you go down that route, bear in mind that even little microcontrollers are very fast. You might not need to do anything special.

You'll definitely need to debounce your button. There are some good libraries that can help you do this in software. See Bounce2, for example.

Good luck and let us know how it goes, preferably with pictures!

Cheers,
John
 
Status
Not open for further replies.
Back
Top