Category Archives: electronics

power consumption of the rapsberry pi and the sound board

okay, i have a samsung charger for the first 10.1 inch tablet they had, usb 5.0v, 2.0a. the analyzer however shows 5.37v when nothing is connected. i think that this is even above the rasperry pi’s spec / acceptable voltage, but i have a 1.5m amazon (“premium”) usb cable and i assume that the voltage drops along the way to a non-lethal level.

i’ve connected the edimax wifi usb plug and a tiny mouse and an external, laptop sized mini-keyboard as well as a 7 inch hdmi display (touch controller not connected):

raspberry pi setup with keyboard, mouse and display

raspberry pi setup with keyboard, mouse and display

during boot up and seeking the wifi connectivity, the pi draws 0.33a. same after booting to the linux terminal.

next up: adding my sound board, but only the amplifier connected though the 5v rail of the pi’s gpio. the loudspeaker does a slight whizzing sound, but not hearable from 40cm away. the pi now draws 0.36a after booting when the pi isn’t playing a sound. phew! first boot with the sound board connected survived, so it seems that the wiring is ok or at least not destroying the pi :-D

okay, so i soldered a cut-off usb plug from a recycled old memory stick to the usb edge connector of the prototyping board and plugged it into the last free usb port of the pi.

sound card connected via home made usb cable

sound card connected via home made usb cable

after boot up, the amp meter shows 0.38a and after a while (linux working background?) it settles around 0.40a, which to me means that the sound card actually is connected decently on the power side.

linux command  aplay -l actually lists one usb audio device, yay!

second thing i notice is that there is a acoustic feedback loop when i turn up the volume without playing a sound. interestingly, the power consumption also goes up to 0.57a and the little rainbow colored square appears on the screen (indicating that power supply is shakey afaik).

and now the final test for today:

arecord -D plughw:0,0 -f cd ./test.wav  followed by
aplay ./test.wav


active audio board for raspberry pi

so recently i re-started my activities around the raspberry pi since their upgrade to a quadcore at the same price. i want to do a couple of things with this little fellows, for example hook up an asus xtion (think of a stripped down microsoft kinect) for 3d vision or at least depth processing for the trashbot or his siblings. another cool thing would be to experiment with sound and speech-recognisers as my dream over the last 20 years was to experiment with phone level systems, i.e. a speech recogniser that doesn’t translate human acoustic language into text or words but to their “sound representations” (i.e. how the words sound written down without orthography).

for this purpose i’m building the “babble pi” which should be a “self contained” audio i/o system on the rasperry pi and certainly i’m an addict to minimalism so Continue reading

trashbot 4 fully assembled

trashbot 4 and more

this time it took really long to make more progress on trashbot but i had the feeling that there were many little improvements that made the bot better and somehow it felt like none of them were big enough to be worth a post.

now in the end i learn that quite a lot happened during the last 8 or so weeks and over easter i invested some time also into the cleanup of the software.

first of all, i added shins to the legs so that he wouldn’t swing too much when shifting his weight from one foot to the other. i used some screw / hooks that you use to hang wired lamps and have a tension on the wires:


next i couldn’t resist to Continue reading

preventing a robot from seizures when powering up

during the work on trashbot v1 and rofi, i noticed that robots get seizures when powered up (see the second video in this post for examples). this is obviously because the arduino’s outputs are not in a defined state for a brief time and the servos also get power already leading to outputs sometimes firing until the arduino has loaded its bootloader and executes the user’s code.

some discussions on the arduino forum and on google+ revealed that it might be helpful to add a relay.

so i ordered some JQX-118F relays from that cost 1.95€ and switch by 5 volts.

here’s my first experiment, simply switching switching one led off and the other on. relays usually switch from one contact to another, meaning that even if the relay coil isn’t powered, there is a default state for both switches (one is on, one is off):

next i wanted to document how actually the servo moves into undefined positions when powered up, so that we see that this is a real problem to solve (yeah, i know that the 2s / 7.4v lipo may be too strong for the mg996r servo, will add a ubec soon):

okay, so finally, we add the two together and use one arduino output to control the relay coil, the relay coil then will switch the power to the servos. i will to this for the whole power rail feeding all the servos of the robot so that i only need one relay and one digital out of the arduino nano. let’s see how it works:

i will add the relay now to trashbot v2’s circuit and see whether there will be any more problems afterwards. i’m not sure whether i need something more (apart from the missing ubec to reduce the voltage for the servos) like diodes (coil loosing power gives it back to the arduino? or not strong enough?) or pull up/down resistors (have to teach myself what that’s all about next). but for now, i’m happy to see it working.


deutsches handbuch für das oszilloskop DS203

ich habe soeben meinem schwiegervater das DS203 geschenkt, weil es ein günstiges und kompaktes oszi ist, um die ganzen arduino schaltungen zu debuggen.

dabei haben wir festgestellt, dass es kein deutsches handbuch gibt und ich möchte gerne die deutsche arduino szene unterstützen, also habe ich beschlossen, zummindest wichtige teile des handbuchs zu übersetzen. also grundlage dient dieses englische original. Continue reading