Back to Tech Projects

NeuroBoost

I built an external intelligence layer for a Makeblock mBot cart. A Linux host handles sensing, language inference, and command validation. The cart’s stock mCore firmware handles its ultrasonic sensor, motors, and RGB LEDs over Bluetooth.

Bluetooth telemetry and protocol

The Python adapter opens a Classic Bluetooth Serial Port Profile connection through a Linux RFCOMM tty configured for raw 115,200-baud I/O. It sends Makeblock GET frames, matches responses to request IDs, and decodes firmware strings and ultrasonic readings. The port 3 range probe paused 100 ms between requests and recorded per-read latency and failures in JSON Lines.

Firmware
06.01.007
Successful ultrasonic reads
88 of 88
Round-trip time, median
32.14 ms
Round-trip time, 95th percentile
36.88 ms
Round-trip time, maximum
51.71 ms

Round-trip timing runs through decoding of the matching reply. A Linux pseudoterminal test replayed captured replies and injected a timeout to check the probe’s failure accounting.

Local model and capability checks

Qwen2.5-1.5B-Instruct runs on the host CPU through llama.cpp with Q4_K_M GGUF weights. The read-only planner receives an instruction, the latest front range, and a capability profile. It proposes a skill such as hold or approaching a front object to a specified standoff. A deterministic validator checks the instruction independently and requires the proposed skill to match.

The stock cart can read forward clearance. The profile lacks rear and side clearance and measured travel. A request to stop 30 cm from a front wall can be previewed using range readings. A request to travel exactly 25 cm with a wait fallback resolves to hold because the cart lacks odometry.

The validated simulation passed 48 of 48 attempts across 16 scenarios repeated three times, with 5.20 s median model inference. A separate live preview measured 48.53 cm and produced a plan in 7.22 s. The simulator checks each proposed move against fresh virtual range readings. The live preview reads the physical sensor with motion disabled.

Supervised actuation and optical replies

A separate terminal demo turns short instructions into a bounded sequence of predefined actions. It displays the plan, checks firmware on the same connection, and sends stock dual-motor commands. The host requests zero PWM after each pulse and aborts on an acknowledgment failure. The demo does not use range readings during motion.

Early low-PWM trials got firmware acknowledgments with no visible wheel motion. In a later wheels-raised trial, both wheels turned and stopped after a one-second pulse. The drive and zero-PWM acknowledgments arrived in 21.32 ms and 22.19 ms, respectively. Those timings measure the serial exchange. Physical stopping time and ground travel remain unmeasured, and the stock firmware lacks an independent watchdog for serial motor commands.

The model can also return a short reply for the onboard RGB LEDs. The demo emits Morse code with nominal 200 ms dots and 600 ms dashes. Motor stops can bypass a pending LED acknowledgment.