Building An Astro Imaging Quality Meter
Field Guide #3 · Building an Astro Imaging Quality Meter
One number that tells you whether tonight is worth setting up — measured from your sky.
Forecasts lie. Not always, and not maliciously, but enough that every suburban astrophotographer has lived the same moment: you check the seeing prediction, haul the gear outside, and discover you can barely see Vega. The forecast said average. Your eyes say otherwise. There is no instrument on your table that settles the argument — no single number that takes what the sky is actually doing right now and tells you whether it is worth setting up.
The Astro Imaging Quality meter is my answer to that problem. It started as a simpler question — can I build a sky quality meter that reads directly in Bortle class? — and grew into something more useful: a handheld instrument that measures sky brightness in real time, factors in atmospheric seeing and transparency, and combines all three into a single composite score from 0 to 100. The AIQ score.
What It Measures
The core measurement is sky brightness, read by a TSL2591 high-dynamic-range lux sensor looking through a 3D-printed optical tube that restricts the field of view to 20 degrees — mimicking the geometry of a professional Unihedron SQM-L. An SVBONY UV/IR cut filter at the aperture blocks infrared contamination. The raw lux reading is converted to magnitudes per arc-second squared using a quadratic calibration curve fitted against the SQM-L, then mapped to the Bortle scale.
But sky brightness alone does not answer the imaging question. A perfectly dark sky with terrible seeing produces bloated stars and smeared detail. Clear darkness with poor transparency loses you signal to haze you cannot see. The AIQ score integrates all three factors — measured darkness, seeing, and transparency — into a weighted composite on a 0-to-100 scale where 100 represents pristine Bortle 1 skies with excellent atmospheric conditions.
The Scoring Formula
The AIQ formula weights darkness most heavily because at Bortle 9, light pollution is the dominant constraint. Darkness contributes up to 40 points from the real-time sensor reading. Seeing and transparency each contribute up to 30 points, entered from the forecast before a session. The result is a single number that captures everything relevant to whether tonight is worth the effort.
| Factor | Source | Weight | What it captures |
|---|---|---|---|
| Darkness | TSL2591 sensor (measured) | 0–40 pts |
How much signal you are losing to light pollution — right now, overhead |
| Seeing | Forecast (manual input) | 0–30 pts |
Atmospheric steadiness — star bloat, resolution limits |
| Transparency | Forecast (manual input) | 0–30 pts |
Atmospheric clarity — haze, thin clouds, signal loss |
The Bortle 9 Reality
One of the first things the AIQ revealed is that the darkness score at my site is nearly a constant. Under a clear sky, Park Ridge reads about 17 magnitudes per arc-second squared — which maps to roughly 5 points out of 40. That number does not move much night to night. The light pollution floor is the light pollution floor.
This means my practical AIQ range is roughly 5 to 65, not 0 to 100. The entire dynamic range of the score comes from seeing and transparency — the atmospheric variables that actually change between sessions. On a night with poor seeing and average transparency, the AIQ reads around 20. That is a no-go. On a night with above-average conditions across the board, the score climbs into the low 50s. That is a solid imaging night for Bortle 9. The threshold between no-go and worth-it appears to be somewhere in the high 30s to low 40s — a boundary that is still being refined with field data.
Field validation
The AIQ sensor tracks the SQM-L to within 0.1–0.2 magnitudes per arc-second squared under field conditions, and both instruments respond in lockstep to changing sky conditions — including the real-time detection of thin clouds rolling through. The calibration curve achieves R² = 0.9957 across the full Bortle 1–9 range with a maximum error of 0.14 magnitudes.
The Hardware
The instrument is built around a Raspberry Pi Zero W running a Python script that reads the TSL2591 light sensor, a BME280 environmental sensor for temperature, humidity, and barometric pressure, and drives an Adafruit OLED Bonnet with physical buttons for field control. The optical tube — designed in Onshape and 3D-printed in PLA — restricts the sensor's acceptance angle to 20 degrees, matching the SQM-L's field of view through geometry rather than optics.
Calibration was performed in a dark room using progressive amounts of controlled light to simulate conditions from Bortle 1 through Bortle 9, with the SQM-L providing the reference measurement at each point. The resulting quadratic curve maps raw lux to magnitudes per arc-second squared. A field-adjustable offset parameter fine-tunes the intercept under real sky — currently converging around −0.90 after multiple sessions.
The Display
The OLED screen shows everything you need in the field without a laptop: Bortle class, AIQ score, magnitudes per arc-second squared, temperature, humidity, barometric pressure, dewpoint spread with a dew risk indicator, and the current seeing and transparency settings. It is a complete imaging conditions dashboard in your hand. The display also confirmed what I suspected but had never measured: I am, conclusively, in Bortle 9.
What's in the PDF
Complete parts list and sourcing. Wiring diagram and GPIO pinout. 3D-printed optical tube design with CAD files. Raspberry Pi setup and full Python source code. The calibration methodology — including the bathroom-based technique for simulating Bortle 1 through 9 without leaving your house. Quadratic curve fitting. AIQ scoring formula derivation and weight rationale. Field validation data. Display layout walkthrough. Offset calibration procedure. Environmental sensor integration. And a section on what comes next: reproducibility testing, remote solar-powered station configuration, and phone-based monitoring.
PDF in development — check back soon.
Clear skies / Pete // bortle9astro.com
Part of the Field Guides series · Introduction — Painting with Light You Can't See · Field Guide #1 — HOO Palette Workflow · Field Guide #2 — SHO Palette Workflow