For the Duel nature sculpure, I wanted to have a ‘breathing’ pattern where all the LEDs vary in brightness in a natural/organic way. A good example is the ‘sleep indicator’ LED on recent Macs/Powerbooks. (There’s even a patent!) The problem is that, while the patent claims its a simple sinusoid (see the patent for the image), programming in a sinusoid doesn’t look nearly as good. So I decided to get the real waveform with a kludgy reverse engineering attempt:
[flickr 212611715 ]I used a MIDIsense instead of a simple voltage divider because I want to extract the absolute LED brightness pattern and a photocell voltage divider acts ‘inversely’ (well, 1/R) instead of linearly (ie, just R). (The MIDIsense has an opamp to linearize the resistive sensor output)
[flickr 212611654 ]
There it is! There is a bit of ‘noise’ on the peaks because I’m picking up some of the PWM artifacts through the diffused white plastic.
Eink, E-paper, Think Ink – Collin shares six segments pondering the unusual low-power display technology that somehow still seems a bit sci-fi – http://adafruit.com/thinkink
Stop breadboarding and soldering – start making immediately! Adafruit’s Circuit Playground is jam-packed with LEDs, sensors, buttons, alligator clip pads and more. Build projects with Circuit Playground in a few minutes with the drag-and-drop MakeCode programming site, learn computer science using the CS Discoveries class on code.org, jump into CircuitPython to learn Python and hardware together, TinyGO, or even use the Arduino IDE. Circuit Playground Express is the newest and best Circuit Playground board, with support for CircuitPython, MakeCode, and Arduino. It has a powerful processor, 10 NeoPixels, mini speaker, InfraRed receive and transmit, two buttons, a switch, 14 alligator clip pads, and lots of sensors: capacitive touch, IR proximity, temperature, light, motion and sound. A whole wide world of electronics and coding is waiting for you, and it fits in the palm of your hand.
Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !
Could it just be abs(sin(w*t)) ?
I would just go for the actual LED driving signal since that would be more useful for replicating the effect. LED brightness doesn’t correspond linearly to driving current. Also, diffusion material would never smooth or deteriorate the PWM signal. Phosphor, such as used in white LEDs, might smooth it a little.
certainly between 12-20 breaths per minute
Funny that it’s patented. I wonder if that’s why my Dell has such an un-natural, ugly pattern.
It’s probably exp(sin(t)) to correct for the logarithmic response of the rest of the optical system (LED->eye->brain).