Crate remora_modem_manager
Expand description
D-Bus client for ModemManager.
The crate has an async proxy for every public interface of the
org.freedesktop.ModemManager1 service. The service exports one object
per modem, SIM, bearer, SMS, call and cell broadcast message. Only the
manager has a fixed path. Build the other proxies with the object path
that the service gives you.
use remora_modem_manager::ModemProxy;
let connection = zbus::Connection::system().await?;
let path = "/org/freedesktop/ModemManager1/Modem/0";
let modem = ModemProxy::new(&connection, path).await?;
println!("{:?}", modem.state().await?);§Versions
The crate covers ModemManager 1.24.2. Members without a version note exist in ModemManager 1.10 and later. Other members and interfaces say in which release they appeared. Calls to a member that the running service lacks fail with a D-Bus error.
§Properties
The service sends PropertiesChanged whenever a property changes. The
proxies cache every property.
§Types
Enums use the derives of remora-derive, and their Other variant keeps
unknown values. Flags keep unknown bits. Dictionaries with documented keys
are structs with optional fields, and keys that a struct does not name are
dropped. The crate keeps a few values raw. The docs of each such member
say why.
Dictionary structs are #[non_exhaustive], so build one from its default
and set the fields you need:
use remora_modem_manager::BearerProperties;
let mut properties = BearerProperties::default();
properties.apn = Some("internet".to_owned());Signals have the types that zbus generates, for example
ModemStateChanged, ModemStateChangedArgs and ModemStateChangedStream.
The types of signals that several interfaces share a name for carry the
interface name as a prefix.
Upstream documentation: https://www.freedesktop.org/software/ModemManager/api/latest/.
Re-exports§
pub use zbus;
Modules§
Structs§
- Activation
State Changed - A
ActivationStateChangedsignal. - Activation
State Changed Args ActivationStateChangedsignal arguments.- Activation
State Changed Stream - A
Streamimplementation that yieldsActivationStateChangedsignals. - Bearer
Allowed Auth - Authentication methods of a bearer.
- Bearer
ApnType - The purposes of an APN.
- Bearer
IpConfig - The IP settings of a connected bearer.
- Bearer
IpFamily - IP families of a bearer.
- Bearer
Properties - The settings of a bearer or connection profile.
- Bearer
Proxy - Client for a packet data bearer.
- Bearer
Roaming Allowance - The networks that a bearer may use while roaming.
- Bearer
Stats - Statistics of a bearer.
- Call
Added - A
CallAddedsignal. - Call
Added Args CallAddedsignal arguments.- Call
Added Stream - A
Streamimplementation that yieldsCallAddedsignals. - Call
Audio Format - The audio format of a call that the host routes.
- Call
Deleted - A
CallDeletedsignal. - Call
Deleted Args CallDeletedsignal arguments.- Call
Deleted Stream - A
Streamimplementation that yieldsCallDeletedsignals. - Call
Properties - The properties of a new call for
Voice.CreateCall. - Call
Proxy - Client for one voice call.
- Call
State Changed - A
StateChangedsignal. - Call
State Changed Args StateChangedsignal arguments.- Call
State Changed Stream - A
Streamimplementation that yieldsStateChangedsignals. - CbmProxy
- Client for one cell broadcast message.
- Cdma
Activation Changes - The properties that an activation state change changed.
- Cdma
Manual Activation - The provisioning data for
Cdma.ActivateManual. - Cdma
Proxy - Client for the CDMA features of a modem.
- Cdma
Signal - Signal information for CDMA 1x.
- Cell
Broadcast Added - A
Addedsignal. - Cell
Broadcast Added Args Addedsignal arguments.- Cell
Broadcast Added Stream - A
Streamimplementation that yieldsAddedsignals. - Cell
Broadcast Deleted - A
Deletedsignal. - Cell
Broadcast Deleted Args Deletedsignal arguments.- Cell
Broadcast Deleted Stream - A
Streamimplementation that yieldsDeletedsignals. - Cell
Broadcast Proxy - Client for the cell broadcast features of a modem.
- Cell
Info - A cell that
Modem.GetCellInforeports. - Dtmf
Received - A
DtmfReceivedsignal. - Dtmf
Received Args DtmfReceivedsignal arguments.- Dtmf
Received Stream - A
Streamimplementation that yieldsDtmfReceivedsignals. - Evdo
Signal - Signal information for CDMA EV-DO.
- Firmware
Image - An installed firmware image.
- Firmware
Proxy - Client for the firmware features of a modem.
- Firmware
Update Settings - The details of a firmware update method.
- GsmSignal
- Signal information for GSM and GPRS.
- Kernel
Event - A kernel event for
Manager.ReportKernelEvent. - Location
Proxy - Client for the location features of a modem.
- LteSignal
- Signal information for LTE.
- Manager
Proxy - Client for the manager object of ModemManager.
- Messaging
Added - A
Addedsignal. - Messaging
Added Args Addedsignal arguments.- Messaging
Added Stream - A
Streamimplementation that yieldsAddedsignals. - Messaging
Deleted - A
Deletedsignal. - Messaging
Deleted Args Deletedsignal arguments.- Messaging
Deleted Stream - A
Streamimplementation that yieldsDeletedsignals. - Messaging
Proxy - Client for the SMS features of a modem.
- Modem3gpp
Facility - Facilities that a PIN can lock.
- Modem3gpp
Network Rejection - The last network rejection during registration.
- Modem3gpp
Nr5g Registration Settings - The 5G registration settings of a device.
- Modem3gpp
Proxy - Client for the 3GPP features of a modem.
- Modem
Access Technology - Access technologies that a modem uses on the network.
- Modem
Capability - Generic families of access technologies that a modem supports.
- Modem
Firmware Update Method - Firmware update procedures that a modem supports.
- Modem
Location Assistance Data Type - Types of assistance data for a GNSS engine.
- Modem
Location Source - Sources of location information.
- Modem
Mode - Generations of access technologies that a modem may use.
- Modem
Proxy - Client for a modem.
- Modem
State Changed - A
StateChangedsignal. - Modem
State Changed Args StateChangedsignal arguments.- Modem
State Changed Stream - A
Streamimplementation that yieldsStateChangedsignals. - Network
Scan Result - A network that
Modem3gpp.Scanfound. - Network
Time Changed - A
NetworkTimeChangedsignal. - Network
Time Changed Args NetworkTimeChangedsignal arguments.- Network
Time Changed Stream - A
Streamimplementation that yieldsNetworkTimeChangedsignals. - Network
Timezone - The timezone that the network reports.
- Nr5g
Signal - Signal information for 5G NR.
- OmaFeature
- OMA device management features.
- OmaProxy
- Client for the OMA device management features of a modem.
- Profile
Manager Proxy - Client for the connection profiles of a modem.
- SarProxy
- Client for the SAR power features of a modem.
- Session
State Changed - A
SessionStateChangedsignal. - Session
State Changed Args SessionStateChangedsignal arguments.- Session
State Changed Stream - A
Streamimplementation that yieldsSessionStateChangedsignals. - Signal
Proxy - Client for the extended signal quality of a modem.
- Signal
Thresholds - The thresholds for
Signal.SetupThresholds. - SimProxy
- Client for a SIM, USIM or RUIM card.
- Simple
Connect Properties - The settings for
Simple.Connect. - Simple
Proxy - Client for the simple connection interface of a modem.
- Simple
Status - The result of
Simple.GetStatus. - SmsProperties
- The properties of a new SMS message for
Messaging.Create. - SmsProxy
- Client for one SMS message.
- Time
Proxy - Client for the network time of a modem.
- Umts
Signal - Signal information for UMTS.
- Updated
- A
Updatedsignal. - Updated
Stream - A
Streamimplementation that yieldsUpdatedsignals. - Ussd
Proxy - Client for the USSD features of a modem.
- Voice
Proxy - Client for the voice features of a modem.
Enums§
- Bearer
Access Type Preference - The access type that a 5G bearer prefers.
- Bearer
IpMethod - How to configure the IP address of a bearer.
- Bearer
Multiplex Support - Whether a bearer uses a multiplexed network link.
- Bearer
Profile Source - Who created a connection profile.
- Bearer
Type - The type of a bearer.
- Call
Direction - The direction of a call.
- Call
State - The state of a call.
- Call
State Reason - The reason for a state change of a call.
- CbmState
- The state of a cell broadcast message.
- Cdma
Activation Error - The error of a CDMA activation.
- Cell
Type - The access technology of a cell.
- Firmware
Image Type - The type of a firmware image.
- Kernel
Event Action - The action of a kernel event.
- LogLevel
- The logging verbosity of the daemon.
- Modem3gpp
DrxCycle - The DRX cycle of a 5G device.
- Modem3gpp
EpsUe Mode Operation - The UE mode of operation for EPS.
- Modem3gpp
Mico Mode - The MICO mode of a 5G device.
- Modem3gpp
Network Availability - The availability of a network that a scan found.
- Modem3gpp
Packet Service State - The state of the packet service.
- Modem3gpp
Registration State - The 3GPP registration state.
- Modem3gpp
Subscription State - The state of the subscription of an account.
- Modem3gpp
Ussd Session State - The state of a USSD session.
- Modem
Band - A radio frequency band.
- Modem
Cdma Activation State - The CDMA activation state.
- Modem
Cdma Registration State - The CDMA registration state.
- Modem
Cdma RmProtocol - The protocol of the CDMA Rm interface.
- Modem
Lock - The lock that a modem waits for.
- Modem
Port Type - The kind of a port of a modem.
- Modem
Power State - The power state of a modem.
- Modem
State - The overall state of a modem.
- Modem
State Change Reason - The reason for a state change of a modem.
- Modem
State Failed Reason - The reason for the failed state of a modem.
- Network
Error - A network error that a registration or session setup returns.
- OmaSession
State - The state of an OMA device management session.
- OmaSession
State Failed Reason - The reason for the failure of an OMA session.
- OmaSession
Type - The type of an OMA device management session.
- Profile
Index Field - The field that identifies a connection profile.
- Serving
Cell Type - The role of a serving cell in carrier aggregation.
- SimEsim
Status - Whether an eSIM has profiles.
- SimRemovability
- Whether a SIM can be removed.
- SimType
- The kind of a SIM.
- SmsCdma
Service Category - The CDMA service category of an SMS message.
- SmsCdma
Teleservice Id - The CDMA teleservice of an SMS message.
- SmsDelivery
State - The delivery state in a status report.
- SmsPdu
Type - The type of the PDUs of an SMS message.
- SmsState
- The state of an SMS message.
- SmsStorage
- A storage area for SMS messages.
- SmsValidity
Type - The format of the validity period of an SMS message.