Ambient Noise Level Indicator

As part of my work at MACH Acoustics – understanding how internal ambient noise levels affect different environments – I was inspired to create an indicator that shows when noise becomes higher than the base level. Some solutions already exist but they are pricey (because they used calibrated sound level meters), and not very engaging. I wanted something that could sit in a classroom and be a friendly indicator for the teachers and students, bringing the noise back down and perhaps learning something in the process!

The solution is a simple RGB led connected to the PWM outputs of an Arduino and uses Processing with the Minim Library to perform a FFT on the mic input – similar to a couple of other projects.

The operation is best described by the video below and commented code. I’ve added a handy GUI that allows the user to do a number of things:

  • View the mic reading, background sample, instantaneous sample, current colour and sample difference.
  • Change the threshold between colours and benchmark colour.
  • Set continuous sampling, direct LED/mic feedback
  • Resample the background
  • Set the frequency band that is used for the amplitude average – this is useful to demonstrate that it is working and also to ignore low frequency to only show speech for example; screechy children in a classroom!
The control panel when the Java applet is running.
The control panel when the Java applet is running.

Its only a prototype concept at the moment. I’d like to design an enclosure that would suit the particular environment, such as a glowing star or dragon for a classroom.

Continue reading Ambient Noise Level Indicator

MATLAB Finite Difference Time Domain Acoustic Modelling

As part of MACH Acoustics’ open window research, they wanted a FDTD model to visualise sound waves moving through various window opening scenarios. I created a FDTD function, that would create an impulse wave at a specified position then calculate discrete pressure points across a defined grid size and time step. Geometry (boundary conditions) could be loaded loaded into the function using scripts for different objects (opening, top/bottom swing window, baffle, etc), video saved and pressure, mic, time step data saved for repeat plotting (the solver took a few minutes to run so being able to plot existing data saved time). There is no currently no absorption so the sound does not decay, reflecting 100%. For short periods however this does not hinder the visualisation too drastically.

A GUI I created to control the simulation settings.
A GUI I created to control the simulation settings.

The videos below show it in action.

Opening with internal baffle plotted in isometric using surf

Opening with internal baffle plotted in isometric using surf

Laser Cut Battery Powered Bluetooth Speaker

I wanted to create a special birthday present for my girlfriend, whom had no speaker system. I decided a battery powered Bluetooth speaker would be neat, and having just learnt use of the laser cutter I came up with a layered design.

I created a mock up in SketchUp, which I used to visualise the layers together and make sure it would work.
I create a mock up in SketchUp, which I used to visualise the layers together and make sure it would work.

The internals consist of a 2x15W RMS digital amp, 2x15W 80 cones, a Bluetooth module, 1800mAh NiMH battery and a basic fast charger – plus a few voltage regulators to bring everything together. It’s all wired so that you can charge while plugged in and still play, and turn the Bluetooth on and off. Finally it’s all insulated with sheep’s wool I had left from doing my van. I found the insulation helped reduce reverberation (probably due to the thin layers) that muddied the mid-ranges. One thing I like about it is that the front and back can be easily changed: the front grill pattern to change the look and the rear could be tuned to include a bass port for better bass response.

I fairly pleased with the result and might start producing them if there is enough interest.

Audi TT Vent iPhone Mount

A render of my first idea that I created in SketchUp
A render of my first idea that I created in SketchUp

I wanted a place to mount my phone, to use for navigation, a bluetooth music player and handsfree in my Audi TT. The sloping windscreen makes it impossible to mount anything and the curved dashboard makes it difficult there too. Plus I wanted something neat, not a naff eBay mount and also an excuse to toy around in SketchUp.

Continue reading Audi TT Vent iPhone Mount

Boblight Web GUI Control RaspBMC

Boblight GUI Control

Since setting up an boblight on my RaspBMC, I’ve been wanting a nice gui to manage it; turn it on and off, change colours.

I was going to make a plugin to improve my Python knowledge but decided a web plugin would be more flexible as it would be controllable from any device. Using Chris Oattes’ TV Control page as base, I moulded the PHP to be compatible with the standard RaspBMC setup, which currently uses the boblight-dispmanx service. The standard XBMC web server doesn’t support PHP and I couldn’t figure a way of getting it to, so my solution requires setup of another lightweight webserver: lighttpd:

You’ll get an error as lighttpd will try to assign to the default web port 80 but libmicrohttpd will already be running on that. You could disable it but I use for remote control. Instead change the default port to something else, I use 3000:

Change server.port = 80 to 3000. Then sudo service lighttpd force-reload

Set the permissions for the server folder:

Now all that is left is to copy my boblight control page to the /var/www directory:

Visit http://[your raspbmc ip]:3000/boblight to set any static LED colour, disable the dynamic lights or turn off the lights all together. I plan on adding function to edit the boblight.conf settings and implementing some more visual effects.

Boblight with Raspbmc – Ambilight Clone

When I first started seeing the Ambilight (Philips’s lighting system that allows the display to bleed out) clones popping up I knew I wanted to create one myself. The open-source system has been fairly well refined to this point, such that it is pretty much plug and play with Raspbmc (XBMC for the Raspberry Pi). ‘nadnerb’ has already created a tutorial for the process, which I followed, so I won’t go into the process here. This post is just to share my results.

Testing before install to avoid any aggravation!
Testing before install to avoid any aggravation!
I opted for some old trunking to hold the LEDs, held using hot glue. The trunking is stuck using double-sided duck tape.
I opted for some old trunking to hold the LEDs, held using hot glue. The trunking is stuck using double-sided duck tape.

AirPi: DIY Airplay Speakers using Shairport and a Raspberry Pi Updated

My last AirPi post has been popular – and still is – but part of why of like Arch linux is that it is constantly updating so you must be hands on, learning a new part of the OS the hard way!

Since my post a year ago, Shairport has some new features and dependencies, and Arch has moved to the systemd service manager, changing the tutorial process somewhat. In order to update it, I have run through the process with the current build (2013-02-11).

Continue reading AirPi: DIY Airplay Speakers using Shairport and a Raspberry Pi Updated