If you played Call of Duty: Modern Warfare 2, you remember the Heartbeat Sensor—that impossibly useful tactical tablet attached to your rifle that pinged enemies through walls. While detecting actual heartbeats through concrete is still military-grade science fiction, tracking localized human presence is perfectly achievable for airsoft thanks to modern, cheap millimeter-wave radar.

This project is a fully functional, real-time replica of the MW2 Heartbeat Sensor that actively tracks physical human movement and renders it on a stylized, game-accurate UI.

The Hardware: Filtering for Humans The core of the build is the Hi-Link LD2450, a 24GHz two-axis human presence radar module. This sensor continuously emits a 24GHz radio frequency and relies on dual receiving antennas to triangulate the X and Y coordinates of a target. What makes this module brilliant for this specific hack is its onboard microcontroller; it runs firmware specifically designed to filter out ambient noise and only detect human targets. It can simultaneously track up to 3 people within a 120-degree cone at distances up to 6 meters.

The brains of the operation is a Seeed Studio XIAO RP2350. This was selected for its postage-stamp footprint, which easily fits inside the tactical enclosure, and its highly convenient integrated battery charge controller. Everything is visualized on a 2.42" SSD1306/SSD1309 OLED display over I2C, specifically chosen for its blue phosphor that perfectly mimics the aesthetic of the in-game device.

The Hack: Quirks, Pinouts, and Axis Inversions Getting the hardware talking wasn't without its hurdles. The LD2450 communicates over UART at a 256000 baud rate, but the Seeed XIAO threw a curveball: its D0 pin does not actually tie to GPIO 0. Getting data streaming required routing to the correct Serial1 RX/TX pins (D4 and D5).

Once the data was streaming, a bizarre hardware quirk emerged: the Y-axis (distance) tracked perfectly, but the X-axis refused to update. After hours of software debugging, the solution was purely mechanical—the LD2450 sensor physically needed to be rotated by 90 degrees for the axes to track spatial movement correctly. Later, during final assembly, the sensor was accidentally mounted upside down, resulting in a mirrored X-axis. Rather than tearing the glued 3D-printed case apart, this was fixed with a quick software inversion of the axis logic.

Smooth UI and Polar Projection To make the display look authentic without sacrificing performance, the code is surprisingly robust. The system utilizes customized sign-magnitude reading for the LD2450 and an enhanced polar projection logic. This ensures that physical side-to-side movements correctly map over the constraints of the OLED screen.

To keep the UI animations—like the expanding sweep line and decaying radar blips—running at a buttery-smooth ~33 FPS, the radar sensor polling was deliberately decoupled from the draw loop. As a bonus, the HUD features a true proximity alert in the bottom-right corner that displays the exact distance in meters to the closest detected target, complete with a custom boot sequence.

Mechanical Integration The entire package is housed in a custom 3D-printed enclosure. To make it field-ready for airsoft, the case incorporates a friction hinge and an M-LOK mount, allowing it to bolt directly to the side of a rifle's handguard.

(Note: The full source code, libraries, and wiring diagrams are available on the project's GitHub repository, and you can see it in action in the linked video below!)