A few times in the past I have seen charts of the dark sky quality for astronomical use. Especially during a visit of the University astronomy department I had the chance to talk with one of the facilities operators. This made me curious about how they quantify the night sky quality.
Upon further research I found the widely used Sky Quality Meter by Unihedron. It is a small box measuring the sky brightness by means of a light sensor with corresponding frequency output. When I could find a distributor selling these sensors for a good price, I was up to building my own one.
My concept was to use a arduino style micro controller and build a sky quality meter together with weather data (temperature, pressure, humidity) recording device. The device should save every 10-30 seconds the data collected. And it should last for at least one whole night running on a small(er) battery like AA or 18650 lithium type.
The hardware part was quite easy to accomplish. I simply had to connect a couple of wires from the micro controller to the sensors and other components. The harder part was to create a proper software, fulfilling all my needs. I had to find a way to
1) cope with the frequency range of 0.01Hz to 1MHz
2) fit all the code within the small memory
3) calculate sky quality and calibrate device to a reference device
Luckily, apart from a reasonably well described device on the Unihedron web-site, I could borrow one Sky Quality Meter from a fellow astronomy club member. So I had a reference device to compare and calibrate my device.
Here is the test setup. The readings are already very close to the original device!