pub struct WlanPhyProxy { /* private fields */ }Implementations§
Source§impl WlanPhyProxy
impl WlanPhyProxy
Sourcepub fn take_event_stream(&self) -> WlanPhyEventStream
pub fn take_event_stream(&self) -> WlanPhyEventStream
Get a Stream of events from the remote end of the protocol.
§Panics
Panics if the event stream was already taken.
Sourcepub fn init(
&self,
payload: WlanPhyInitRequest,
) -> QueryResponseFut<WlanPhyInitResult, DefaultFuchsiaResourceDialect>
pub fn init( &self, payload: WlanPhyInitRequest, ) -> QueryResponseFut<WlanPhyInitResult, DefaultFuchsiaResourceDialect>
This method can be used by the WlanPhy client to send the client end of the WlanPhyNotify endpoint for the WlanPhy server to use. If the WlanPhy client never invokes this method that is an indirect implication that the WlanPhyNotify is not supported. Some possible error codes are: ZX_ERR_NOT_SUPPORTED: The WlanPhy server does not support the WlanPhyNotify protocol.
Sourcepub fn get_supported_mac_roles(
&self,
) -> QueryResponseFut<WlanPhyGetSupportedMacRolesResult, DefaultFuchsiaResourceDialect>
pub fn get_supported_mac_roles( &self, ) -> QueryResponseFut<WlanPhyGetSupportedMacRolesResult, DefaultFuchsiaResourceDialect>
MAC roles supported for ifaces on the physical device.
Sourcepub fn create_iface(
&self,
payload: WlanPhyCreateIfaceRequest,
) -> QueryResponseFut<WlanPhyCreateIfaceResult, DefaultFuchsiaResourceDialect>
pub fn create_iface( &self, payload: WlanPhyCreateIfaceRequest, ) -> QueryResponseFut<WlanPhyCreateIfaceResult, DefaultFuchsiaResourceDialect>
Create a new interface with the specified role, returning the interface id.
Some common error codes are:
ZX_ERR_NO_RESOURCES: maximum number of interfaces have already been created.
ZX_ERR_NOT_SUPPORTED: device does not support the specified role.
Sourcepub fn destroy_iface(
&self,
payload: &WlanPhyDestroyIfaceRequest,
) -> QueryResponseFut<WlanPhyDestroyIfaceResult, DefaultFuchsiaResourceDialect>
pub fn destroy_iface( &self, payload: &WlanPhyDestroyIfaceRequest, ) -> QueryResponseFut<WlanPhyDestroyIfaceResult, DefaultFuchsiaResourceDialect>
Destroy the interface with the matching id.
Some common error codes are:
ZX_ERR_NOT_FOUND: Specified iface does not exist or has already been removed.
ZX_ERR_SHOULD_WAIT: Device is busy and cannot be removed, try again later.
Sourcepub fn set_country(
&self,
country: &[u8; 2],
) -> QueryResponseFut<WlanPhySetCountryResult, DefaultFuchsiaResourceDialect>
pub fn set_country( &self, country: &[u8; 2], ) -> QueryResponseFut<WlanPhySetCountryResult, DefaultFuchsiaResourceDialect>
Set country with a 2-byte country code.
Some common error codes are:
ZX_ERR_NOT_FOUND: Specified country code not supported. PHY state is left unchanged.
Sourcepub fn clear_country(
&self,
) -> QueryResponseFut<WlanPhyClearCountryResult, DefaultFuchsiaResourceDialect>
pub fn clear_country( &self, ) -> QueryResponseFut<WlanPhyClearCountryResult, DefaultFuchsiaResourceDialect>
Set device to a world-safe country, i.e. a mode that conforms to all
regulatory constraints globally.
Generally expected to succeed if the device is in a functional state.
Sourcepub fn get_country(
&self,
) -> QueryResponseFut<WlanPhyGetCountryResult, DefaultFuchsiaResourceDialect>
pub fn get_country( &self, ) -> QueryResponseFut<WlanPhyGetCountryResult, DefaultFuchsiaResourceDialect>
Read currently configured country. Implementations are advised to read the
country directly from the firmware, where possible.
Generally expected to succeed if the device is in a functional state.
Sourcepub fn set_power_save_mode(
&self,
payload: &WlanPhySetPowerSaveModeRequest,
) -> QueryResponseFut<WlanPhySetPowerSaveModeResult, DefaultFuchsiaResourceDialect>
pub fn set_power_save_mode( &self, payload: &WlanPhySetPowerSaveModeRequest, ) -> QueryResponseFut<WlanPhySetPowerSaveModeResult, DefaultFuchsiaResourceDialect>
Set Power Save mode on device. In most implementations this
likely to be set in Firmware.
Some common error codes are:
ZX_ERR_NOT_SUPPORTED: Specified Power Save mode not supported.
Sourcepub fn get_power_save_mode(
&self,
) -> QueryResponseFut<WlanPhyGetPowerSaveModeResult, DefaultFuchsiaResourceDialect>
pub fn get_power_save_mode( &self, ) -> QueryResponseFut<WlanPhyGetPowerSaveModeResult, DefaultFuchsiaResourceDialect>
Get current Power Save mode from device. In most implementation this likely to be retrieved from Firmware.
Sourcepub fn power_down(
&self,
) -> QueryResponseFut<WlanPhyPowerDownResult, DefaultFuchsiaResourceDialect>
pub fn power_down( &self, ) -> QueryResponseFut<WlanPhyPowerDownResult, DefaultFuchsiaResourceDialect>
Power up/down/reset the wlan chip.
If supported, PowerDown will power down the wlan chip if it is currently powered on.
Any existing interfaces should have already been deleted before making this call or else the
driver will fail the call with error code ZX_ERR_INTERNAL.
Other possible error codes are:
ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.
ZX_ERR_BAD_STATE: the wlan chip is already powered down.
Sourcepub fn power_up(
&self,
) -> QueryResponseFut<WlanPhyPowerUpResult, DefaultFuchsiaResourceDialect>
pub fn power_up( &self, ) -> QueryResponseFut<WlanPhyPowerUpResult, DefaultFuchsiaResourceDialect>
If supported, PowerUp will power up the wlan chip if it is currently powered down.
Possible error codes are:
ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.
ZX_ERR_BAD_STATE: the wlan chip is already powered up.
Sourcepub fn reset(
&self,
) -> QueryResponseFut<WlanPhyResetResult, DefaultFuchsiaResourceDialect>
pub fn reset( &self, ) -> QueryResponseFut<WlanPhyResetResult, DefaultFuchsiaResourceDialect>
If supported, Reset functionality implements PowerDown then PowerUp in an attempt to
recover from an error state. For example, if an interface gets into a bad state or if
firmware crashes, the firmware/chip may be unable to perform some actions and Reset
may be able to clear the bad state.
Possible error codes are:
ZX_ERR_NOT_SUPPORTED: the feature is not supported by the driver.
ZX_ERR_BAD_STATE: the wlan chip is already powered down.
Sourcepub fn get_power_state(
&self,
) -> QueryResponseFut<WlanPhyGetPowerStateResult, DefaultFuchsiaResourceDialect>
pub fn get_power_state( &self, ) -> QueryResponseFut<WlanPhyGetPowerStateResult, DefaultFuchsiaResourceDialect>
Returns the current power state of the wlan chip. After successful initialization of the wlan driver, the state is set to true (power on) by default. power_on set to true indicates that the wlan chip is powered on and false indicates the wlan chip is powered off.
Sourcepub fn set_bt_coexistence_mode(
&self,
payload: &WlanPhySetBtCoexistenceModeRequest,
) -> QueryResponseFut<WlanPhySetBtCoexistenceModeResult, DefaultFuchsiaResourceDialect>
pub fn set_bt_coexistence_mode( &self, payload: &WlanPhySetBtCoexistenceModeRequest, ) -> QueryResponseFut<WlanPhySetBtCoexistenceModeResult, DefaultFuchsiaResourceDialect>
Set the Bluetooth coexistence mode.
Possible error codes are:
ZX_ERR_NOT_SUPPORTED: device does not support the specified BT coexistence mode.
pub fn set_tx_power_scenario( &self, payload: &WlanPhySetTxPowerScenarioRequest, ) -> QueryResponseFut<WlanPhySetTxPowerScenarioResult, DefaultFuchsiaResourceDialect>
pub fn reset_tx_power_scenario( &self, ) -> QueryResponseFut<WlanPhyResetTxPowerScenarioResult, DefaultFuchsiaResourceDialect>
pub fn get_tx_power_scenario( &self, ) -> QueryResponseFut<WlanPhyGetTxPowerScenarioResult, DefaultFuchsiaResourceDialect>
Trait Implementations§
Source§impl Clone for WlanPhyProxy
impl Clone for WlanPhyProxy
Source§fn clone(&self) -> WlanPhyProxy
fn clone(&self) -> WlanPhyProxy
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for WlanPhyProxy
impl Debug for WlanPhyProxy
Source§impl Proxy for WlanPhyProxy
impl Proxy for WlanPhyProxy
Source§type Protocol = WlanPhyMarker
type Protocol = WlanPhyMarker
Proxy controls.Source§fn from_channel(inner: AsyncChannel) -> Self
fn from_channel(inner: AsyncChannel) -> Self
Source§fn into_channel(self) -> Result<AsyncChannel, Self>
fn into_channel(self) -> Result<AsyncChannel, Self>
Source§fn as_channel(&self) -> &AsyncChannel
fn as_channel(&self) -> &AsyncChannel
Source§fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
fn into_client_end(self) -> Result<ClientEnd<Self::Protocol>, Self>
Source§fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
fn on_closed(&self) -> OnSignals<'_, Unowned<'_, NullableHandle>>
PEER_CLOSED signal.