one button

The one button project was born in yet another attempt to fix social problems through technology. Though this doesn't work most of the time - in this case it might actually work - be it only as yet another social experiment.

Makefu was annoyed by bad music playing in the shack's lounge one too many times and decided he had to do something about it. He came up with the idea to use a pushbutton to just delete that annoying song which is currently running.

Since the internet was in bad shape <insert pic here> and the red glowy button caught our eye we decided to indoctrinate include it in the project.

So the quest began to improve the old internet with some additional features.

Wookie tried hooking up the electronics - but failed miserably - and has not been seen since. We quickly hacked some mosfets that fell out of an old motherboard (those are good sources for N-Channel hexfets) and we learned in the process how to use them - and which type goes along well with a „weak“ source like a raspberry pi pin (50mA max!). The used N-Channel Mosfets irlr7821 can be directly run by a raspberry pi pin and they can be triggered really really fast (like > 9000 times per second).

Maybe you can calculate it like this: Qg (max) = 14nC 14nC/3.3V (pin voltage) = 4.66nF pin current max = 50mA dt = (4,66nF*3,3V)/50mA ergibt dt = 280nS per switch cycle → 560ns periode length → 1.786Mhz max todo: take a freakin' scope and measure the max pin frequency as well as max frequency on the load side. todo: add 30cm ws2811 led stripe and make it a moodlight (or else)

We came up with the idea that there needed to be pain involved in deleting music because otherwise we would end up with no music left. This is similar to the proof of work inside the bitcoin protocol (and everybody loves bitcoins). We scavenged the sirens out of the 'internet' and attached them to the Raspi. So basically you have to weigh whether the music is bad enough for you to endure the sirens. Since they turned out to be too loud(!) running at 12 V we reduced the voltage to 5V thus needing another light for the button - the previously pwm'ed bulb ;-) would only give a faint glow. So we added an led and now the button radiates a nice resemblance of hal.

Some time later the one button received more awesome features: If there is no music playing a short push will start makefu's best liked radiostream. All github pull requests regarding default radiostream may be rejected, deal with it. Also - if you give it a short press while music is playing you will skip to the next song in the playlist.

This is how the state diagram of the one button currently looks like:

In short: - If you push the button less than 5 seconds the song currently playing will be skipped - If you push it longer than 5 seconds the song will be permanently deleted from the Music Library - Within the timeout (1 to 5 seconds) Sirens will be screaming - If no song was running the default stream will be played

one_button.txt · Zuletzt geändert: 2014/01/31 00:03 von excogitation