Kleidos API Search

In development. It changes without notice.

The firmware

The firmware of the INA228 bench power meter: an ESP32-S3-N16R8 on a DSX063-1 carrier reading a TI INA228 across an R100 shunt, built with ESP-IDF only. It measures what the Kleidos boards draw and speaks SCPI-1999 over the CH343 line at 6 Mbps; The meter's SCPI command set is the protocol, The bench meter firmware — architecture the design, and The Kleidos bench meter says how it is built, flashed and wired.

This part of the site is for changing the firmware: every symbol of firmware/src, by topic. To measure with the instrument, Using the meter takes a session in order (the port, the line, the calibration, the null, a measurement, a capture, the relays, the end state), The meter's SCPI command set is every command and report, and the panel (kleidos-meter serve) is The panel. The host package the panel belongs to is kleidos-meter, the host client, and its Python interface The Python API; both speak to the instrument over the cable, the one interface it has.

The boot

app_main() (Entry point) does the whole boot, in this order: the relay inputs driven to released (every coil off, the DUT on the shunt), the LED blanked, the calibration loaded from its record log (Record logs), the I2C bus and the INA228's bring-up, then the sampler and the console, so that every queue and semaphore both tasks may reach exists before either task does. Each step's reason is in main.cpp's file comment.

The two tasks

  • meter-sample, Core 1 (Sampling): paces and reads the INA228 for the open capture and never prints. A streamed capture hands its samples to the console through a queue, a ring capture writes the TRACE ring, a null accumulates.
  • main, Core 0 (Console), the task ESP-IDF runs app_main() on, which becomes the console once the boot is done and never returns (FW-17): reads UART0 (Console line), parses each program message (SCPI parser), runs its units through the command table, writes the responses and the stream, and owns the relays (Relays) and the calibration (Calibration).

Topics