Enumerations
enum TypeCPortInput
| Name | Value |
|---|---|
| kPortStateChanged | 1 |
| kTimerFired | 2 |
Changes signaled to the Type C Port Config Channel state machine.
Defined at line 19 of file ../../src/devices/power/drivers/fusb302/typec-port-state-machine.h
enum SinkPolicyEngineInput
| Name | Value |
|---|---|
| kInitialized | 1 |
| kMessageReceived | 2 |
| kTimerFired | 3 |
Changes signaled to the Sink Policy Engine state machine.
Defined at line 22 of file ../../src/devices/power/drivers/fusb302/pd-sink-state-machine.h
enum TransmissionState
| Name | Value |
|---|---|
| kPending | 0 |
| kTimedOut | 1 |
| kSuccess | 2 |
Tracks the acknowledgement of the last transmitted message.
Defined at line 27 of file ../../src/devices/power/drivers/fusb302/fusb302-protocol.h
enum TypeCPortState
| Name | Value |
|---|---|
| kSinkUnattached | 3 |
| kSinkAttached | 5 |
| kSourceAttached | 9 |
States for the Type C Port Config Channel state machine.
The states are defined in Section 4.5.2 "CC Functional and Behavioral
Requirements" in the USB Type C spec. The state values match the
corresponding sub-section numbers in Section 4.5.2.2 "Connection State
Machine Requirements".
Defined at line 30 of file ../../src/devices/power/drivers/fusb302/typec-port-state-machine.h
enum SinkPolicyEngineState
| Name | Value |
|---|---|
| kStartup | 1 |
| kDiscovery | 2 |
| kWaitForCapabilities | 3 |
| kEvaluateCapability | 4 |
| kSelectCapability | 5 |
| kTransitionSink | 6 |
| kReady | 7 |
| kGiveSinkCapabilities | 10 |
| kGetSourceCapabilities | 12 |
| kSendSoftReset | 13 |
| kSoftReset | 14 |
Sink Policy Engine States. States for SinkPolicyEngineStateMachine.
The states are a subset of the Sink states listed in Table 8-80 "Policy
Engine States" in Section 8.3.3.30 "Policy Engine States" of the USB PD spec.
Defined at line 32 of file ../../src/devices/power/drivers/fusb302/pd-sink-state-machine.h
enum GoodCrcGenerationMode
| Name | Value |
|---|---|
| kSoftware | 0 |
| kTracked | 1 |
| kAssumed | 2 |
Method used to generate or track GoodCRC replies to incoming USB PD packets.
Defined at line 42 of file ../../src/devices/power/drivers/fusb302/fusb302-protocol.h
enum SwitchBlockConfig
| Name | Value |
|---|---|
| kOpen | 0 |
| kPullUp | 1 |
| kPullDown | 2 |
| kConnectorVoltage | 3 |
Mutually exclusive configurations of the switch blocks attached to CC pins.
Rev 5 datasheet: Figure 6 "Configuration Channel Switch Functionality" on
page 6, Figure 3 "Functional Block Diagram" on page 3, Table 10 "Type-C CC
Switch" on page 15.
Defined at line 140 of file ../../src/devices/power/drivers/fusb302/registers.h
enum Fusb302RoleDetectionMode
| Name | Value |
|---|---|
| kReserved | 0b00 |
| kDualPowerRole | 0b01 |
| kSinkOnly | 0b10 |
| kSourceOnly | 0b11 |
Values for `mode`.
Defined at line 433 of file ../../src/devices/power/drivers/fusb302/registers.h
enum PowerRoleDetectionState
| Name | Value |
|---|---|
| kDetecting | 0b000 |
| kSourceOnCC1 | 0b001 |
| kSourceOnCC2 | 0b010 |
| kSinkOnCC1 | 0b101 |
| kSinkOnCC2 | 0b110 |
| kAudioAccessory | 0b111 |
The reported state of the power role detection hardware logic.
Values are obtained from the `togss` field in the
`Status1AReg` register
Defined at line 807 of file ../../src/devices/power/drivers/fusb302/registers.h
enum FixedComparatorResult
| Name | Value |
|---|---|
| kRa | 0b00 |
| kStandardUsbRd | 0b01 |
| kTypeC1500mARd | 0b10 |
| kTypeC3000mARd | 0b11 |
CC pin voltage, as reported by the fixed comparators in the measure block.
The fixed comparators can distinguish between the Sink terminations in
typec2.2 4.11.3 "Voltage Parameters", Table 4.38 "Voltage on Sink CC pins
(Multiple Source Current Announcements)".
Rev 5 datasheet: Table 37 on page 27, field BC_LVL[1:0]
Defined at line 933 of file ../../src/devices/power/drivers/fusb302/registers.h
enum ReceiveTokenType
| Name | Value |
|---|---|
| kSop | 0b111 |
| kSopPrime | 0b110 |
| kSopDoublePrime | 0b101 |
| kSopPrimeDebug | 0b100 |
| kSopDoublePrimeDebug | 0b011 |
| kUndocumented | 0b000 |
Receive fifo tokens decoded by FifosReg::AsReceiveTokenType().
Rev 5 datasheet: Table 42 page 28
Defined at line 1121 of file ../../src/devices/power/drivers/fusb302/registers.h
Records
-
class Control0Reg -
class Control1Reg -
class Control2Reg -
class Control3Reg -
class Control4Reg -
class DeviceIdReg -
class FifosReg -
class Fusb302 -
class Fusb302Controls -
class Fusb302Device -
class Fusb302Fifos -
class Fusb302Identity -
class Fusb302Protocol -
class Fusb302Register -
class Fusb302Sensors -
class Fusb302Signals -
class InspectableBool -
class InspectableInt -
class InspectableUint -
class InterruptAReg -
class InterruptBReg -
class InterruptReg -
class MaskAReg -
class MaskBReg -
class MaskReg -
class MeasureReg -
class OcpReg -
class PowerReg -
class ResetReg -
class SinkPolicyEngineStateMachine -
class SliceReg -
class StateMachineBase -
class Status0AReg -
class Status0Reg -
class Status1AReg -
class Status1Reg -
class Switches0Reg -
class Switches1Reg -
class TransmitToken -
class TypeCPortStateMachine
Functions
-
const char * SwitchBlockConfigToString (SwitchBlockConfig config)Descriptor for logging and debugging.
Defined at line 11 of file ../../src/devices/power/drivers/fusb302/registers.cc
-
const char * Fusb302RoleDetectionModeToString (Fusb302RoleDetectionMode mode)Descriptor for logging and debugging.
Defined at line 26 of file ../../src/devices/power/drivers/fusb302/registers.cc
-
usb_pd::ConfigChannelPinSwitch WiredCcPinFromPowerRoleDetectionState (PowerRoleDetectionState state)Defined at line 1385 of file ../../src/devices/power/drivers/fusb302/registers.h
-
usb_pd::PowerRole PowerRoleFromDetectionState (PowerRoleDetectionState state)`state` must be one of the states that has a Configuration Channel.
Defined at line 1398 of file ../../src/devices/power/drivers/fusb302/registers.h
-
const char * PowerRoleDetectionStateToString (PowerRoleDetectionState state)Descriptor for logging and debugging.
Defined at line 42 of file ../../src/devices/power/drivers/fusb302/registers.cc
-
usb_pd::ConfigChannelTermination ConfigChannelTerminationFromFixedComparatorResult (FixedComparatorResult result)Best-effort mapping from fixed comparator outcomes.
A result of `kRp3000mA` means "anything above 1,230 mV" and should be
supplemented by an upper bound check.
Defined at line 1407 of file ../../src/devices/power/drivers/fusb302/registers.h
-
const char * ReceiveTokenTypeToString (ReceiveTokenType receive_token_type)Descriptor for logging and debugging.
Defined at line 60 of file ../../src/devices/power/drivers/fusb302/registers.cc