Files
contracts/docs/impl/reports/Z27AG-DECODE-2.md
T

79 lines
5.1 KiB
Markdown
Raw Normal View History

---
type: report
date: 2026-10-15
---
# Z27AG CAN: second pass, against OBD-II and GNSS
Sessions `000007-20261015T192938` and `000008-20261015T200202` (car Orin): doors, tailgate,
bonnet and wipers (checklist step 10–11), then a short drive with GNSS (3D fix, helix antenna)
and OBD-II through the ELM327 on the K-line, all on the Orin's clock. The first time CAN, OBD-II
and GNSS were recorded together. About 30 minutes; 1190 OBD-II samples of each fast value.
## Confirmed
| Signal | Where | Evidence | Registered as |
|---|---|---|---|
| Engine speed | `210` bytes 4–5, BE, 1 rpm (pass 1) | equal to OBD-II `0C`: median ratio 1.0000, median difference 4 rpm, 1190 samples | `engine_rpm` (unchanged) |
| Coolant temperature | `449` byte 2, −40 °C | equal to OBD-II `05` within ±1 °C (median 0.0) over 86–97 °C; no other byte tracks it | `coolant_temp_c` |
| Vehicle speed | `231` bytes 6–7, **little-endian**, **0.0577 km/h per count** | steady cruising (> 15 km/h, GNSS change < 1 km/h over 2 s, 117 fixes): spread 2.6 % against GNSS | `vehicle_speed_kph` |
| Four wheel speeds | `235` four words, **little-endian** (pass 1 left the byte order open) | big-endian misses by 28 km/h rms; little-endian fits. Words 0, 1: 0.0578; words 2, 3: 0.0581 km/h per count against GNSS | not yet: which word is which wheel waits for the jack-stands run (fronts turn, rears stay) |
Scales are against **GNSS**, so they include this car's tyres today. **OBD-II speed reads 3 % low**
against GNSS (0.9706): the ECU's figure is no better a reference than the ABS frames. The two
word pairs of `235` differ by 0.5 %, the usual size of a front/rear tyre difference.
## Doors, tailgate, bonnet, wipers
| Thing | Bit | Notes |
|---|---|---|
| Driver's door | `423.0.4` | its own bit (pass 1); also sets any-door |
| Passenger, rear left, rear right | only `423.2.1` (any door) | no bit of their own |
| Tailgate | only `423.2.1` | with the driver's door open, `423.0.4` cleared on closing it while `423.2.1` stayed set until the tailgate shut |
| Bonnet | nothing | a mechanical latch with no switch, as expected |
| Front wiper running | `423.3.3` | set through "low" and "high"; nothing in a 4 s "interval" window. Medium confidence; also explains pass 1's unexplained `423.3.3` stretch |
## IMU calibration, checked against GNSS
Level from session `000006` (two still stretches, the ground's 1.9° slope cancelled), forward from
`000008` (three stops, one launch; 3512 samples, mean spread 12.7°). The module sits upside down,
about 24° off level, turned so its X axis points forward. Calibrated, the marked stretches read:
| Stretch | IMU longitudinal (0.25 s mean, peak) | GNSS |
|---|---|---|
| Stop, 48 → 0 km/h | −0.35 g | −0.28 g |
| Stop, 45 → 0 | −0.17 g | −0.17 g |
| Stop, 40 → 0 | −0.21 g | −0.18 g |
| Launch | +0.32 g | +0.36 g |
Lateral stays at about 0 in all four: forward is straight ahead. GNSS reports about once a second,
which smooths short peaks.
## Session 000009: lights at night, corners
`z27ag-20261015-203117-lights-corners-drive`: step 9 at night, then a 35-minute errand drive
(no OBD-II: the obd-poller was off after the freeze). References: GNSS and the calibrated IMU.
| Signal | Where | Evidence | Registered as |
|---|---|---|---|
| Main beam | `423.2.7` | set exactly through the marked stretch; also fired once with the other lights off: flash-to-pass | `main_beam` |
| Front fog lamps | `423.2.4` | set exactly through the marked stretch (lights on) | `front_fogs` |
| **Steering wheel angle** | `0C0` bytes 0–1, little-endian, **signed**, **0.1° per count**, positive left | correlation **+0.995** with how sharply the car turns (IMU yaw rate ÷ speed), 1021 s of driving. Lock to lock −479…+471°; with a 2.5 m wheelbase that is a 16.3:1 steering ratio, typical. Straight driving reads −2.7° (camber or alignment) | `steering_angle_deg` (the layout format gained `signed`) |
| Dipped beam? | `423.3.1` | clean in daylight on the 13th; at night it flickers on for 0.1–0.2 s at each switch movement. The cluster has **no dipped-beam lamp** (only side lights, main beam and fogs, no rear fogs), and `423` matches the cluster's lamps, so this bit is probably something else that moves with the lights (illumination, dimming). A walk through Off → Auto → Dim → Main settles it | `dipped_beam` kept, description says so |
**IMU, lateral axis:** lateral g against speed × yaw rate gives a slope of **−0.998** (correlation
−0.91; the sign is right: yaw counts a left turn positive, lateral g counts right positive). With the
stops above, both horizontal axes of the calibration are confirmed.
`149` bytes 1–2 is not a yaw-rate sensor (correlation 0.02 with the IMU's yaw rate).
## Not found
- **Intake air temperature:** no byte of `449` tracks OBD-II `0F` (29–51 °C here).
- `449` bytes 0, 1, 3 move like temperatures but match nothing on OBD-II.
## Notes on the recording
- **The Orin froze mid-drive** (19:59; hardware watchdog reset at 20:01:47), splitting the drive
over two sessions. orin-nano-env-setup has the investigation.
- OBD-II through the ELM gave each fast value about every 2 s (K-line, ~250 ms per request).