Lab / Lab 05
Terminal visualiser
When agents run long jobs, I spend a lot of time looking at a terminal. I wanted the pane beside them to move with the music I work to, in a way that actually reflects the track rather than just decorating it. The loop above is two bars of a 174 BPM break, rendered by the visualiser itself.

How it works
The visualiser listens to the computer's audio, splits it into seven frequency bands, and turns each band into a wave that ripples out from its own point on the screen.
- Frequency bands
- 7
- Samples per reading
- 2,048
- Characters in the scale
- 13
The audio is routed through a virtual loopback device, so it hears whatever is playing. Every 2,048 samples it measures how much energy is in each band. The bands are not evenly spaced. They are set where drum & bass actually sits: sub (20–60 Hz) is the bassline's low end, bass is the body of the kick, mid is the crack of the snare, and high and air are the hats and cymbals.
Each band drives a circular wave from a fixed position. The sub comes from the centre and moves slowly, so a long bassline shows up as a slow swell from the middle. The kick comes from the top corners, the snare from the bottom corners and the hats from the top and bottom edges, moving fastest. Where the waves overlap they interfere, and the combined value in each character cell picks a character from a scale that runs from a blank space to a solid @.
Reading a break
These six frames come from two bars. Purple means the bass is louder in that spot, cyan means the drums are, and the blended colour means they're roughly equal.
For this page the unchanged visualiser was fed a generated break (kick, snare, hats and a sub at 174 BPM) instead of the computer's audio, so nothing playing on the machine was captured.






Design decisions
Bass and drums kept apart
The bass bands and drum bands are added up separately, and the colour of each cell comes from whichever is stronger there. That's what lets you see a rolling bassline carry on underneath a busy break.
Position shows frequency
Where something happens on screen tells you which band caused it. Once you know the layout, you read the corners as much as the colours.
Speed follows pitch
Low bands move slowly and high bands move quickly. It matches how the sounds feel, so the motion reads as the music rather than as noise.
Characters, not pixels
Because it's text, it runs in any terminal and font and resizes as the window does. It sits in a pane beside the agents instead of taking over the screen.
Shape over volume
Each frame is scaled to its own range, so a quiet intro still moves. The downside is that a breakdown and a drop look equally busy, which I'd like to change.
No set-up each time
It finds the loopback device on its own. Something I glance at while working can't ask me to configure it every time I open it.
What I learnt
- The maths is the easy part, and the mapping is the design. A frequency analysis takes a few lines of code. Deciding that the sub comes from the centre, the snare from the corners and the hats from the edges is what makes it readable.
- Scaling every frame hides the dynamics. Keeping a slow measure of overall loudness alongside the shape would let a drop feel like a drop. That's the next change.
- Beat detection is a different product. A second, louder version added kick and snare detection with flashes and effects. The launcher I use every day runs the calmer version, because something in the corner of your eye shouldn't flash at you.