Documented Serial Monitor output does not match what the firmware actually prints
arduino/arduino-instructions.md and AGENTS.md show Serial Monitor examples that don't match arduino/PlantSensors/PlantSensors.ino. A builder following the hardware steps will see different output and may think something is broken.
1. Firmware emits 0–1 fractions, docs show 0–100
The firmware prints normalized fractions:
{"moisture":0.45,"light":1.00}
(updateSensors() uses Serial.print(moisture, 2) and Serial.print(light, 2).)
But the docs show already-scaled values as if they came straight from Serial Monitor:
{"moisture":45,"light":100}
(arduino-instructions.md "What you should see", and AGENTS.md step 6.)
The 0–100 scaling actually happens later in the browser (src/lib/plant/sensors.ts → scaleHardwareFractions), not on the Arduino. The Serial Monitor examples should show fractions, or the text should make clear the 45/100 values are the browser-side representation.
2. light:99 is impossible
arduino-instructions.md includes {"moisture":45,"light":99}. The light sensor is binary; the firmware only ever outputs 0.00 or 1.00 (→ 0 or 100 after scaling). A value of 99 can't occur.
3. "raw value such as 200-400" before calibration
The docs say moisture "may be a larger raw value such as 200-400" before calibration. In normal mode the firmware always normalizes to 0–1; raw ADC counts only appear in calibrate mode.
4. Calibrate-mode output format
The docs show:
Raw: 398 | Calibrating... (type 'calibrate' again to exit)
The firmware actually prints JSON:
5. status doesn't print a firmware version
The serial protocol reference says status prints "firmware version and current settings". The status command prints serial_interval, air_value, and water_value only — there is no version field.
Suggested fix
Align the documented examples with the actual firmware output (fractions, JSON {"raw":...}, no version field, no light:99), or adjust the firmware to match the docs.
Documented Serial Monitor output does not match what the firmware actually prints
arduino/arduino-instructions.mdandAGENTS.mdshow Serial Monitor examples that don't matcharduino/PlantSensors/PlantSensors.ino. A builder following the hardware steps will see different output and may think something is broken.1. Firmware emits 0–1 fractions, docs show 0–100
The firmware prints normalized fractions:
(
updateSensors()usesSerial.print(moisture, 2)andSerial.print(light, 2).)But the docs show already-scaled values as if they came straight from Serial Monitor:
(
arduino-instructions.md"What you should see", andAGENTS.mdstep 6.)The 0–100 scaling actually happens later in the browser (
src/lib/plant/sensors.ts→scaleHardwareFractions), not on the Arduino. The Serial Monitor examples should show fractions, or the text should make clear the 45/100 values are the browser-side representation.2.
light:99is impossiblearduino-instructions.mdincludes{"moisture":45,"light":99}. The light sensor is binary; the firmware only ever outputs0.00or1.00(→ 0 or 100 after scaling). A value of 99 can't occur.3. "raw value such as 200-400" before calibration
The docs say moisture "may be a larger raw value such as 200-400" before calibration. In normal mode the firmware always normalizes to 0–1; raw ADC counts only appear in
calibratemode.4. Calibrate-mode output format
The docs show:
The firmware actually prints JSON:
5.
statusdoesn't print a firmware versionThe serial protocol reference says
statusprints "firmware version and current settings". Thestatuscommand printsserial_interval,air_value, andwater_valueonly — there is no version field.Suggested fix
Align the documented examples with the actual firmware output (fractions, JSON
{"raw":...}, no version field, nolight:99), or adjust the firmware to match the docs.