Struct d1_pac::usb1::ohci_root_hub_partition::hc_rh_descriptor_a::R
source · pub struct R(/* private fields */);
Expand description
Register hc_rh_descriptor_a
reader
Implementations§
source§impl R
impl R
sourcepub fn number_downstream_ports(&self) -> NUMBER_DOWNSTREAM_PORTS_R
pub fn number_downstream_ports(&self) -> NUMBER_DOWNSTREAM_PORTS_R
Bits 0:7 - NumberDownstreamPorts
These bits specify the number of downstream ports supported by the Root Hub. It is implementation-specific. The minimum number of ports is 1. The maximum number of ports supported.
sourcepub fn no_power_swithcing(&self) -> NO_POWER_SWITHCING_R
pub fn no_power_swithcing(&self) -> NO_POWER_SWITHCING_R
Bit 8 - NoPowerSwithcing
These bits are used to specify whether power switching is supported or ports are always powered. It is implementation- specific. When this bit is cleared, the PowerSwitchingMode specifies global or per-port switching.
sourcepub fn power_switching_mode(&self) -> POWER_SWITCHING_MODE_R
pub fn power_switching_mode(&self) -> POWER_SWITCHING_MODE_R
Bit 9 - PowerSwitchingMode
This bit is used to specify how the power switching of the Root Hub ports is controlled. It is implementation-specific. This field is only valid if the NoPowerSwitching field is cleared.
sourcepub fn device(&self) -> DEVICE_R
pub fn device(&self) -> DEVICE_R
Bit 10 - Device Type This bit specifies that the Root Hub is not a compound device. The Root Hub is not permitted to be a compound device. This field should always read/write 0.
sourcepub fn over_current_protection_mode(&self) -> OVER_CURRENT_PROTECTION_MODE_R
pub fn over_current_protection_mode(&self) -> OVER_CURRENT_PROTECTION_MODE_R
Bit 11 - OverCurrentProtectionMode
This bit describes how the overcurrent status for the Root Hub ports are reported. At reset, these fields should reflect the same mode as PowerSwitchingMode. This field is valid only if the NoOverCurrentProtection field is cleared. 0 Over-current status is reported collectively for all downstream ports. 1 Over-current status is reported on per-port basis.
sourcepub fn no_over_current_protection(&self) -> NO_OVER_CURRENT_PROTECTION_R
pub fn no_over_current_protection(&self) -> NO_OVER_CURRENT_PROTECTION_R
Bit 12 - NoOverCurrentProtection
This bit describes how the overcurrent status for the Root Hub ports are reported. When this bit is cleared, the OverCurrentProtectionMode field specifies global or per-port reporting.
sourcepub fn power_on_to_power_good_time(&self) -> POWER_ON_TO_POWER_GOOD_TIME_R
pub fn power_on_to_power_good_time(&self) -> POWER_ON_TO_POWER_GOOD_TIME_R
Bits 24:31 - PowerOnToPowerGoodTime[POTPGT]
This byte specifies the duration HCD has to wait before accessing a powered-on port of the Root Hub. It is implementation-specific. The unit of time is 2 ms. The duration is calculated as POTPGT * 2ms.