Line 6:
Line 6:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || ShutdownSystem
+
| 0 || [[#ShutdownSystem]]
|-
|-
−
| 1 || RebootSystem
+
| 1 || [[#RebootSystem]]
|-
|-
−
| 2 || GetWakeupReason
+
| 2 || [[#GetWakeupReason]]
|-
|-
−
| 3 || GetShutdownReason
+
| 3 || [[#GetShutdownReason]]
|-
|-
−
| 4 || GetAcOk
+
| 4 || [[#GetAcOk]]
|-
|-
−
| 5 || GetBoardPowerControlEvent
+
| 5 || [[#GetPowerEvent]]
|-
|-
−
| 6 || [2.0.0+] GetSleepButtonState
+
| 6 || [2.0.0-13.2.1] [[#GetSleepButtonState]]
|-
|-
−
| 7 || [2.0.0+] GetPowerEvent
+
| 7 || [2.0.0+] [[#GetPowerButtonEvent]]
|-
|-
−
| 8 || [2.0.0-9.2.0] CreateWakeupTimer
+
| 8 || [2.0.0-9.2.0] [[#CreateWakeupTimer]]
|-
|-
−
| 9 || [2.0.0-9.2.0] CancelWakeupTimer
+
| 9 || [2.0.0-9.2.0] [[#CancelWakeupTimer]]
|-
|-
| 10 || [2.0.0-9.2.0] [[#EnableWakeupTimerOnDevice]]
| 10 || [2.0.0-9.2.0] [[#EnableWakeupTimerOnDevice]]
|-
|-
−
| 11 || [3.0.0-9.2.0] CreateWakeupTimerEx
+
| 11 || [3.0.0-9.2.0] [[#CreateWakeupTimerEx]]
|-
|-
−
| 12 || [3.0.0-9.2.0] GetLastEnabledWakeupTimerType
+
| 12 || [3.0.0-9.2.0] [[#GetLastEnabledWakeupTimerType]]
|-
|-
−
| 13 || [3.0.0-9.2.0] CleanAllWakeupTimers
+
| 13 || [3.0.0-9.2.0] [[#CleanAllWakeupTimers]]
|-
|-
−
| 14 || [6.0.0+] GetPowerButton
+
| 14 || [6.0.0+] [[#GetPowerButton]]
|-
|-
−
| 15 || [10.0.0+]
+
| 15 || [10.0.0+] [[#SetUpRtcResetOnShutdown]]
|}
|}
+
+
== ShutdownSystem ==
+
No input/output.
+
+
== RebootSystem ==
+
No input/output.
+
+
== GetWakeupReason ==
+
No input. Returns an output u32.
+
+
== GetShutdownReason ==
+
No input. Returns an output u32.
+
+
== GetAcOk ==
+
No input. Returns an output bool.
+
+
== GetPowerEvent ==
+
Takes an input [[#BoardPowerControlEventTarget|BoardPowerControlEventTarget]]. Returns an output Event handle.
+
+
== GetSleepButtonState ==
+
No input. Returns an output [[#SleepButtonState|SleepButtonState]].
+
+
== GetPowerButtonEvent ==
+
Takes an input [[#EventTarget|EventTarget]]. Returns an output Event handle.
+
+
== CreateWakeupTimer ==
+
Takes an input u64. Returns an output u32.
+
+
== CancelWakeupTimer ==
+
Takes an input u32. No output.
== EnableWakeupTimerOnDevice ==
== EnableWakeupTimerOnDevice ==
−
No input, returns a total of 0x10-bytes of output. [3.0.0+] Now returns a total of 0xC-bytes of output.
+
No input. Returns an output bool '''IsEnabled''' and an output u64 '''Interval'''.
+
+
[3.0.0+] Now returns an u32 and an u64.
+
+
== CreateWakeupTimerEx ==
+
Takes two input u64s. Returns an output u32.
+
+
== GetLastEnabledWakeupTimerType ==
+
No input. Returns an output u32.
+
+
== CleanAllWakeupTimers ==
+
Takes an input u32. No output.
+
+
== GetPowerButton ==
+
No input. Returns an output bool '''IsPushed'''.
+
+
== SetUpRtcResetOnShutdown ==
+
No input/output. Enables an internal wakeup timer when calling [[#ShutdownSystem|ShutdownSystem]] or [[#RebootSystem|RebootSystem]].
= bpc:r =
= bpc:r =
Line 49:
Line 96:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || GetRtcTime
+
| 0 || [[#GetRtcTime]]
|-
|-
−
| 1 || SetRtcTime
+
| 1 || [[#SetRtcTime]]
|-
|-
−
| 2 || GetRtcResetDetected
+
| 2 || [[#GetRtcResetDetected]]
|-
|-
−
| 3 || [2.0.0+] ClearRtcResetDetected
+
| 3 || [2.0.0+] [[#ClearRtcResetDetected]]
|-
|-
−
| 4 || [3.0.0+] SetUpRtcResetOnShutdown
+
| 4 || [3.0.0+] [[#SetUpRtcResetOnShutdown]]
|}
|}
+
+
== GetRtcTime ==
+
No input. Returns an output u64.
+
+
== SetRtcTime ==
+
Takes an input u64. No output.
+
+
== GetRtcResetDetected ==
+
No input. Returns an output bool.
+
+
== ClearRtcResetDetected ==
+
No input/output.
+
+
== SetUpRtcResetOnShutdown ==
+
No input/output.
= bpc:c =
= bpc:c =
Line 69:
Line 131:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || ShutdownSystem
+
| 0 || [[#ShutdownSystem]]
|-
|-
−
| 1 || RebootSystem
+
| 1 || [[#RebootSystem]]
|-
|-
−
| 2 || GetWakeupReason
+
| 2 || [[#GetWakeupReason]]
|-
|-
−
| 3 || GetShutdownReason
+
| 3 || [[#GetShutdownReason]]
|-
|-
−
| 4 || GetAcOk
+
| 4 || [[#GetAcOk]]
|-
|-
−
| 5 || GetBoardPowerControlEvent
+
| 5 || [[#GetPowerEvent]]
|}
|}
Line 91:
Line 153:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || GetSleepButtonState
+
| 0 || [[#GetSleepButtonState]]
|-
|-
−
| 1 || GetPowerEvent
+
| 1 || [[#GetPowerButtonEvent]]
|}
|}
Line 105:
Line 167:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || CreateWakeupTimer
+
| 0 || [[#CreateWakeupTimer]]
|-
|-
−
| 1 || CancelWakeupTimer
+
| 1 || [[#CancelWakeupTimer]]
|-
|-
| 2 || [[#EnableWakeupTimerOnDevice]]
| 2 || [[#EnableWakeupTimerOnDevice]]
Line 119:
Line 181:
! Cmd || Name
! Cmd || Name
|-
|-
−
| [1.0.0-7.0.1] 0 || SetPowerEnabled
+
| [1.0.0-7.0.1] 0 || [[#SetPowerEnabled]]
|-
|-
−
| [1.0.0-7.0.1] 1 || SetClockEnabled
+
| [1.0.0-7.0.1] 1 || [[#SetClockEnabled]]
|-
|-
−
| [1.0.0-7.0.1] 2 || SetClockRate
+
| [1.0.0-7.0.1] 2 || [[#SetClockRate]]
|-
|-
−
| [1.0.0-7.0.1] 3 || GetClockRate
+
| [1.0.0-7.0.1] 3 || [[#GetClockRate]]
|-
|-
−
| [1.0.0-7.0.1] 4 || GetState
+
| [1.0.0-7.0.1] 4 || [[#GetState]]
|-
|-
−
| [1.0.0-7.0.1] 5 || GetPossibleClockRates
+
| [1.0.0-7.0.1] 5 || [[#GetPossibleClockRates]]
|-
|-
−
| [1.0.0-7.0.1] 6 || SetMinVClockRate
+
| [1.0.0-7.0.1] 6 || [[#SetMinVClockRate]]
|-
|-
−
| [1.0.0-7.0.1] 7 || SetReset
+
| [1.0.0-7.0.1] 7 || [[#SetReset]]
|-
|-
−
| [1.0.0-7.0.1] 8 || SetVoltageEnabled
+
| [1.0.0-7.0.1] 8 || [[#SetVoltageEnabled]]
|-
|-
−
| [1.0.0-7.0.1] 9 || GetVoltageEnabled
+
| [1.0.0-7.0.1] 9 || [[#GetVoltageEnabled]]
|-
|-
−
| [1.0.0-7.0.1] 10 || GetVoltageRange
+
| [1.0.0-7.0.1] 10 || [[#GetVoltageRange]]
|-
|-
−
| [1.0.0-7.0.1] 11 || SetVoltageValue
+
| [1.0.0-7.0.1] 11 || [[#SetVoltageValue]]
|-
|-
−
| [1.0.0-7.0.1] 12 || GetVoltageValue
+
| [1.0.0-7.0.1] 12 || [[#GetVoltageValue]]
|-
|-
−
| [1.0.0-7.0.1] 13 || GetTemperatureThresholds
+
| [1.0.0-7.0.1] 13 || [[#GetTemperatureThresholds]]
|-
|-
−
| [1.0.0-7.0.1] 14 || SetTemperature
+
| [1.0.0-7.0.1] 14 || [[#SetTemperature]]
|-
|-
−
| [1.0.0-5.1.0] 15 || Initialize
+
| [1.0.0-5.1.0] 15 || [[#Initialize]]
|-
|-
−
| [1.0.0-5.1.0] 16 || IsInitialized
+
| [1.0.0-5.1.0] 16 || [[#IsInitialized]]
|-
|-
−
| [1.0.0-5.1.0] 17 || Finalize
+
| [1.0.0-5.1.0] 17 || [[#Finalize]]
|-
|-
−
| [3.0.0-7.0.1] 18 || PowerOn
+
| [3.0.0-7.0.1] 18 || [[#PowerOn]]
|-
|-
−
| [3.0.0-7.0.1] 19 || PowerOff
+
| [3.0.0-7.0.1] 19 || [[#PowerOff]]
|-
|-
−
| [3.0.0-7.0.1] 20 || ChangeVoltage
+
| [3.0.0-7.0.1] 20 || [[#ChangeVoltage]]
|-
|-
−
| [3.0.0-7.0.1] 21 || GetPowerClockInfoEvent
+
| [3.0.0-7.0.1] 21 || [[#GetPowerClockInfoEvent]]
|-
|-
−
| [3.0.0-7.0.1] 22 || GetOscillatorClock
+
| [3.0.0-7.0.1] 22 || [[#GetOscillatorClock]]
|-
|-
−
| [3.0.0-7.0.1] 23 || GetDvfsTable
+
| [3.0.0-7.0.1] 23 || [[#GetDvfsTable]]
|-
|-
−
| [3.0.0-7.0.1] 24 || GetModuleStateTable
+
| [3.0.0-7.0.1] 24 || [[#GetModuleStateTable]]
|-
|-
−
| [3.0.0-7.0.1] 25 || GetPowerDomainStateTable
+
| [3.0.0-7.0.1] 25 || [[#GetPowerDomainStateTable]]
|-
|-
−
| 26 || [3.0.0+] GetFuseInfo
+
| 26 || [3.0.0+] [[#GetFuseInfo]]
|-
|-
−
| 27 || [5.0.0+] GetDramId
+
| 27 || [5.0.0+] [[#GetDramId]]
|-
|-
| [6.0.0-7.0.1] 28 || [[#IsPoweredOn]]
| [6.0.0-7.0.1] 28 || [[#IsPoweredOn]]
Line 180:
Line 242:
|}
|}
−
[7.0.0+] The type-0xA output buffers were replaced with type-0x22 output buffers, for the following: GetDvfsTable, GetModuleStateTable, and GetPowerDomainStateTable.
+
== SetPowerEnabled ==
+
Takes an input [[#Module|ModuleId]] and an input bool '''Enabled'''. No output.
+
+
== SetClockEnabled ==
+
Takes an input [[#Module|ModuleId]] and an input bool '''Enabled'''. No output.
+
+
== SetClockRate ==
+
Takes an input [[#Module|ModuleId]] and an input u32 '''ClockRateHz'''. No output.
+
+
== GetClockRate ==
+
Takes an input [[#Module|ModuleId]]. Returns an output u32 '''ClockRateHz'''.
+
+
== GetState ==
+
Takes an input [[#Module|ModuleId]]. Returns an output [[#ModuleState|ModuleState]].
+
+
== GetPossibleClockRates ==
+
Takes a type-0xA output buffer of [[#ClockRatesListType|ClockRatesListType]], an input [[#Module|ModuleId]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount''' and an output u32 '''OutRates'''.
+
+
== SetMinVClockRate ==
+
Takes an input [[#Module|ModuleId]] and an input u32 '''ClockRateHz'''. No output.
+
+
== SetReset ==
+
Takes an input [[#Module|ModuleId]] and an input bool '''Asserted'''. No output.
+
+
== SetVoltageEnabled ==
+
Takes an input [[#PowerDomain|PowerDomain]] and an input bool '''Enabled'''. No output.
+
+
== GetVoltageEnabled ==
+
Takes an input [[#PowerDomain|PowerDomain]]. Returns an output bool '''Enabled'''.
+
+
== GetVoltageRange ==
+
Takes an input [[#PowerDomain|PowerDomain]]. Returns three output s32s '''MinVolt''', '''MaxVolt''' and '''StepVolt'''.
+
+
== SetVoltageValue ==
+
Takes an input [[#PowerDomain|PowerDomain]] and an input s32 '''MicroVolt'''. No output.
+
+
== GetVoltageValue ==
+
Takes an input [[#PowerDomain|PowerDomain]]. Returns an output s32 '''MicroVolt'''.
+
+
== GetTemperatureThresholds ==
+
Takes a type-0xA output buffer of [[#TemperatureThreshold|TemperatureThreshold]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
+
+
== SetTemperature ==
+
Takes an input s32 '''TemperatureMilliC'''. No output.
+
+
== Initialize ==
+
No input/output.
+
+
== IsInitialized ==
+
No input. Returns an output bool.
+
+
== Finalize ==
+
No input/output.
+
+
== PowerOn ==
+
Takes an input [[#PowerControlTarget|PowerControlTarget]] and an input s32 '''MicroVolt'''. No output.
+
+
== PowerOff ==
+
Takes an input [[#PowerControlTarget|PowerControlTarget]]. No output.
+
+
== ChangeVoltage ==
+
Takes an input [[#PowerControlTarget|PowerControlTarget]] and an input s32 '''MicroVolt'''. No output.
+
+
== GetPowerClockInfoEvent ==
+
No input. Returns an output Event handle.
+
+
== GetOscillatorClock ==
+
No input. Returns an output u32.
+
+
== GetDvfsTable ==
+
Takes two type-0xA output buffers and two input s32s. Returns an output s32 '''OutCount'''.
+
+
[7.0.0+] The type-0xA output buffers were replaced with type-0x22 output buffers.
+
+
== GetModuleStateTable ==
+
Takes a type-0xA output buffer of [[#ModuleState|ModuleState]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
+
+
[7.0.0+] The type-0xA output buffer was replaced with a type-0x22 output buffer.
+
+
== GetPowerDomainStateTable ==
+
Takes a type-0xA output buffer of [[#PowerDomainState|PowerDomainState]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
+
+
[7.0.0+] The type-0xA output buffer was replaced with a type-0x22 output buffer.
+
+
== GetFuseInfo ==
+
Takes a type-0xA output buffer and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
+
+
== GetDramId ==
+
No input. Returns an u32.
== IsPoweredOn ==
== IsPoweredOn ==
−
Takes a [[#PowerDomain|PowerDomain]] and returns a bool indicating the status of the requested voltage block.
+
Takes an input [[#PowerControlTarget|PowerControlTarget]]. Returns an output bool.
== GetVoltage ==
== GetVoltage ==
−
Takes a [[#PowerDomain|PowerDomain]] and returns an u32 voltage value for the requested voltage block.
+
Takes an input [[#PowerControlTarget|PowerControlTarget]]. Returns an output s32.
= pcv:arb =
= pcv:arb =
Line 197:
Line 347:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || ReleaseControl
+
| 0 || [[#ReleaseControl]]
|}
|}
+
+
== ReleaseControl ==
+
Takes an input [[#Module|ModuleId]]. No output.
= pcv:imm =
= pcv:imm =
Line 209:
Line 362:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || SetClockRate
+
| 0 || [[#SetClockRate]]
|}
|}
Line 221:
Line 374:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || [[#OpenSession]]
+
| 0 || [[#OpenSession|OpenSession]]
|-
|-
−
| 1 || GetTemperatureThresholds
+
| 1 || [[#GetTemperatureThresholds|GetTemperatureThresholds]]
|-
|-
−
| 2 || SetTemperature
+
| 2 || [[#NotifyTemperature|NotifyTemperature]]
|-
|-
−
| 3 || GetPossibleClockRates
+
| 3 || [[#GetClkrstStateTable|GetClkrstStateTable]]
|-
|-
−
| 4 || GetClockInfoEvent
+
| 4 || [[#GetClkrstStateTableUpdateEvent|GetClkrstStateTableUpdateEvent]]
|-
|-
−
| 5 || GetClockModuleNumLimit
+
| 5 || [[#GetClkrstStateTableCount|GetClkrstStateTableCount]]
+
|-
+
| 6 || [15.0.0+] PrintClockTree
|}
|}
== OpenSession ==
== OpenSession ==
−
Takes a [[#Module|DeviceCode]] and an u32. Returns an [[#IClkrstSession]].
+
Takes an input [[#Module|DeviceCode]] and an input u32. Returns an [[#IClkrstSession]].
−
== GetClockModuleNumLimit ==
+
== NotifyTemperature ==
−
Returns 0x1A.
+
Takes an input float. No output.
+
+
== GetClkrstStateTable ==
+
Takes a type-0xA output buffer of [[#ModuleState|ModuleState]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
+
+
[7.0.0+] The type-0xA output buffer was replaced with a type-0x22 output buffer.
+
+
== GetClkrstStateTableUpdateEvent ==
+
No input. Returns an output Event handle.
+
+
== GetClkrstStateTableCount ==
+
No input. Returns 0x1A.
== IClkrstSession ==
== IClkrstSession ==
Line 247:
Line 413:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || SetClockEnabled
+
| 0 || EnableClock
|-
|-
−
| 1 || SetClockDisabled
+
| 1 || DisableClock
|-
|-
−
| 2 || SetResetAsserted
+
| 2 || AssertReset
|-
|-
−
| 3 || SetResetDeasserted
+
| 3 || DeassertReset
|-
|-
−
| 4 || SetPowerEnabled
+
| 4 || EnablePower
|-
|-
−
| 5 || SetPowerDisabled
+
| 5 || DisablePower
|-
|-
−
| 6 || GetState
+
| 6 || GetModuleState
|-
|-
| 7 || SetClockRate
| 7 || SetClockRate
Line 265:
Line 431:
| 8 || GetClockRate
| 8 || GetClockRate
|-
|-
−
| 9 || SetMinVClockRate
+
| 9 || SetMinimumVoltageClockRate
|-
|-
| 10 || GetPossibleClockRates
| 10 || GetPossibleClockRates
|-
|-
| 11 || GetDvfsTable
| 11 || GetDvfsTable
+
|-
+
| 12 || [14.0.0+] IsParentClock
+
|-
+
| 13 || [14.0.0+] SetParentClock
+
|-
+
| 14 || [18.0.0+]
+
|-
+
| 15 || [18.0.0+]
|}
|}
Line 281:
Line 455:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || [[#ReleaseControl]]
+
| 0 || [[#ReleaseControl_2|ReleaseControl]]
|}
|}
== ReleaseControl ==
== ReleaseControl ==
−
Takes a [[#Module|Module]]. No output.
+
Takes an input [[#Module|DeviceCode]]. No output.
= rgltr =
= rgltr =
Line 296:
Line 470:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || [[#OpenSession]]
+
| 0 || [[#OpenSession_2|OpenSession]]
|-
|-
−
| 1 || GetPowerDomainStateTable
+
| 1 || [[#GetRegulatorStateTable|GetRegulatorStateTable]]
|-
|-
−
| 2 || GetPowerInfoEvent
+
| 2 || [[#GetRegulatorStateTableUpdateEvent|GetRegulatorStateTableUpdateEvent]]
|-
|-
−
| 3 || GetPowerModuleNumLimit
+
| 3 || [[#GetRegulatorStateTableCount|GetRegulatorStateTableCount]]
|}
|}
== OpenSession ==
== OpenSession ==
−
Takes a [[#PowerDomain|DeviceCode]] and returns an [[#IRegulatorSession]].
+
Takes an input [[#PowerDomain|DeviceCode]] and returns an [[#IRegulatorSession]].
+
+
== GetRegulatorStateTable ==
+
Takes a type-0xA output buffer of [[#PowerDomainState|PowerDomainState]] and an input s32 '''MaxCount'''. Returns an output s32 '''OutCount'''.
−
== GetPowerModuleNumLimit ==
+
[7.0.0+] The type-0xA output buffer was replaced with a type-0x22 output buffer.
−
Returns 0x3.
+
+
== GetRegulatorStateTableUpdateEvent ==
+
No input. Returns an output Event handle.
+
+
== GetRegulatorStateTableCount ==
+
No input. Returns 0x3.
== IRegulatorSession ==
== IRegulatorSession ==
Line 318:
Line 500:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || [[#SetVoltageEnabled]]
+
| 0 || RequestOutput
|-
|-
−
| 1 ||
+
| 1 || CancelOutputRequest
|-
|-
−
| 2 || [[#GetVoltageEnabled]]
+
| 2 || IsOutputEnabled
|-
|-
−
| 3 || GetVoltageRange
+
| 3 || GetVoltageRangeInMicroVolt
|-
|-
−
| 4 || GetVoltageValue
+
| 4 || GetVoltageInMicroVolt
|-
|-
−
| 5 || [[#SetVoltageValue]]
+
| 5 || RequestVoltageInMicroVolt
|-
|-
−
| 6 || ChangeVoltage
+
| 6 || CancelVoltageRequest
+
|-
+
| 7 || [13.0.0+] [[#GetMinimumOffStateHoldTime|GetMinimumOffStateHoldTime]]
+
|-
+
| 8 || [13.0.0+] [[#RequestMinimumOffStateHoldTime|RequestMinimumOffStateHoldTime]]
+
|-
+
| 9 || [13.0.0+] [[#CancelMinimumOffStateHoldTimeRequest|CancelMinimumOffStateHoldTimeRequest]]
|}
|}
−
=== SetVoltageEnabled ===
+
=== GetMinimumOffStateHoldTime ===
−
Takes a bool. Enables/disables the LDO this session was opened for.
+
No input. Returns an output u64.
−
=== GetVoltageEnabled ===
+
=== RequestMinimumOffStateHoldTime ===
−
Returns a bool. True if voltage is enabled, false if not.
+
Takes an input u64. No output.
−
=== SetVoltageValue ===
+
=== CancelMinimumOffStateHoldTimeRequest ===
−
Takes in a voltage in microvolts and sets the LDO to this voltage.
+
No input/output.
= rtc =
= rtc =
+
This is "nn::rtc::IRtcManager".
+
This was added with [8.0.0+].
This was added with [8.0.0+].
Line 349:
Line 539:
! Cmd || Name
! Cmd || Name
|-
|-
−
| 0 || [[#GetRtcTime]]
+
| 0 || [[#GetTimeInSeconds|GetTimeInSeconds]]
+
|-
+
| 1 || [[#SetTimeInSeconds|SetTimeInSeconds]]
+
|-
+
| 2 || [[#SetResetOnShutdown|SetResetOnShutdown]]
|-
|-
−
| 1 || [[#SetRtcTime]]
+
| 3 || [[#GetResetDetected|GetResetDetected]]
|-
|-
−
| 2 || [[#SetUpRtcResetOnShutdown]]
+
| 4 || [[#ClearResetDetected|ClearResetDetected]]
|-
|-
−
| 3 || [[#GetRtcResetDetected]]
+
| 10 || [10.0.0+] [[#EnableAlarm|EnableAlarm]]
|-
|-
−
| 4 || [[#ClearRtcResetDetected]]
+
| 11 || [10.0.0+] [[#DisableRtcAlarm|DisableRtcAlarm]]
|-
|-
−
| 10 || [10.0.0+]
+
| 12 || [18.0.0+]
|-
|-
−
| 11 || [10.0.0+]
+
| 13 || [18.0.0+]
|}
|}
−
== GetRtcTime ==
+
== GetTimeInSeconds ==
−
Same as GetRtcTime from [[#bpc:r|bpc:r]], but takes an extra [[Bus_services#I2cDevice|DeviceCode]], which [[#bpc:r|bpc:r]] hardcodes to 0x3B000001 (max77620_rtc0) instead.
+
Same as [[#GetRtcTime|GetRtcTime]], but takes an input [[Bus_services#I2cDevice|DeviceCode]] ([[#bpc:r|bpc:r]] uses hardcoded value 0x3B000001).
+
+
== SetTimeInSeconds ==
+
Same as [[#SetRtcTime|SetRtcTime]], but takes an input [[Bus_services#I2cDevice|DeviceCode]] ([[#bpc:r|bpc:r]] uses hardcoded value 0x3B000001).
+
+
== SetResetOnShutdown ==
+
Takes an input bool '''DoReset''' and an input [[Bus_services#I2cDevice|DeviceCode]]. Similar to [[#SetUpRtcResetOnShutdown|SetUpRtcResetOnShutdown]], but this version assigns the provided boolean value on a per-client basis (instead of a global variable) and checks it when the current [[PSC_services#Power_Management_States|power state]] is '''ReadyShutdown'''.
−
== SetRtcTime ==
+
== GetResetDetected ==
−
Same as SetRtcTime from [[#bpc:r|bpc:r]], but takes an extra [[Bus_services#I2cDevice|DeviceCode]], which [[#bpc:r|bpc:r]] hardcodes to 0x3B000001 (max77620_rtc0) instead.
+
Same as [[#GetRtcResetDetected|GetRtcResetDetected]], but takes an input [[Bus_services#I2cDevice|DeviceCode]] ([[#bpc:r|bpc:r]] uses hardcoded value 0x3B000001).
−
== SetUpRtcResetOnShutdown ==
+
== ClearResetDetected ==
−
Takes an u8 '''DoReset''' and a [[Bus_services#I2cDevice|DeviceCode]]. Similar to SetUpRtcResetOnShutdown from [[#bpc:r|bpc:r]], but this version assigns the provided boolean value on a per-client basis (instead of a global variable) and checks it when the current [[PSC_services#Power_Management_States|power state]] is "ReadyShutdown".
+
Same as [[#ClearRtcResetDetected|ClearRtcResetDetected]], but takes an input [[Bus_services#I2cDevice|DeviceCode]] ([[#bpc:r|bpc:r]] uses hardcoded value 0x3B000001).
−
== GetRtcResetDetected ==
+
== EnableAlarm ==
−
Same as GetRtcResetDetected from [[#bpc:r|bpc:r]], but takes an extra [[Bus_services#I2cDevice|DeviceCode]], which [[#bpc:r|bpc:r]] hardcodes to 0x3B000001 (max77620_rtc0) instead.
+
Takes an input [[#Module|DeviceCode]], an input u32 '''RtcAlarmId''' (0 = RtcAlarm1, 1 = RtcAlarm2) and an u64 '''RtcAlarmTime'''. No output.
−
== ClearRtcResetDetected ==
+
== DisableAlarm ==
−
Same as ClearRtcResetDetected from [[#bpc:r|bpc:r]], but takes an extra [[Bus_services#I2cDevice|DeviceCode]], which [[#bpc:r|bpc:r]] hardcodes to 0x3B000001 (max77620_rtc0) instead.
+
Takes an input [[#Module|DeviceCode]] and an input u32 '''RtcAlarmId''' (0 = RtcAlarm1, 1 = RtcAlarm2). No output.
= time:u, time:a, time:s =
= time:u, time:a, time:s =
Line 386:
Line 586:
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
−
! Cmd || Name || Notes
+
! Cmd || Name
|-
|-
−
| 0 || GetStandardUserSystemClock || Returns an [[#ISystemClock]].
+
| 0 || [[#GetStandardUserSystemClock]]
|-
|-
−
| 1 || GetStandardNetworkSystemClock || Returns an [[#ISystemClock]].
+
| 1 || [[#GetStandardNetworkSystemClock]]
|-
|-
−
| 2 || GetStandardSteadyClock || Returns an [[#ISteadyClock]].
+
| 2 || [[#GetStandardSteadyClock]]
|-
|-
−
| 3 || GetTimeZoneService || Returns an [[#ITimeZoneService]].
+
| 3 || [[#GetTimeZoneService]]
|-
|-
−
| 4 || GetStandardLocalSystemClock || Returns an [[#ISystemClock]].
+
| 4 || [[#GetStandardLocalSystemClock]]
|-
|-
−
| 5 || [4.0.0+] GetEphemeralNetworkSystemClock || Returns an [[#ISystemClock]].
+
| 5 || [4.0.0+] [[#GetEphemeralNetworkSystemClock]]
|-
|-
−
| 20 || [6.0.0+] GetSharedMemoryNativeHandle ||
+
| 20 || [6.0.0+] GetSharedMemoryNativeHandle
|-
|-
−
| 30 || [6.0.0+] GetStandardNetworkClockOperationEventReadableHandle ||
+
| 30 || [6.0.0+] GetStandardNetworkClockOperationEventReadableHandle
|-
|-
−
| 31 || [6.0.0+] GetEphemeralNetworkClockOperationEventReadableHandle ||
+
| 31 || [6.0.0+] GetEphemeralNetworkClockOperationEventReadableHandle
|-
|-
−
| 50 || [4.0.0+] SetStandardSteadyClockInternalOffset ||
+
| 50 || [4.0.0+] SetStandardSteadyClockInternalOffset
|-
|-
−
| 100 || IsStandardUserSystemClockAutomaticCorrectionEnabled ||
+
| 100 || IsStandardUserSystemClockAutomaticCorrectionEnabled
|-
|-
−
| 101 || SetStandardUserSystemClockAutomaticCorrectionEnabled ||
+
| 101 || SetStandardUserSystemClockAutomaticCorrectionEnabled
|-
|-
−
| 102 || [5.0.0+] GetStandardUserSystemClockInitialYear ||
+
| 102 || [5.0.0+] GetStandardUserSystemClockInitialYear
|-
|-
−
| 200 || [3.0.0+] IsStandardNetworkSystemClockAccuracySufficient ||
+
| 200 || [3.0.0+] IsStandardNetworkSystemClockAccuracySufficient
|-
|-
−
| 201 || [6.0.0+] GetStandardUserSystemClockAutomaticCorrectionUpdatedTime ||
+
| 201 || [6.0.0+] GetStandardUserSystemClockAutomaticCorrectionUpdatedTime
|-
|-
−
| 300 || [4.0.0+] CalculateMonotonicSystemClockBaseTimePoint ||
+
| 300 || [4.0.0+] CalculateMonotonicSystemClockBaseTimePoint
|-
|-
−
| 400 || [4.0.0+] GetClockSnapshot ||
+
| 400 || [4.0.0+] GetClockSnapshot
|-
|-
−
| 401 || [4.0.0+] GetClockSnapshotFromSystemClockContext ||
+
| 401 || [4.0.0+] GetClockSnapshotFromSystemClockContext
|-
|-
−
| 500 || [4.0.0+] CalculateStandardUserSystemClockDifferenceByUser ||
+
| 500 || [4.0.0+] CalculateStandardUserSystemClockDifferenceByUser
|-
|-
−
| 501 || [4.0.0+] CalculateSpanBetween ||
+
| 501 || [4.0.0+] CalculateSpanBetween
|}
|}
+
+
== GetStandardUserSystemClock ==
+
No input. Returns an [[#ISystemClock]].
+
+
== GetStandardNetworkSystemClock ==
+
No input. Returns an [[#ISystemClock]].
+
+
== GetStandardSteadyClock ==
+
No input. Returns an [[#ISteadyClock]].
+
+
== GetTimeZoneService ==
+
No input. Returns an [[#ITimeZoneService]].
+
+
== GetStandardLocalSystemClock ==
+
No input. Returns an [[#ISystemClock]].
+
+
== GetEphemeralNetworkSystemClock ==
+
No input. Returns an [[#ISystemClock]].
== ISteadyClock ==
== ISteadyClock ==
Line 434:
Line 652:
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
−
! Cmd || Name || Notes
+
! Cmd || Name
|-
|-
−
| 0 || GetCurrentTimePoint || No input, returns an output [[#SteadyClockTimePoint]].
+
| 0 || [[#GetCurrentTimePoint]]
|-
|-
−
| 2 || GetTestOffset || No input, returns an output [[#TimeSpanType]].
+
| 2 || [[#GetTestOffset]]
|-
|-
−
| 3 || SetTestOffset || Takes an input [[#TimeSpanType]], no output.
+
| 3 || [[#SetTestOffset]]
|-
|-
−
| 100 || [2.0.0+] GetRtcValue || No input, returns an output s64.
+
| 100 || [2.0.0+] [[#GetRtcValue]]
|-
|-
−
| 101 || [2.0.0+] IsRtcResetDetected || No input, returns an output u8 bool.
+
| 101 || [2.0.0+] [[#IsRtcResetDetected]]
|-
|-
−
| 102 || [2.0.0+] GetSetupResultValue || No input, returns an output u32.
+
| 102 || [2.0.0+] [[#GetSetupResultValue]]
|-
|-
−
| 200 || [3.0.0+] GetInternalOffset || No input, returns an output [[#TimeSpanType]].
+
| 200 || [3.0.0+] [[#GetInternalOffset]]
|-
|-
−
| 201 || [3.0.0-3.0.2] SetInternalOffset || Takes an input [[#TimeSpanType]], no output.
+
| 201 || [3.0.0-3.0.2] [[#SetInternalOffset]]
|}
|}
−
=== SteadyClockTimePoint ===
+
=== GetCurrentTimePoint ===
−
{| class="wikitable" border="1"
+
No input. Returns an output [[#SteadyClockTimePoint]].
−
|-
+
−
! Offset || Size || Description
+
=== GetTestOffset ===
−
|-
+
No input. Returns an output [[#TimeSpanType]].
−
| 0x0 || 0x8|| A u64 representing a point in time.
+
−
|-
+
=== SetTestOffset ===
−
| 0x8 || 0x10 || An ID representing the clock source.
+
Takes an input [[#TimeSpanType]]. No output.
−
|}
+
+
=== GetRtcValue ===
+
No input. Returns an output s64.
+
+
=== IsRtcResetDetected ===
+
No input. Returns an output u8 bool.
+
+
=== GetSetupResultValue ===
+
No input. Returns an output u32.
−
This is a 0x18-byte struct.
+
=== GetInternalOffset ===
+
No input. Returns an output [[#TimeSpanType]].
−
=== TimeSpanType ===
+
=== SetInternalOffset ===
−
This is an u64.
+
Takes an input [[#TimeSpanType]]. No output.
== ISystemClock ==
== ISystemClock ==
Line 473:
Line 700:
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
−
! Cmd || Name || Notes
+
! Cmd || Name
|-
|-
−
| 0 || GetCurrentTime || Returns an output [[#PosixTime]].
+
| 0 || [[#GetCurrentTime]]
|-
|-
−
| 1 || SetCurrentTime || Takes an input [[#PosixTime]].
+
| 1 || [[#SetCurrentTime]]
|-
|-
−
| 2 || GetSystemClockContext || Returns an output [[#SystemClockContext]].
+
| 2 || [[#GetSystemClockContext]]
|-
|-
−
| 3 || SetSystemClockContext || Takes an input [[#SystemClockContext]].
+
| 3 || [[#SetSystemClockContext]]
|-
|-
−
| 4 || [9.0.0+] GetOperationEventReadableHandle ||
+
| 4 || [9.0.0+] GetOperationEventReadableHandle
|}
|}
−
=== PosixTime ===
+
=== GetCurrentTime ===
−
This is an s64 for UTC POSIX time.
+
No input. Returns an output [[#PosixTime]].
+
+
=== SetCurrentTime ===
+
Takes an input [[#PosixTime]]. No output.
−
=== SystemClockContext ===
+
=== GetSystemClockContext ===
−
This is an 0x20-byte struct.
+
No input. Returns an output [[#SystemClockContext]].
−
{| class="wikitable" border="1"
+
=== SetSystemClockContext ===
−
|-
+
Takes an input [[#SystemClockContext]]. No output.
−
! Offset || Size || Description
−
|-
−
| 0x0 || 0x8|| a [[#PosixTime]] representing the system clock epoch.
−
|-
−
| 0x8 || 0x18 || a [[#SteadyClockTimePoint]]
−
|}
== ITimeZoneService ==
== ITimeZoneService ==
Line 506:
Line 730:
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
−
! Cmd || Name || Notes
+
! Cmd || Name
|-
|-
−
| 0 || GetDeviceLocationName || No input, returns an output [[#LocationName]].
+
| 0 || [[#GetDeviceLocationName]]
|-
|-
−
| 1 || SetDeviceLocationName || Takes an input [[#LocationName]], no output.
+
| 1 || [[#SetDeviceLocationName]]
|-
|-
−
| 2 || GetTotalLocationNameCount || No input, returns an output s32.
+
| 2 || [[#GetTotalLocationNameCount]]
|-
|-
−
| 3 || LoadLocationNameList ||
+
| 3 || [[#LoadLocationNameList]]
|-
|-
−
| 4 || LoadTimeZoneRule || Takes an input [[#LocationName]] and a type-0x16 output buffer for [[#TimeZoneRule]], no output.
+
| 4 || [[#LoadTimeZoneRule]]
|-
|-
−
| 5 || [2.0.0+] GetTimeZoneRuleVersion || No input, returns an output [[#TimeZoneRuleVersion]].
+
| 5 || [2.0.0+] [[#GetTimeZoneRuleVersion]]
|-
|-
−
| 6 || [5.0.0+] GetDeviceLocationNameAndUpdatedTime ||
+
| 6 || [5.0.0+] GetDeviceLocationNameAndUpdatedTime
|-
|-
−
| 100 || ToCalendarTime || Takes an input [[#PosixTime]] and a type-0x15 input buffer for [[#TimeZoneRule]], returns an output [[#CalendarTime]] and [[#CalendarAdditionalInfo]].
+
| 100 || [[#ToCalendarTime]]
|-
|-
−
| 101 || ToCalendarTimeWithMyRule || Takes an input [[#PosixTime]], returns an output [[#CalendarTime]] and [[#CalendarAdditionalInfo]].
+
| 101 || [[#ToCalendarTimeWithMyRule]]
|-
|-
−
| 201 || ToPosixTime || Takes an input [[#CalendarTime]], a type-0x15 input buffer for [[#TimeZoneRule]], an type-0xA output buffer for [[#PosixTime]] array, and returns an output s32.
+
| 201 || [[#ToPosixTime]]
|-
|-
−
| 202 || ToPosixTimeWithMyRule || Takes an input [[#CalendarTime]], an type-0xA output buffer for [[#PosixTime]] array, and returns an output s32.
+
| 202 || [[#ToPosixTimeWithMyRule]]
|}
|}
−
=== LoadLocationNameList ===
+
=== GetDeviceLocationName ===
−
Takes an input s32 LocationName_index and a type-0x6 output buffer for [[#LocationName]], returns an output s32 for total output entries.
+
No input. Returns an output [[#LocationName]].
−
=== LocationName ===
+
=== SetDeviceLocationName ===
−
This contains a TimeZone location string with a max size of 0x24 bytes.
+
Takes an input [[#LocationName]]. No output.
−
=== TimeZoneRule ===
+
=== GetTotalLocationNameCount ===
−
This is an 0x4000-byte struct. Official sw uses fixed-size 0x4000 for the buffer size with the above commands.
+
No input. Returns an output s32.
−
This is loaded from the [[Title_list|TimeZoneBinary]] title with the specified LocationName under the zoneinfo/ directory, the content is then converted into this TimeZoneRule structure.
+
=== LoadLocationNameList ===
−
+
Takes an input s32 LocationName_index and a type-0x6 output buffer for [[#LocationName]]. Returns an output s32 for total output entries.
−
The files contained under zoneinfo/ directory are Tzif2 files without Tzif1 header and data at the begining of them (see [https://tools.ietf.org/html/rfc8536 RFC8536] for more information).
−
The conversion of a Tzif2 file to a TimeZoneRule structure is based on [https://github.com/eggert/tz/blob/master/localtime.c tz database code] with some custom modifications (Leap seconds aren't handled, no usage of "posixrules" and Tzif1 support stripped out).
+
=== LoadTimeZoneRule ===
+
Takes an input [[#LocationName]] and a type-0x16 output buffer for [[#TimeZoneRule]]. No output.
−
{| class="wikitable" border="1"
+
=== GetTimeZoneRuleVersion ===
−
|-
+
No input. Returns an output [[#TimeZoneRuleVersion]].
−
! Offset || Size || Description
−
|-
−
| 0x0 || 0x4 || timecnt
−
|-
−
| 0x4 || 0x4 || typecnt
−
|-
−
| 0x8 || 0x4 || charcnt
−
|-
−
| 0xC || 0x1 || goback
−
|-
−
| 0xD || 0x1 || goahead
−
|-
−
| 0xE || 0x2 || Padding
−
|-
−
| 0x10 || 0x8 * 1000 || ats
−
|-
−
| 0x1f50 || 0x1 * 1000 || types
−
|-
−
| 0x2338 || 0x10 * 128 || ttis (time type information), struct ttinfo[1000]
−
|-
−
| 0x2b38 || 0x1 * 512 || chars
−
|-
−
| 0x2d38 || 0x4 || defaulttype
−
|-
−
| 0x2d3c || 0x12c4 || Reserved / Unused
−
|}
−
=== ttinfo ===
+
=== ToCalendarTime ===
−
This is an 0x10-byte struct.
+
Takes an input [[#PosixTime]] and a type-0x15 input buffer for [[#TimeZoneRule]]. Returns an output [[#CalendarTime]] and [[#CalendarAdditionalInfo]].
−
Represent a Time Type Information used in [[#TimeZoneRule]].
−
{| class="wikitable" border="1"
+
=== ToCalendarTimeWithMyRule ===
−
|-
+
Takes an input [[#PosixTime]]. Returns an output [[#CalendarTime]] and [[#CalendarAdditionalInfo]].
−
! Offset || Size || Description
−
|-
−
| 0x0 || 0x4 || tt_gmtoff
−
|-
−
| 0x4 || 0x1 || tt_isdst
−
|-
−
| 0x5 || 0x3 || Padding
−
|-
−
| 0x8 || 0x4 || tt_abbrind
−
|-
−
| 0xC || 0x1 || tt_ttisstd
−
|-
−
| 0xD || 0x1 || tt_ttisgmt
−
|-
−
| 0xE || 0x2 || Padding
−
|}
−
=== TimeZoneRuleVersion ===
+
=== ToPosixTime ===
−
This is an u128.
+
Takes an input [[#CalendarTime]], a type-0x15 input buffer for [[#TimeZoneRule]], an type-0xA output buffer for [[#PosixTime]] array.R eturns an output s32.
−
=== CalendarTime ===
+
=== ToPosixTimeWithMyRule ===
−
{| class="wikitable" border="1"
+
Takes an input [[#CalendarTime]], an type-0xA output buffer for [[#PosixTime]] array. Returns an output s32.
−
|-
−
! Offset || Size || Description
−
|-
−
| 0x0 || 0x2 || Year
−
|-
−
| 0x2 || 0x1 || Month
−
|-
−
| 0x3 || 0x1 || Day
−
|-
−
| 0x4 || 0x1 || Hour
−
|-
−
| 0x5 || 0x1 || Minute
−
|-
−
| 0x6 || 0x1 || Second
−
|-
−
| 0x7 || 0x1 || Padding / unknown?
−
|}
−
This is an 0x8-byte struct.
+
= BoardPowerControlEventTarget =
+
This is "nn::bpc::BoardPowerControlEventTarget".
−
=== CalendarAdditionalInfo ===
+
= SleepButtonState =
−
{| class="wikitable" border="1"
+
This is "nn::bpc::SleepButtonState".
−
|-
−
! Offset || Size || Description
−
|-
−
| 0x0 || 0x4 || 0-based day-of-week.
−
|-
−
| 0x4 || 0x4 || 0-based day-of-year.
−
|-
−
| 0x8 || 0x8 || Timezone name string.
−
|-
−
| 0x10 || 0x4 || 0 = no DST, 1 = DST.
−
|-
−
| 0x14 || 0x4 || s32 seconds relative to UTC for this timezone.
−
|}
−
This is an 0x18-byte struct. This stores timezone info.
+
= EventTarget =
+
This is "nn::bpc::EventTarget".
= Module =
= Module =
Line 648:
Line 801:
! Value || Name || DeviceCode || Rail
! Value || Name || DeviceCode || Rail
|-
|-
−
| 0 || Cpu || 0x40000001 || VddCpu
+
| 0 || Cpu || 0x40000001 || VddCpu
|-
|-
−
| 1 || Gpu || 0x40000002 || VddGpu
+
| 1 || Gpu || 0x40000002 || VddGpu
|-
|-
−
| 2 || I2s1 || 0x40000003 || VddSoc
+
| 2 || I2s1 || 0x40000003 || VddSoc
|-
|-
−
| 3 || I2s2 || 0x40000004 || VddSoc
+
| 3 || I2s2 || 0x40000004 || VddSoc
|-
|-
−
| 4 || I2s3 || 0x40000005 || VddSoc
+
| 4 || I2s3 || 0x40000005 || VddSoc
|-
|-
−
| 5 || Pwm || 0x40000006 || VddSoc
+
| 5 || Pwm || 0x40000006 || VddSoc
|-
|-
−
| 6 || I2c1 || 0x02000001 || VddSoc
+
| 6 || I2c1 || 0x02000001 || VddSoc
|-
|-
−
| 7 || I2c2 || 0x02000002 || VddSoc
+
| 7 || I2c2 || 0x02000002 || VddSoc
|-
|-
−
| 8 || I2c3 || 0x02000003 || VddSoc
+
| 8 || I2c3 || 0x02000003 || VddSoc
|-
|-
−
| 9 || I2c4 || 0x02000004 || VddSoc
+
| 9 || I2c4 || 0x02000004 || VddSoc
|-
|-
| 10 || I2c5 || 0x02000005 || VddSoc
| 10 || I2c5 || 0x02000005 || VddSoc
Line 821:
Line 974:
|-
|-
| [6.0.0+] 86 || Extperiph2 || 0x40000057 || VddSoc
| [6.0.0+] 86 || Extperiph2 || 0x40000057 || VddSoc
+
|-
+
| [8.0.0+] - || OscClk || 0x40000080 || None
|}
|}
Line 830:
Line 985:
! Value || Name || DeviceCode || Description
! Value || Name || DeviceCode || Description
|-
|-
−
| 0 || Max77620_Sd0 || 0x3A000080 ||
+
| 0 || Max77620_Sd0 || 0x3A000080 || SoC (1.125v)
|-
|-
−
| 1 || Max77620_Sd1 || 0x3A000081 ||
+
| 1 || Max77620_Sd1 || 0x3A000081 || Dram (1.1v)
|-
|-
−
| 2 || Max77620_Sd2 || 0x3A000082 ||
+
| 2 || Max77620_Sd2 || 0x3A000082 || Ldo0, Ldo1, Ldo7, Ldo8 (1.325v)
|-
|-
−
| 3 || Max77620_Sd3 || 0x3A000083 ||
+
| 3 || Max77620_Sd3 || 0x3A000083 || Reserved (1.8v)
|-
|-
−
| 4 || Max77620_Ldo0 || 0x3A0000A0 || 1.2v
+
| 4 || Max77620_Ldo0 || 0x3A0000A0 || Panel (1.2v)
|-
|-
−
| 5 || Max77620_Ldo1 || 0x3A0000A1 ||
+
| 5 || Max77620_Ldo1 || 0x3A0000A1 || Xusb, PCIe (1.05v)
|-
|-
−
| 6 || Max77620_Ldo2 || 0x3A0000A2 || SDcard power, 1.8v - 3.3v
+
| 6 || Max77620_Ldo2 || 0x3A0000A2 || SdCard (1.8v, 3.3v)
|-
|-
−
| 7 || Max77620_Ldo3 || 0x3A0000A3 || GC ASIC 3.1v
+
| 7 || Max77620_Ldo3 || 0x3A0000A3 || GcCard (3.1v)
|-
|-
−
| 8 || Max77620_Ldo4 || 0x3A0000A4 || RTC power, 0.85v
+
| 8 || Max77620_Ldo4 || 0x3A0000A4 || Rtc (0.85v)
|-
|-
−
| 9 || Max77620_Ldo5 || 0x3A0000A5 || GC ASIC 1.8v
+
| 9 || Max77620_Ldo5 || 0x3A0000A5 || GcCard (1.8v)
|-
|-
−
| 10 || Max77620_Ldo6 || 0x3A0000A6 || AVDD touchscreen, 2.9v
+
| 10 || Max77620_Ldo6 || 0x3A0000A6 || TouchPanel, ALS (2.9v)
|-
|-
−
| 11 || Max77620_Ldo7 || 0x3A0000A7 ||
+
| 11 || Max77620_Ldo7 || 0x3A0000A7 || Xusb (1.05v)
|-
|-
−
| 12 || Max77620_Ldo8 || 0x3A0000A8 || DisplayPort, 1.05v
+
| 12 || Max77620_Ldo8 || 0x3A0000A8 || DisplayPort, HDMI, SioMcu (1.05v)
|-
|-
| 13 || Max77621_Cpu || 0x3A000003 ||
| 13 || Max77621_Cpu || 0x3A000003 ||
Line 865:
Line 1,020:
|-
|-
| [6.0.0+] 17 || Max77812_Dram || 0x3A000005 ||
| [6.0.0+] 17 || Max77812_Dram || 0x3A000005 ||
+
|}
+
+
= PowerControlTarget =
+
This is "nn::pcv::PowerControlTarget".
+
+
{| class="wikitable" border="1"
+
|-
+
! Value || Name || DeviceCode || Description
+
|-
+
| 0 || || 0x3C000004 || SdCard (Ldo2)
+
|-
+
| [6.0.0+] 1 || || 0x34000007 || DisplayPort, HDMI (Ldo8)
+
|-
+
| [6.0.0+] 2 || || || Debug (Ldo7, Hoag only)
|-
|-
−
| [8.0.0+] - || || 0x3C000004 || SDCard
+
| [6.0.0+] 3 || || 0x3500041A || SioMcu (Ldo8, Hoag only)
|-
|-
−
| [8.0.0+] - || || 0x34000007 || HDMI
+
| [14.0.0+] - || || 0x3C000404 || GcCard (Ldo3)
|-
|-
−
| [8.0.0+] - || || 0x3500041A || MCU
+
| [14.0.0+] - || || 0x3C000405 || GcCard (Ldo5)
+
|}
+
+
= ModuleState =
+
This is "nn::pcv::ModuleState". This is a 0xC-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || ClockFrequency
+
|-
+
| 0x4 || 0x1 || ClockEnabled
+
|-
+
| 0x5 || 0x1 || PowerEnabled
+
|-
+
| 0x6 || 0x1 || ResetAsserted
+
|-
+
| 0x7 || 0x1 || Reserved
+
|-
+
| 0x8 || 0x4 || MinVClockRate
+
|}
+
+
= PowerDomainState =
+
This is "nn::pcv::PowerDomainState". This is a 0x8-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x1 || Enabled
+
|-
+
| 0x1 || 0x3 || Reserved
+
|-
+
| 0x4 || 0x4 || Voltage
+
|}
+
+
[8.0.0+] This is a 0xC-byte struct.
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || DeviceCode
+
|-
+
| 0x4 || 0x1 || Enabled
+
|-
+
| 0x5 || 0x3 || Reserved
+
|-
+
| 0x8 || 0x4 || Voltage
+
|}
+
+
= TemperatureThreshold =
+
This is "nn::pcv::TemperatureThreshold". This is a 0x8-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || MinMilliC
+
|-
+
| 0x4 || 0x4 || MaxMilliC
+
|}
+
+
= ClockRatesListType =
+
This is "nn::pcv::ClockRatesListType".
+
+
{| class="wikitable" border="1"
+
|-
+
! Value || Description
+
|-
+
| 0 || Invalid
+
|-
+
| 1 || Discrete
+
|-
+
| 2 || Range
+
|}
+
+
= SteadyClockTimePoint =
+
This is a 0x18-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x8 || A u64 representing a point in time.
+
|-
+
| 0x8 || 0x10 || An ID representing the clock source.
+
|}
+
+
= TimeSpanType =
+
This is an u64.
+
+
= PosixTime =
+
This is an s64 for UTC POSIX time.
+
+
= SystemClockContext =
+
This is an 0x20-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x8|| a [[#PosixTime]] representing the system clock epoch.
+
|-
+
| 0x8 || 0x18 || a [[#SteadyClockTimePoint]]
+
|}
+
+
= LocationName =
+
This contains a TimeZone location string with a max size of 0x24 bytes.
+
+
= TimeZoneRule =
+
This is an 0x4000-byte struct. Official sw uses fixed-size 0x4000 for the buffer size with the above commands.
+
+
This is loaded from the [[Title_list|TimeZoneBinary]] title with the specified LocationName under the zoneinfo/ directory, the content is then converted into this TimeZoneRule structure.
+
+
The files contained under zoneinfo/ directory are Tzif2 files without Tzif1 header and data at the begining of them (see [https://tools.ietf.org/html/rfc8536 RFC8536] for more information).
+
+
The conversion of a Tzif2 file to a TimeZoneRule structure is based on [https://github.com/eggert/tz/blob/master/localtime.c tz database code] with some custom modifications (Leap seconds aren't handled, no usage of "posixrules" and Tzif1 support stripped out).
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || timecnt
+
|-
+
| 0x4 || 0x4 || typecnt
+
|-
+
| 0x8 || 0x4 || charcnt
+
|-
+
| 0xC || 0x1 || goback
+
|-
+
| 0xD || 0x1 || goahead
+
|-
+
| 0xE || 0x2 || Padding
+
|-
+
| 0x10 || 0x8 * 1000 || ats
+
|-
+
| 0x1f50 || 0x1 * 1000 || types
+
|-
+
| 0x2338 || 0x10 * 128 || ttis (time type information), struct ttinfo[1000]
+
|-
+
| 0x2b38 || 0x1 * 512 || chars
+
|-
+
| 0x2d38 || 0x4 || defaulttype
+
|-
+
| 0x2d3c || 0x12c4 || Reserved / Unused
+
|}
+
+
= ttinfo =
+
This is an 0x10-byte struct. Represents a Time Type Information used in [[#TimeZoneRule]].
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || tt_gmtoff
+
|-
+
| 0x4 || 0x1 || tt_isdst
+
|-
+
| 0x5 || 0x3 || Padding
+
|-
+
| 0x8 || 0x4 || tt_abbrind
+
|-
+
| 0xC || 0x1 || tt_ttisstd
+
|-
+
| 0xD || 0x1 || tt_ttisgmt
+
|-
+
| 0xE || 0x2 || Padding
+
|}
+
+
= TimeZoneRuleVersion =
+
This is an u128.
+
+
= CalendarTime =
+
This is an 0x8-byte struct.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x2 || Year
+
|-
+
| 0x2 || 0x1 || Month
+
|-
+
| 0x3 || 0x1 || Day
+
|-
+
| 0x4 || 0x1 || Hour
+
|-
+
| 0x5 || 0x1 || Minute
+
|-
+
| 0x6 || 0x1 || Second
+
|-
+
| 0x7 || 0x1 || Padding / unknown?
+
|}
+
+
= CalendarAdditionalInfo =
+
This is an 0x18-byte struct. This stores timezone info.
+
+
{| class="wikitable" border="1"
+
|-
+
! Offset || Size || Description
+
|-
+
| 0x0 || 0x4 || 0-based day-of-week.
+
|-
+
| 0x4 || 0x4 || 0-based day-of-year.
+
|-
+
| 0x8 || 0x8 || Timezone name string.
+
|-
+
| 0x10 || 0x4 || 0 = no DST, 1 = DST.
+
|-
+
| 0x14 || 0x4 || s32 seconds relative to UTC for this timezone.
|}
|}
[[Category:Services]]
[[Category:Services]]