Deployed firmwares hardcode command=0x01 (legacy from when the byte was
named `version`); treating 0x01 as ping would have flagged every existing
frame as a diagnostic. Keep 0x00/0x01 as normal-data and use 0x02 as the
explicit ping trigger.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Le champ `version` (offset 9 du payload NebuleAir Pro 4G) était hardcodé
`0x01` côté firmware et n'a jamais porté un vrai versioning protocole.
Renommé en `command` et réaffecté à un type de trame :
- 0x00 = données mesure
- 0x01 = ping test (firmware → Miotiq → backend, pas d'archivage)
Versioning protocole reste sur `version_major/minor/patch`.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Parsers and formats are tightly linked (a parser produces a format) and
the split made cross-links heavy for a single parser file. Also removed
the confusing "Enveloppe JSON" block in udp-miotiq.md that mixed the
raw webhook wrapper with what the backend actually consumes — the
decoded payload schema lives in json-payload.md and is now referenced
directly.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
formats/json-payload.md: full rewrite around the actual server-side template
(endpoint api.aircarto.com/receive_data?device_type=<model>, flat schema,
_unit suffix companions, -1 and 255 sentinel semantics, full bitfield
tables for error_flags/npm_status/device_status, misc context codes).
formats/iso-pollutant-codes.md: fill in the LCSQA mapping. Fixes my earlier
inversion — ISO_39=PM2.5 and ISO_24=PM10 (not the other way). Add gases:
ISO_03=NO2, ISO_04=CO, ISO_05=H2S, ISO_08=O3, ISO_21=NH3.
parsers/udp-miotiq.md:
- string base function outputs hex (not ASCII) — update description and
generic Python parser accordingly.
- Fix ISO_39/ISO_24 labels in NebuleAir Pro 4G byte layout.
- Name the 5 gases by offset, cross-link bitfield docs and JSON canonical.
- New TODO: origin of latitude/longitude/misc in final JSON (not in 83B
descriptor).
README.md: reflect the new file layout and data flow summary.