Skip to content

Lapilli

Lapilli — Minimal Embedded HAL

Write firmware once. Run it on your laptop, inspect it in the dashboard. Flash it to the chip.

The same C source file runs as a native host process and as MCU firmware. Only the port layer changes — selected at build time, invisible to application code.

examples/blinky/main.c
#include "hal/hal.h"
int main(void) {
lpl_gpio_init();
lpl_gpio_set_mode(LPL_PIN_A0, LPL_GPIO_OUTPUT);
while (1) {
lpl_gpio_write(LPL_PIN_A0, LPL_GPIO_HIGH);
lpl_delay_ms(500);
lpl_gpio_write(LPL_PIN_A0, LPL_GPIO_LOW);
lpl_delay_ms(500);
}
}

Dashboard — two nodes communicating over the simulation bus

$ python3 dashboard/run.py —firmware build/host/multi_node — two MCUs, simulation bus, live event log

One API, many targets

Write against hal.h. The build system picks the port directory — no #ifdef soup in shared code, ever.

Test without hardware

All logic runs as plain host processes. The POSIX port is the primary CI target. Hardware is never a prerequisite.

Live dashboard

Visualize GPIO, UART, ADC, and the simulation bus in real time from a web dashboard.

No overhead

C11. No dynamic allocation. No vendor SDKs in shared code. No feature added “just in case.”