BUILD WRITE-UP: how I built a personal lighting tool for my own PC. It isn't a product and it isn't for sale or download.

22u.ai · Build write-up

How I built it, step by step.

A music-reactive lighting engine for a Corsair iCUE PC. It listens to whatever is playing and gives the kick, snare, cymbals, vocals, bass and big moments their own places on the case.

IDEA TO LIVE: 10 HRS · SEP 2026
Build write-upPersonal projectDesktop appHardwareAudio analysis
PythonNumPySciPyCorsair iCUE SDKWASAPI loopbackPhilips Hue Entertainment APIClaude

The problem with “loud”

Corsair’s iCUE software has an audio visualizer, but it measures one thing: how loud the music is. In a loud chorus that means every LED stays lit the whole time, and a quiet but busy verse looks the same as the climax. The fans also fill clockwise, which doesn’t read from a desk, where you see most of them edge-on.

The goal: make the case react to what’s actually happening in the music. Kick drums, snares, cymbals, vocals, bass lines and big moments each get their own place on the case, and only a real climax lights everything.

iCUE’s built-in visualizer: lighting follows overall loudness.Click to zoom.

What it drives

PC

Origin PC case, ROG motherboard, MSI GeForce RTX graphics card (not controlled)

Fans

7 × Corsair iCUE LINK RX RGB fans: 3 on top (the radiator), 3 on the front, 1 at the rear, 8 LEDs each

Cooler

Corsair iCUE LINK 360 RX LCD liquid cooler: the pump head has two LED rings (24 inner, 16 outer)

RAM

2 × Corsair VENGEANCE RGB DDR5 sticks, 10 LEDs each

Mouse

Corsair Nightsabre Wireless mouse (12 LEDs)

Hue

Philips Hue: 2 color lamps and 2 Signe gradient floor lamps

Lighting only. Corsair’s SDK can’t change fan or pump speeds, so the tool can never affect cooling.

The first layout plan, drawn before any code was written.Click to zoom.

The build, step by step

01

A plan, not code.

Started by sketching what each part of the case should do and how to tell drums from everything else. The key idea: react to sudden change in each part of the frequency range, not to overall loudness. A wall of distorted guitar is loud but steady; a snare is a sudden jump.

02

The listening engine.

Built an analyzer that splits the music into frequency bands about 94 times a second and detects kicks, snares, hi-hats, crash cymbals, horn and chord stabs, vocals, strings and swells. Before touching real hardware, it was tested against synthetic songs with known drum hits: 39 of 40 kicks, 20 of 20 snares and 4 of 4 crashes found.

03

Asking iCUE what’s there.

iCUE didn’t expose 10 separate devices. It exposed three: one 96-LED ‘LINK System Hub’ holding all seven fans and the pump, one 20-LED device for both RAM sticks, and the mouse. Corsair’s own SDK also crashed on disconnect with current iCUE, so the tool hands lighting back without disconnecting.

04

Calibration.

iCUE reported each fan’s LEDs as a flat row, not a circle, so the tool couldn’t know which way any fan was mounted. A calibration step lights each fan and lets you rotate and flip it until white sits on the glass edge (top fans) or the top of the case (front and rear fans). Every one of 440 simulated mountings resolved to exactly one correct setting.

05

First light.

The live output drives 116 case LEDs at about 57 updates a second. After 8 seconds of silence it hands the lights back to iCUE, so normal effects return when nothing is playing.

06

Tuning on real songs.

Real recordings showed what the synthetic tests couldn’t. On Charlie Puth’s ‘Attention’ the loudness meter sat near 100% the whole song, and soft, subby kicks were being filed as bass notes. The fix was a new layout: drums play on each fan’s glass edge (the part you actually see from the desk), the RAM became one paired meter where height means loudness and color means intensity, and the whole case flashes when the band comes in.

Real 'Attention' audio through the new layout: the verse entry and chorus.Click to zoom.
07

Hearing the beat.

The tool finds the tempo and beat grid by listening (100 BPM for ‘Attention’), learns each song’s kick and snare pattern, and fires those hits about 25 ms early so the lights land with the sound instead of just after it. A drag-and-drop editor made every mapping customizable.

The mapping editor.Click to zoom.
08

Deep bass and rap.

In EDM and rap the deepest bass sits at 20–35 Hz, which the first sub band barely heard. A true 20–60 Hz filter and a bass-drop detector fixed that. Rap consonants were also triggering snares, so snares that land where a song’s pattern never has one are now ignored: false snares in one rap section dropped from 14 to 4 per 4 seconds.

09

Guitar, blues and piano.

In guitar and piano music the mid bands were busy all the time, so the lights just stayed on. Band brightness now follows how each band is moving, custom frequency bands can be defined, a Notes source catches individual piano notes and guitar picks, and a Spectrum can run bottom to top up the three front fans.

10

Everyday use, Hue and the mouse.

A tray icon turns the show on and off and can start with Windows. The mouse joined as another spot. Hue first used individual light commands, which did nothing, because iCUE’s own Hue integration was holding the lights’ entertainment area. With iCUE’s integration off, Hue now streams through the Hue Entertainment API about 40 times a second.

11

Fixing late flashes.

The ‘band comes in’ flash was firing 200–500 ms after the hit, almost a beat late. It now fires on the hit itself, within about 20 ms, and checks a moment later whether the loudness stayed. If it didn’t, the flash is cut short.

12

Being a good citizen on the PC.

After a 2–3 hour session the tray icon froze. A 16-minute soak test showed the music analysis itself stayed steady; the weak points were the parts talking to the outside world. Now every call to iCUE, the audio device and Hue has a time limit, the tray never waits on slow work, the audio device reopens itself after sleep or a device change, a watchdog restarts the show if anything stalls, it runs at below-normal priority, and Quit always finishes within 6 seconds.

13

Taming the room lights.

Once Hue could update 40 times a second, it got everything the case does and turned the room into a strobe. Hue now fades between colors (violent jumps in a busy test went from 79 a minute to 0), stays out of the whole-case flash, and each lamp is its own spot with its own brightness, so one lamp can follow Intensity and another Loudness. Every mapping got four controls: strength, only react above a level, minimum glow, and smoothing.

In my own words: the prompts behind it

Everything was built from plain-language requests like these. Each is my own message, lightly edited for typos, with what it led to.

“Can I get the iCUE lighting effects to work with specific frequencies? I have 7 fans, a CPU cooler, and two RAM sticks, but I don’t know how to set different behavior based on different frequencies.”

→ Led to the idea: follow the music’s changes, not its loudness.

“I only want to control lights based on the music that’s playing. I don’t want to mess with temperatures or anything that could break the machine. LED lights only. … Anything that is just ‘loud’ like some louder EDM and rock music in general just has all the LEDs lit all the time during choruses… they aren’t ‘bumping’ on bass drum kicks or snare hits or cymbal crashes. An ideal situation would be that different types of hits light up different LEDs different colors. … I want to make sure that an actual ‘quiet’ piece of a song isn’t lighting up all the lights just because all the instruments are playing at the same time. … Draw up some ideas and let me know what you’re thinking. Don’t compile anything or create executables; let’s plan out the tool.”

→ Led to the plan, the layout diagram, and a drum detector per kind of hit.

“Use Charlie Puth, ‘Attention’, as an example. Funky bass line. ‘Swelling’ vocals and background. … Tool, ‘Sober’: the intro when the snares come in should really make the lights pop around, but right now they all kind of stay lit because there’s so much other noise on that build-up. … Post Malone, ‘Rockstar’: basically it’s at 100% light the whole time after the intro.”

→ Led to vocal detection, snares that cut through distorted guitar, and a loudness meter relative to each song.

“The top three fans are mostly only visible from the side… Maybe ‘glass side’, ‘motherboard side’… and then for the fans that are oriented the other way, we can stick with top of case / bottom of case / glass side / mobo side?”

→ Led to calibrating every fan against real landmarks, and drums on the glass edges.

“First of all: IT’S WORKING. … Maybe the entire drum kit is mapped out to the FRONT GLASS LEDs on the fans, so we can see that impact on the side window. Then the AMPLITUDE of those things can affect how much of the rest of the fan is lit up. … If it’s loud but only one instrument it’s one color, but if it’s loud and it’s really the climax of the entire orchestra it swells to a warmer color, even red.”

→ Led to the “Kit” layout and the RAM loudness meter colored by intensity.

“Can we make it so that I can actually control what instruments or frequencies are mapped to particular LEDs? It would let me drag and drop instrument types over to the LEDs so that I could make it look the way I want. Also, is there a way you can grab the BPM, either from Tidal or just by listening to the song while it’s playing? That might help you ANTICIPATE the beat.”

→ Led to the drag-and-drop editor and beat prediction that fires hits about 25 ms early.

“Color themes that keep the beat impact but override the colors… so that sometimes if you just want all red for one night but want to keep the beat patterns, you don’t need to change everything.”

→ Led to color themes, including three rainbow modes.

“The intensity was firing too late… it’d be slightly after the big hit, so because it was so late it kind of made the effect useless.”

→ Measured at 200–500 ms late; now fires on the hit itself, within about 20 ms.

“Can you check everything to make sure everything elegantly enters and exits and doesn’t conflict with other things on the computer? Check for memory leaks and runaway processes.”

→ Led to time limits on everything, self-healing, a watchdog, and a Quit that always finishes within 6 seconds.

Under the hood

01

Listen

WASAPI loopback hears whatever Windows is playing: Tidal, YouTube, games.

↓

02

Analyze

FFT and band-pass filters, onset detectors, a beat tracker and a pattern learner. About 94 analyses a second.

↓

03

Map

Routes: any source to any spot, with a style, direction, color, blend and delay. Color themes can recolor everything while keeping the patterns.

↓

04

Light

Corsair iCUE SDK for the case (~57 updates/s) and mouse (~30/s); Hue Entertainment API for the lamps (~40 frames/s); a local tuning page in the browser.

By the numbers

0

case LEDs driven (plus 12 on the mouse and the Hue lamps)

0 / s

music analyses

~0 / s

LED updates to the case

~0 ms

early: predicted kicks and snares

0 → 20 ms

impact flash timing, before and after the fix

0 BPM

tempo found for ‘Attention’ by listening

0

simulated fan mountings checked for calibration

0 s

longest possible quit, even with a hung driver

0 → 0

violent Hue jumps per minute, once fades were added

What it does now

Drag-and-drop light mapping

Any source to any spot: each fan, groups like the front column, the pump’s two rings, the RAM pair, the mouse, Hue lights.

Directions

Lights can start at the glass edge, climb bottom to top of the case, or run rear to front.

Presets and saved layouts

Kit, Spectrum up the front, Guitar & piano, Beat pulse, plus your own named layouts.

Custom frequency bands

Up to 12 bands in any ranges, with ready-made sets for deep bass, guitar and piano, or octaves.

Color themes

Solid colors, song intensity, or three rainbow modes, keeping every hit and pattern.

Beat anticipation

Kicks and snares fire just before they land.

Tray icon

One click on or off; starts with Windows if you want.

Hands everything back

When it stops or nothing is playing, iCUE and Hue return to exactly how they were.

Room lights, tamed

Hue fades, per-lamp brightness, and each lamp as its own spot.

Songs that shaped it

“Attention,” Charlie Puth

the verse entrance, the loudness meter, soft kicks

“Sober,” Tool

snares cutting through a wall of distorted guitar

“Luck Be a Lady,” Frank Sinatra

trumpet stabs and a string intro

“Rockstar,” Post Malone

a steady-loud trap beat that shouldn’t pin the meter at 100%

“Killer Queen,” Queen

finger snaps and piano with no drum kit

“Rhapsody In Blue,” Gershwin

full orchestra and piano arrangement

“Lucille,” B. B. King

the quintessential blues guitarist

Various EDM and rap drops, solo vocalists, and piano recordings

What I learned

  • Loudness isn’t the beat. People hear change, so the lights should follow change.
  • Real recordings beat synthetic tests. Every big fix came from replaying an actual screen recording.
  • Measure before tuning. “The flash feels late” turned out to be 200–500 ms, which pointed straight at the cause.
  • Hardware can describe itself in unexpected ways, like fans reported as flat rows.
  • Only one app can stream to a Hue bridge at a time.

Designed and built in the AI Development Lab via conversation with Claude (Anthropic) Opus 5.5 as a pair programmer. Every change was tested against synthetic songs and real recordings before it shipped.

PC Light Show is a personal build for my own PC; it isn't available to download or buy.

Want something built for your business? Check out Business Buddy.

← More builds at 22u.ai

© 2026 22u.ai