Integration reference for the serial command interface of the EFAS Mini motion sensor (Detection V3). The original document is attached as a PDF.
Connection: USB serial (virtual COM port) — 115200 baud, 8 data bits, no parity, 1 stop bit. Each command is a single line terminated with a newline character (\n). Commands are case-sensitive.
Commands you can send to the sensor
| Command | Example | What it does | Reply |
|---|---|---|---|
getThreshold | getThreshold | Reads the current motion sensitivity threshold. | success: threshold is 0.20 |
setThreshold <value> | setThreshold 0.35 | Sets the motion threshold in m/s². Saved permanently (survives power loss). Lower value = more sensitive. | success: threshold was set to 0.35success: threshold was saved to EEPROM |
resetThreshold | resetThreshold | Restores the factory default threshold of 0.20 m/s². Saved permanently. | success: threshold was reset to 0.2success: threshold was saved to EEPROM |
setDelay <seconds> | setDelay 30 | Stores a backlight delay value that the sensor reports to the display on the next power cycle. | delay was set to 30 seconds, this will be executed after a power cycle |
setDebug <0|1> | setDebug 1 | Turns live sensor logging on (1) or off (0). Diagnostics only — leave off in normal operation. | success: debug mode is enabled |
getAccelerometerRange | — | Reports the accelerometer measuring range. | success: accelerometer range is 2G |
getGyroRange | — | Reports the gyroscope range. | success: gyro range is 500 |
getFilterBandwidth | — | Reports the sensor's filter bandwidth in Hz. | success: filter bandwidth is 21 |
Messages the sensor sends on its own
| Message | Meaning |
|---|---|
forceUserDetection 1 | Motion detected. This is the main output — the display should wake and register a user. Also sent 20 times at startup as a boot handshake. |
setBacklightDelay <value> | Sent once after boot if a delay was configured with setDelay. The stored value is then cleared, so it is sent only once per setDelay. |
ThresholdUp / ThresholdDown | A physical button on the unit was pressed. |
Notes for tuning
- Threshold is the deviation from the running average acceleration, in m/s². Default is
0.2. The valid range is above 0 and below 10 — values outside that are ignored at the next boot and fall back to0.2.- Too many false triggers → increase the value (e.g.
0.3,0.4). - Motion is being missed → decrease the value (e.g.
0.15).
- Too many false triggers → increase the value (e.g.
- After each detection the sensor ignores motion for roughly one second to avoid repeat triggers.
- The onboard LED lights while motion is above the threshold, and flashes 4 times to confirm a setting was saved (once for a query). This is a quick way to check a command landed without a serial monitor.
- Debug mode (
setDebug 1) prints one raw reading per second in the formAccel m/s^2 x,y,z: ... | vec: .... Switch it off withsetDebug 0when finished — it adds serial traffic.
Two points to be aware of when integrating
- Commands are matched as substrings, so any line containing a command name (for example
setThreshold) will trigger it. Make sure the host system does not echo command names back over the same link. setDelayis one-shot: the stored value is consumed and cleared on the next boot, so it must be re-sent for each subsequent power cycle.
Was this article helpful?
That’s Great!
Thank you for your feedback
Sorry! We couldn't be helpful
Thank you for your feedback
Feedback sent
We appreciate your effort and will try to fix the article