FAQ
How does Serilab talk to my hardware over serial?
Serilab works with any board that exposes a USB serial port — Arduino, ESP32, Teensy, Raspberry Pi Pico, Daisy Seed and many more. It connects through the browser's Web Serial API and exchanges plain text, one message per line. There's no binary protocol and nothing board-specific: if your firmware can print a line, it can talk to Serilab.
The example further down uses a Daisy Seed, but the format is identical on every board — only the print/read calls differ (on Arduino you'd use Serial.println(...) and Serial.readStringUntil('\n')).
The rules are simple:
- Every message is a single line terminated by a newline (
\n). - The default baud rate is 115200 (adjustable in the toolbar — it must match your firmware).
- Data uses a
channel:valueformat; debug text uses alog:prefix.
Device → Serilab (what your board sends)
Serilab looks at each incoming line and sorts it into one of three buckets:
| Line your board sends | Where it goes in Serilab |
|---|---|
knob1:64 |
Value 64 is stored under channel knob1 and drives any widget bound to it. Also shown in the Serial log. |
log: booting up… |
Shown in the Debug log (the log: prefix is stripped). Ignored by widgets. |
hello world |
Shown in the Serial log only (no colon = not a channel). |
So the channel name is just the text before the first colon, and the value is everything after it. Bind an output widget (LED, LCD, Scope…) to a channel name and it updates automatically whenever a matching line arrives.
Serilab → Device (what your board receives)
When you move a knob, press a toggle, or run the Performer, Serilab sends the exact same format back to your board:
knob1:64
led1:1
Your firmware just has to read a line and split it on the first :.
Example: Daisy Seed
One concrete board to make it tangible. The same three ideas — send a value, send a debug line, receive a command — map directly to Serial.println() / Serial.readStringUntil('\n') on Arduino, ESP32, Teensy and the rest.
Setup — start the USB serial logger once:
#include "daisy_seed.h"
using namespace daisy;
DaisySeed hw;
int main(void)
{
hw.Init();
hw.StartLog(false); // false = don't wait for a serial terminal
while (1)
{
// ... see below ...
System::Delay(10);
}
}
Send a value to a widget — use the channel:value format:
int knobValue = hw.adc.Get(0) >> 5; // 0–127
hw.PrintLine("knob1:%d", knobValue); // updates the "knob1" channel in Serilab
Send a debug message — prefix it with log::
hw.PrintLine("log: cutoff = %d Hz", cutoff);
hw.PrintLine("log: warning, buffer underrun");
PrintLine appends the \n for you, so the line is complete.
Receive a command from Serilab — read a line and split on the first colon:
// Called for each complete line received from Serilab
void HandleLine(const char* line)
{
const char* colon = strchr(line, ':');
if (!colon) return;
char channel[32];
size_t len = colon - line;
strncpy(channel, line, len);
channel[len] = '\0';
int value = atoi(colon + 1);
if (strcmp(channel, "led1") == 0)
led.Set(value > 0); // e.g. a toggle widget bound to "led1"
}
Good to know
- The USB serial port can only be held by one program at a time. Close your flashing/terminal tool before connecting in Serilab (and vice-versa).
- Serilab keeps the last 500 debug lines and 200 serial lines; older lines scroll off.
- The
log:check is case-insensitive (log:,LOG:,Log:all work).
Is there a ready-made library for the Daisy Seed?
Yes. For the Daisy Seed there's a ready-made, open-source HAL that already handles the channel:value format and reading/writing over serial – you don't have to write the boilerplate yourself. Code and docs: Serilab HAL on GitHub.
For any other board, a simple print / read per line is all you need – see the example above.
Which browsers are supported?
The Web Serial API is supported by Chrome and Edge on desktop. Firefox and Safari do not currently support Web Serial.
What hardware can I use?
Anything that exposes a USB serial port: Arduino, ESP32, Teensy, Raspberry Pi Pico and many more. If your microcontroller has a USB serial connection, it will work with Serilab.
Where are my projects stored?
Locally in the browser (localStorage). Your data never leaves your machine. Projects can also be exported as a file and imported on other devices.
Is Serilab really free?
Yes – completely and without limitations. No account, no subscription, no tracking. If you'd like to support the project, I'd love a coffee on Ko-fi.
Is there a mobile version?
No. Web Serial is only supported on desktop browsers. A mobile version is not currently planned.