Ambiguities¶
Places where the datasheet (Rev. 7) is silent, inconsistent or typed wrongly, and what the driver does about each.
The driver is safe under every reading: each row is a documented behaviour, and where the chip could behave in more
than one way the host-test model has a knob (a field of its Readings structure) that runs the other readings, or the
row says that there is none and why. The
numbers C1 to C59 are the ones the tests cite. A reading marked "Resolved" was decided against the
safe side; the rest are open until someone measures the chip.
Table, section and page numbers are the datasheet's own (Table n, S for a section, p for the printed page).
| # | Question (the datasheet is silent or inconsistent) | Resolution, model knob and driver behaviour |
|---|---|---|
| C1 | OTP_SWx_DVS_SEL (Table 31) has no register: DVS mode of SW1/SW2 cannot be read (6.2.2, p28) |
Config declares Dvs::Enabled/Disabled per buck; voltage writes only when declared enabled; model runs both. |
| C2 | SW3 voltage registers "read only because DVS is not supported" (Table 122 to Table 124, 6.3.3): are writes ignored or stored? | Model sw3_write_ignored; driver never writes them. |
| C3 | Interrupt clearing: PMIC STAT bits "Read or Write 1 to clear" (Table 90 note); charger CHG_INT is RW1S in Table 150 and RW1C in the bitmap (Table 175) |
Model knob int_clear {WriteOne, OnRead, Both} (all groups); driver copies the value out first, writes 1 only to reported bits, bounded 3 passes. |
| C4 | RW1S (most charger and rail fields): footnote "Load from OTP fuse, Read, and Write" versus the name "write-1-to-set" |
Model rw1s_set_only (a written 0 does not clear); driver verifies after every write and returns VerifyFailed. |
| C5 | KEY1 is at 0x6F in the bitmap (Table 174 p125); Tables 148 and 149 both print ADDR 0x6B (RC_16MHZ is at 0x6B in the bitmap); CHGR_KEY2 "Reserved" at 0x9F (Table 173); no key sequence or OTP window is documented in Rev. 7 | Resolved: KEY1 = 0x6F (two registers cannot share an address; the table of contents repeats the table error). The model decodes KEY1 at 0x6F and RC_16MHZ at 0x6B; none is exposed. |
| C6 | GOTO_SHIP: Table 138 "any state"; 10.2.3 "in REGS_DISABLE"; Table 83 G takes RUN/STANDBY/SLEEP to REGS_DISABLE on GOTO_SHIP=1, J enters SHIP only if VBUS < 1.0 V (footnote 10), footnote 4 "does not stay"; AN13554 "GOTO_SHIP = 1 and VBUSIN < 1 V". With VBUS valid the data sheet is silent (power-down happens, SHIP is not stated) |
Resolved to the safe reading: EnterShip needs state Run/Standby/Sleep and VBUS below UVLO, refuses with VBUS valid (Contract). Model knob ship_with_vbus {RegsDisableOnly, BitIgnored, ShipsAnyway} runs all three; the session test checks that EnterShip is refused with VBUS valid and writes nothing under each. |
| C7 | GOTO_CORE_OFF: Table 83 I needs VBUS_INVALID and ONKEY = 1; footnotes 8 and 9 say it is set "when system is ON" (secondary processor for other products) |
Model core_off_needs_run; driver EnterCoreOff requires the token, VBUS invalid (VBUS_SNS), ONKEY sense high. |
| C8 | WD_TIME prints "0" for both 80 s and 32 s (Table 161); tWD 80 s typical with ±20 % (Table 12): the shortest possible period is 25.6 s |
Model wd_time_one_is_32s with accuracy; driver services at <= 16 s whichever reading holds and defaults to the reset value. |
| C9 | Watchdog expiry: 8.9.2 says CHG_SNS = 0x0B, Table 154 marks 0x0B Reserved and defines WDT_SNS b5 |
Model wdt_reports_0x0b; driver treats either as expired. |
| C10 | OTP_FLAVOR values 4 to 9 not listed (Table 87 "continues"); A0 "internal validation only" (Table 1 footnote) |
Driver reports the raw byte, a named option only for listed values, never an error; A0 supported by reading with a contract note. |
| C11 | Table 116 is titled "SW1_SLP_VOLT" at 0x36 | Treated as SW1_CTRL1 (consistent with 0x3C, 0x42); register-reference check in Table 04. |
| C12 | Table 141 is titled "SW2_PWRDN_SEQ" at 0x61; table 140 has the same title at 0x60 | Treated as SW3_PWRDN_SEQ (bitmap order); not exposed. |
| C13 | Tables 148 and 149 share ADDR 0x6B | See C5 (resolved to 0x6F). |
| C14 | Charger CHG_INT bits RW1S footnote versus ordinary status: the bit reset condition differs per field (VCOREDIG_RSTB, CHGPOK_RSTB, POR). VBUS_LIN_ILIM is the one driver-written field with CHGPOK_RSTB: an invalid VBUSIN (a cable removal) puts it back to its OTP value (Table 163) |
The model has two events: Reset() (VCOREDIG or POR: every register) and VbusRemoved() (only VBUS_LIN_ILIM). The driver does not use VBUS_LIN_ILIM as evidence of a chip reset (PartialResetBits), so a cable removal is not DeviceReset; the reverted limit is the OTP one: charging is refused when it is above Limits.input_max_ma, and the status reads, the interrupt service and the watchdog service write the configured limit again (once VBUSIN is valid: while it is invalid the model holds the field in reset, env.vbus_limit_held) or switch the charger off (input_limit_ok in SelfCheck()). No other per-field reset condition of a written field is modelled apart from the whole-chip reset. Bench step: remove and restore VBUSIN and read VBUS_INLIM_CNFG. |
| C15 | Reset sources are stated only by the bitmap legend (p122: [1] invalid VCOREDIG, [2] PORB or RESETBMCU, [3] pulse to REGS_DISABLE) and charger "Reset condition" lines; whether an MCU reset leaves PMIC registers unchanged is not stated | No assumption is made. No knob: the model's Reset() is the reset the chip applies (every register to its start-up value), and the driver sees a reset only by a register it changed reading back differently (C59); EnsureInitialized re-reads identity and the as-found check, Configure re-verifies. |
| C16 | Charge parameter change while charging: glitch-free? CHG_OPER 0 to 2 needed to re-latch? | Model knob apply_delay_us (C49) is the delay before a parameter takes effect; no knob for the glitch; driver writes with the charger not in mode 2, CHG_OPER last, verifies (see C49). |
| C17 | PRECHGLB_THRS codes 1 to 3 Reserved, only 2.8 V documented |
Only code 0 encodable. |
| C18 | BOVRC_DISBATFET / BATFET_OC: Table 161 text versus 8.9.6 about what keeps the BATFET closed |
No knob: the driver writes BATFET_OC and BOVRC bits only with the acknowledgement, whichever text is right, and never writes the whole byte from one read (B1). |
| C19 | CHG_CC codes above 1000 mA are labelled Reserved while the feature list says 100 to 1000 mA | Only documented codes encodable; model treats a forced reserved code as no change. |
| C20 | VBUS_LIN_ILIM codes 21 to 31 Reserved; low settings (10 to 50 mA) use the linear low-power mode (8.7.2) | Reserved not encodable. |
| C21 | CHG_SNS reset 1000 (state 8) while the charger registers reset with VCOREDIG_RSTB: first read after reset |
Model initial value; driver never acts on a first read alone. |
| C22 | SILICON_REV: fields METAL 001, FULL 010 give 0x11 (Table 88) but the bitmap reset is 0x08 (FULL_LAYER_REV = 001); all fields "Unused" |
Stored raw, no decision made; model knob silicon_rev_reset {0x11, 0x08}. |
| C23 | USE_DEFAULT_ADDR (Table 147): effect undefined; address 0x08 to 0x0F set by fuses |
Not touched (no knob: the driver never writes the bit, so no reading of its effect is reachable). |
| C24 | DPM default: Table 5 says 4.4 V; Table 164 and Table 62 give reset 000 = 3.90 V; Table 85 gives 3.9 V or 4.5 V per option | Driver always writes its configured dpm_mv and verifies; the model's default is the option's (Table 85); no knob. |
| C25 | EOC_MODE "Unused" in Table 158 but an option in Table 85 (done to linear mode) |
Not exposed (no knob: the driver has no way to write it). |
| C26 | Timer accuracy tacc and tSCIDG 0 to 2 ms: CHG_I and CHG_SNS after a state change |
Driver waits the datasheet maximum before trusting a status; no knob: the model's status registers follow a state change at once. |
| C27 | VBUS_SNS, CHG_SNS and BATT_SNS are separate transfers | Documented non-atomic; consistent flag. |
| C28 | Interrupt category summary (INT_CATEGORY) versus charger page: CHG_INT summarised in b0 only | Model derives the summary from the status bits at once (no knob); ServiceInterrupts loops at most three passes, so a lagging summary is read again. |
| C29 | UVDET and LOW_SYS_WARN are OTP-loaded and writable; Table 137 lists rising and falling thresholds (UVDET 2.65/2.55, 2.8/2.7, 3.0/2.9, 3.⅓.0 V; LOW_SYS_WARN 3.3/3.1 to 3.9/3.7 V). No ambiguity; a wrong UVDET resets the system (Table 83 G) | UVDET guarded by undervoltage_threshold for that reason only. Model uses the table values. |
| C30 | POR_DLY code 001 not defined (Table 135); OTP-loaded |
Not exposed. |
| C31 | LDO load-switch mode (7.2.6): no current limit; does LDOx_FAULTI fire? | Model ls_fault_interrupt; load switch needs a token. |
| C32 | Low-power mode LPWR is for loads below 10 mA (7.x, Table 42); no register enforces it |
low_power requires the acknowledgement load_below_10ma. |
| C33 | SW1/SW2 non-DVS table: 3.30 V for every code 7 to 63 (Table 31) | Driver writes only code 7 for 3.3 V; any code >= 7 decodes to 3.3 V. |
| C34 | DVS done interrupt and settle time (DVSSPEED) not bounded in the register text | Driver waits the DVS-done event or DelayUs maximum; model dvs_done_delay_us. |
| C35 | STBY/SLP voltage registers in non-DVS mode: "read-only and must not be written" (6.2.5) yet marked RW | Never written; model nondvs_write_accepted. |
| C36 | STATE_INFO has codes for WAIT, RUN, STANDBY, SLEEP, REGS_DISABLE only; CORE_OFF and SHIP have no I2C-visible state |
Decoded Unknown otherwise; the model reports no state when system off. |
| C37 | Table 83 lettering skips D | Recorded here only; no matrix row. |
| C38 | PWRON level or edge sensitivity is OTP_PWRON_CFG, not a register |
Declared in Config; model both columns of Table 83. |
| C39 | STANDBYDLY and STANDBYINV effects on pin handling (Table 76) |
StandbyPin hook optional; no knob (the model does not time the pin). |
| C40 | VCOIN 0111 is printed as 3.3 V (Table 111 p91) while the step is 100 mV per LSB from 1.8 V (0111 would be 2.5 V); Table 25 (p22) gives a valid range of 1.8 to 3.3 V, which 16 codes fill with 3.3 V = 1111 |
Adopted reading: step 100 mV, 3.3 V = 1111. Because the printed code differs, codes above 0 need Limits.coin_cell_max_mv >= 3300. No knob: the model stores VCOIN and does not charge a cell; the literal reading is the bench step in docs/datasheet.md. |
| C41 | PWRONDBNC / ONKEYDBNC codes 00 and 01 are identical (Table 136) |
Enum offers 31.25 ms once; both codes decode the same. |
| C42 | TGRESET is a register (Table 135) but 10.4 calls it OTP_TGRESET |
Writing guarded (acknowledgement); no knob (the model accepts the write). |
| C43 | LED_PWM 6-bit field versus duty n/32 (values above 32 undefined) |
Driver encodes 0 to 32 only (no knob: no value above 32 is reachable). |
| C44 | LED_CURRENT only 01 = 6.0 mA valid |
Only 6 mA encodable. |
| C45 | Charger registers all "RW" in the LED/USB blocks but reserved bits RW: reserved bits written 0 or preserved? | Preserved by read-modify-write; test Table 03. |
| C46 | REGTEMP code 3 Reserved (Table 162) |
Not encodable. |
| C47 | IO_DRV0 and IO_DRV1 appear only in the bitmap (Table 174 p125) |
Not exposed; model stores. |
| C48 | Multi-byte reads and auto-increment not described (9.7.2) | Never used (no knob: no multi-byte transfer is reachable; the bus layer refuses one). |
| C49 | Does a charge parameter write take effect at once (C16 timing)? | Model apply_delay; driver verifies by read-back. |
| C50 | SW3_CTRL b4: Table 125 says UNUSED, the bitmap (Table 174 p124) says SW3_DVSSPEED, RW1S; PWRCTRL3 b7:2 and TEMP_INT_MASK0 b3 and b1: tables unused, bitmap RW or reset 1 | Not exposed; reserved bits preserved by read-modify-write; model stores the bitmap type. |
| C51 | Table 112 (SW1_VOLT): VOLT[5:0] and UNUSED[7:5] overlap on bit 5; Table 147 (I2C_ADDR) has no row for bits 6:3; the bitmap prints PWRCTRL2 as "015A" and DEVICE_ID FAMILY as [3:7]; OTP_FLAVOR is [7:0] in Table 87 but [5:0] in the bitmap | Typos recorded; field rows use the table; row FLD-68.GAP_6_3 added; knob none. |
| C52 | Feature list (p2) "battery discharge overcurrent up to 3.0 A" and "6.5 V input operating range" versus Table 14 (2.2, 2.8, 3.2 A typical, 2.0 to 4.0 A range) and Table 5 (VBUS valid from UVLO rising 3.8 to 4.2 V up to OVLO rising 6.0 to 7.0 V: a 6.0 V supply can already be in OVLO) | Driver reports VBUS_OVLO_SNS; the contract states the Table 14 and Table 5 numbers and that a 6.0 V input is not guaranteed valid. |
| C53 | Table 160 CHGCV is not one-to-one: codes 0 to 8 all 3.50 V, 9 to 55 = 3.52 to 4.44 V in 20 mV steps, 56 to 63 all 4.44 V | Only codes 8 to 55 encodable. |
| C54 | Power-up sequencer (section 10.6, Table 85): the slot of a regulator with PWRUP_SEQ = n is not stated; is the number 1 the first slot, and does 0 start in the first slot or never? |
Reading: n starts (n - 1) slots after the first one, 0 starts in the first slot. Model seq0_starts_first; PowerUpDelayUs() follows the reading. |
| C55 | Power-down sequencer (section 10.7): regulators with the same PWRDN_SEQ number: one after the other or together? |
Reading: together, (highest - own) steps of 2 ms (Table 84, tD5). Model and PowerDownDelayUs() follow it. |
| C56 | Power-down sequencer: a regulator with PWRDN_SEQ = 0 while others are non-zero |
Reading: it turns off last, after the highest number's delay. Model seq_order_zero_last; all zero bypasses the sequencer. |
| C57 | Table 85 OTP_SW1_DVS_SEL and OTP_SW2_DVS_SEL are printed in merged cells of a wide table; which option column each value belongs to is read from a text extraction of the PDF, not from the table's grid. The flavour byte of options A4 to A9 is not listed (C10) |
The driver trusts the profile only for the listed options A1 to A3 and refuses a declaration that contradicts it for a block it configures; for any other part (including A0) the declaration stands and a DVS declaration needs Acknowledgements::dvs_on_unlisted_part. Model: the option table. Bench step: read SW1 and SW2 in both modes. |
| C58 | WDTCLR (Table 161) is typed plain RW, "writing 01 clears the watchdog": does the field hold the written value, and does a clear need a 0 to 01 edge? |
The driver writes WDTCLR = 01 and, when it reads 01 back before a service, writes 00 first, so each service is an edge either way; the two bits are not compared in the read-back. Model wdtclr_holds. Bench step: service twice at 8 s and watch CHG_SNS WDT. |
| C59 | PWRUP_I: Table 108 and section 10.6 define it as the completion of the STANDBY to RUN and SLEEP to RUN transitions; no text says that a power-on or a reset sets it, and no other bit is defined as a reset flag | The driver does not use PWRUP_I as a reset flag (it is an ordinary event, also set by a standby wake-up). A reset is seen as hardware lessons 12a asks: after a verified write that changed a register bit, the driver remembers the value, and a changing call first reads the recorded registers back; a difference twice in a row is DeviceReset. A reset that leaves every driver-written bit at its start-up value shows nothing, and needs nothing (the chip holds what the driver wrote). Model knob pwrup_flag_at_reset (default off) runs the reading in which a reset sets PWRUP_I as well; a STANDBY to RUN transition is raised with Raise(0x28, 0). Bench step: read MISC_INT_STAT0 after a power-up and a UVDET reset. |
| C60 | VBUS_LIN_ILIM default: Table 163 gives the reset value 01101 (code 13, 400 mA); the OTP table (OTP_CHG_CFG5) says OTP_CHGR_VBUS_LIN_ILIM "VBUS ILIM = 1500 mA" (code 20). A cable removal puts the field back to its reset condition (CHGPOK_RSTB, C14), so which value comes back is open |
The model uses the OTP value of the option (1500 mA, above the 1 A Limits of the tests), which is the harder case for the driver: the configured limit is written again, or the charger is switched off (OutOfLimits). Under the Table 163 reading (400 mA) the reverted limit is below Limits and the same restore applies. Bench step: remove and restore VBUSIN and read VBUS_INLIM_CNFG. |
How to change a reading¶
- The knob of a row is a field of
pf1550_test::Readingsintests/mock_pf1550.hpp. A test that sets it runs the driver against the other reading. - When a bench measurement settles a row, change the model's default, keep the knob for the other reading, and say so in the changelog.
- Nothing here is verified on hardware.