Platforms

DTR / RTS on open

Choosing the modem line levels when a port opens.

Many boards (Arduino Uno/Nano, ESP32 dev kits) reset when DTR rises. Choose the levels when opening:

const port = new SerialPort({ path: "/dev/ttyUSB0", baudRate: 115200, dtr: false, rts: false });

Default when not set: unchanged on desktop (Linux and macOS raise DTR on open, Windows does not), asserted on Android. On Linux the kernel still pulses DTR briefly before the setting applies.