PF1550 Driver 0.1.0
API reference
Loading...
Searching...
No Matches
Classes | Functions
Configuration

Limits, acknowledgements, block configurations and validation. More...

Classes

struct  pf1550::RailLimits
 The voltage window and load a rail's consumer tolerates. All zero means "not set". More...
 
struct  pf1550::Limits
 What the application's hardware tolerates. No defaults: Validate() rejects unset ones. More...
 
struct  pf1550::Acknowledgements
 Explicit acknowledgements; every flag defaults to false. More...
 
struct  pf1550::RailModes
 Per-state rail enables (EN, STBY_EN, OMODE, LPWR). More...
 
struct  pf1550::BuckConfig
 A buck regulator. apply = false leaves the block as the chip holds it. More...
 
struct  pf1550::LdoConfig
 An LDO. More...
 
struct  pf1550::VrefDdrConfig
 VREFDDR. More...
 
struct  pf1550::VsnvsConfig
 VSNVS. More...
 
struct  pf1550::CoinCell
 The coin cell charger (Table 111). More...
 
struct  pf1550::UsbPhyConfig
 The USBPHY LDO (Table 165). More...
 
struct  pf1550::LedConfig
 The charger LED driver (Tables 170 and 172). More...
 
struct  pf1550::PowerConfig
 Power control (Tables 135 to 137). More...
 
struct  pf1550::PowerDownConfig
 The power-down order (Tables 139 to 145); needs power_down_order_reviewed. More...
 
struct  pf1550::VbusOptions
 VBUS options (Tables 164, 166, 169). More...
 
struct  pf1550::JeitaConfig
 JEITA thresholds and reductions (Tables 162, 168). More...
 
struct  pf1550::FaultPolicy
 BATFET behaviour per fault; false opens the BATFET (the reset value, the safe one). More...
 
struct  pf1550::BatfetConfig
 The battery FET (Tables 156, 161, 171). More...
 
struct  pf1550::WatchdogConfig
 The charger watchdog. When on, ServiceChargerWatchdog() must run every 16 s or less. More...
 
struct  pf1550::ChargerInterrupts
 Charger interrupt options (Table 167). More...
 
struct  pf1550::ChargerConfig
 The charger. apply = false leaves it as found. Voltage, current and input limit have no default: they must be set when apply is true. More...
 
struct  pf1550::Config
 Everything the driver writes. The constructor stores it with no I/O. More...
 

Functions

constexpr Error pf1550::Validate (const Config &config) noexcept
 Check a configuration without touching the chip.
 
constexpr Limits pf1550::SingleCellLimits () noexcept
 A Limits for a 4.2 V single cell charged at up to 500 mA from a 1 A supply; a starting point whose numbers the application must check against its own cell and supply.
 

Detailed Description

Limits, acknowledgements, block configurations and validation.

Function Documentation

◆ SingleCellLimits()

constexpr Limits pf1550::SingleCellLimits ( )
constexprnoexcept

A Limits for a 4.2 V single cell charged at up to 500 mA from a 1 A supply; a starting point whose numbers the application must check against its own cell and supply.

Returns
The limits; rails are not permitted until their windows are set.

◆ Validate()

constexpr Error pf1550::Validate ( const Config &  config)
constexprnoexcept

Check a configuration without touching the chip.

Fails with InvalidArgument for an unset or insane Limits, a value off the data sheet grid, a reserved code or a value that is not an enumerator; with OutOfLimits for a valid value outside Limits; with ReadOnlyRail for a buck voltage on SW3 or on a buck not declared Dvs::Enabled; with Unsafe for a safety downgrade without its acknowledgement.

Parameters
configThe configuration.
Returns
Error::Ok or the first failure.