Projects

Room Scanner

A bare-metal Raspberry Pi system that batches ultrasonic measurements into a 2D room map.

Illustration of room scanner outputAn illustrative ring of green points around a central sensor on a dark twenty-centimetre grid.
Illustration based on the scanner client

C, AArch64, Raspberry Pi, SDL2

How it works

The freestanding kernel drives a motor with software PWM and records 128 ultrasonic measurements at 100 ms intervals. Distances are capped at two metres, packed with inferred angles, Base64-encoded, and sent over a 9600-baud UART connection. An SDL2 client decodes the completed batch and plots the points in Cartesian space.

Implementation

The scanner extension builds as a freestanding C and AArch64 image linked at 0x80000, with no operating system or standard library underneath it.

Angle is inferred open-loop from sample order rather than measured by an encoder. The prototype sends native packed records as one Base64 batch without a checksum or retry protocol, and the desktop client hard-codes a Windows serial port.

Next: PintOS