Projects / Personal / 2026

Pico Latency Tester

A small device that measures the delay between a mouse click and the screen changing.

click screen threshold measured latency
One measurement: the timer starts with the click and stops when the screen's brightness crosses a threshold.

This device measures the time between a mouse click and the screen actually changing. That delay includes the USB connection, the operating system, the game, the graphics card and the monitor, so it's a good way to compare game and display settings. It also checks that something like the MixPad doesn't slow anything down.

How it works

  1. Read the screen's brightness and noise with a light sensor held against the monitor.
  2. Send a click as a 1000 Hz USB mouse and start a microsecond timer.
  3. Stop the timer when the brightness moves past a threshold set from the measured noise.

Each run takes 100 measurements with random pauses in between, so the clicks never line up with the monitor's refresh. The device shows the average and spread on its display, and a Python script can log every measurement to a CSV file.

Why C++

I first planned to use CircuitPython, but its source code showed that it only reports USB input every 8 milliseconds. That would have added up to 8 ms of error to every measurement, so I wrote the firmware in C++ with TinyUSB, which reports every millisecond.