Line 796: |
Line 796: |
| ! Offset || Size || Description | | ! Offset || Size || Description |
| |- | | |- |
− | | 0x00 || 0x4 || u32. Input (Sink) current limit in mA | + | | 0x00 || 0x4 || InputCurrentLimit (input/sink current limit in mA) |
| |- | | |- |
− | | 0x04 || 0x4 || u32. Output (Source/Vbus/OTG) current limit in mA | + | | 0x04 || 0x4 || BoostModeCurrentLimit (output/source/vbus/OTG current limit in mA) |
| |- | | |- |
− | | 0x08 || 0x4 || u32. Battery charging current limit in mA | + | | 0x08 || 0x4 || FastChargeCurrentLimit (battery charging current limit in mA) |
| |- | | |- |
− | | 0x0C || 0x4 || u32. Battery charging voltage limit in mV | + | | 0x0C || 0x4 || ChargeVoltageLimit (battery charging voltage limit in mV) |
| |- | | |- |
− | | 0x10 || 0x4 || enum, same as power-role? Always 1 except when OTG where it becomes 2 | + | | 0x10 || 0x4 || [[#ChargerType_2|ChargerType]] |
| |- | | |- |
− | | 0x14 || 0x4 || Bit field (bit8: Enable Battery Charging) | + | | 0x14 || 0x1 || [[#HiZMode|HiZMode]] |
| |- | | |- |
− | | 0x18 || 0x4 || u32. Charging limits state based on battery temperature | + | | 0x15 || 0x1 || [[#BatteryCharging|BatteryCharging]] |
| |- | | |- |
− | | 0x1C || 0x4 || u32. Battery Temperature (milli C) | + | | 0x16 || 0x2 || Reserved |
| |- | | |- |
− | | 0x20 || 0x4 || u32. Capacity now per cent-mille (i.e. 100% = 100000 pcm) | + | | 0x18 || 0x4 || [[#Vdd50State|Vdd50State]] |
| |- | | |- |
− | | 0x24 || 0x4 || u32. Voltage avg in mV | + | | 0x1C || 0x4 || TemperatureCelsius (battery temperature in milli C) |
| |- | | |- |
− | | 0x28 || 0x4 || u32. Battery age (capacity full / capacity design) per cent-mille (i.e. 100% = 100000 pcm) | + | | 0x20 || 0x4 || BatteryChargePercentage (capacity now per cent-mille, i.e. 100% = 100000 pcm) |
| |- | | |- |
− | | 0x2C || 0x4 || enum. Power role (0: Unknown, 1: Sink, 2: Source) | + | | 0x24 || 0x4 || BatteryChargeMilliVoltage (voltage avg in mV) |
| |- | | |- |
− | | 0x30 || 0x4 || enum. [[#Charger]] | + | | 0x28 || 0x4 || BatteryAgePercentage (battery age capacity full/capacity design per cent-mille, i.e. 100% = 100000 pcm) |
| |- | | |- |
− | | 0x34 || 0x4 || u32. Charger voltage limit in mV | + | | 0x2C || 0x4 || [[#UsbPowerRole|UsbPowerRole]] |
| |- | | |- |
− | | 0x38 || 0x4 || u32. Charger current limit in mA | + | | 0x30 || 0x4 || [[#UsbChargerType|UsbChargerType]] |
| |- | | |- |
− | | 0x3C || 0x4 || Bit field (bit0: potentially no hub, bit8: Joy-con charging, bit12: OTG) | + | | 0x34 || 0x4 || ChargerInputVoltageLimit (charger voltage limit in mV) |
| |- | | |- |
− | | 0x40 || 0x14 || | + | | 0x38 || 0x4 || ChargerInputCurrentLimit (charger current limit in mA) |
| + | |- |
| + | | 0x3C || 0x1 || [[#FastBatteryCharging|FastBatteryCharging]] |
| + | |- |
| + | | 0x3D || 0x1 || [[#ControllerPowerSupply|ControllerPowerSupply]] |
| + | |- |
| + | | 0x3E || 0x1 || [[#OtgRequest|OtgRequest]] |
| + | |- |
| + | | 0x3F || 0x1 || Reserved |
| + | |- |
| + | | 0x40 || 0x14 || [17.0.0+] |
| + | |} |
| + | |
| + | == ChargerType == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || ChargeDisable |
| + | |- |
| + | | 1 || ChargeBattery |
| + | |- |
| + | | 2 || Otg |
| + | |} |
| + | |
| + | == HiZMode == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Disable |
| + | |- |
| + | | 1 || Enable |
| + | |} |
| + | |
| + | == BatteryCharging == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Disable |
| + | |- |
| + | | 1 || Enable |
| + | |} |
| + | |
| + | == FastBatteryCharging == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Disable |
| + | |- |
| + | | 1 || Enable |
| + | |} |
| + | |
| + | == ControllerPowerSupply == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Disable |
| + | |- |
| + | | 1 || Enable |
| + | |} |
| + | |
| + | == OtgRequest == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Disable |
| + | |- |
| + | | 1 || Enable |
| + | |} |
| + | |
| + | == UsbPowerRole == |
| + | {| class="wikitable" border="1" |
| + | |- |
| + | ! Value || Name |
| + | |- |
| + | | 0 || Unknown |
| + | |- |
| + | | 1 || Sink |
| + | |- |
| + | | 2 || Source |
| |} | | |} |
| | | |
− | === Charger === | + | == UsbChargerType == |
| {| class="wikitable" border="1" | | {| class="wikitable" border="1" |
| |- | | |- |
Line 838: |
Line 922: |
| | 0 || Unknown | | | 0 || Unknown |
| |- | | |- |
− | | 1 || PD | + | | 1 || Pd |
| |- | | |- |
− | | 2 || Type-C 1.5A | + | | 2 || TypeC15 |
| |- | | |- |
− | | 3 || Type-C 3.0A | + | | 3 || TypeC30 |
| |- | | |- |
− | | 4 || DCP | + | | 4 || Dcp |
| |- | | |- |
− | | 5 || CDP | + | | 5 || Cdp |
| |- | | |- |
− | | 6 || SDP | + | | 6 || Sdp |
| |- | | |- |
− | | 7 || Apple 500mA | + | | 7 || Apple500 |
| |- | | |- |
− | | 8 || Apple 1000mA | + | | 8 || Apple1000 |
| |- | | |- |
− | | 9 || Apple 2000mA | + | | 9 || Apple2000 |
| |} | | |} |
| | | |