Skip to content

Tutorial: First Serial Scan

This tutorial assumes the ESP32-S3 firmware is loaded and the spectrometer is visible as a serial port.

1. Find the Port

macOS usually exposes boards as /dev/tty.usbmodem* or /dev/tty.usbserial*.

ls /dev/tty.usb*

2. Capture One JSON Frame

python tools/read_luxnode_serial.py /dev/tty.usbmodem1101 --command SCAN --out scan.json

3. Inspect With the SDK

luxspec inspect-frame scan.json

4. Capture Calibration Frames

python tools/read_luxnode_serial.py /dev/tty.usbmodem1101 --command DARK --out dark.json
python tools/read_luxnode_serial.py /dev/tty.usbmodem1101 --command WHITE --out white.json
python tools/read_luxnode_serial.py /dev/tty.usbmodem1101 --command SCAN --out sample.json

Treat the first scan after power-up as disposable. The firmware already flushes once, but repeated first-light checks are useful while hardware is changing.