#[non_exhaustive]pub enum Api<'a, T: Direction> {
Show 18 variants
ApiVersion(T::Type<'a, ApiVersion>),
AppletRequest(T::Type<'a, AppletRequest>),
AppletResponse(T::Type<'a, AppletResponse>),
PlatformReboot(T::Type<'a, PlatformReboot>),
AppletTunnel(T::Type<'a, AppletTunnel>),
_PlatformInfo0(T::Type<'a, _PlatformInfo0>),
PlatformVendor(T::Type<'a, PlatformVendor>),
_PlatformUpdateMetadata(T::Type<'a, _PlatformUpdateMetadata>),
_PlatformUpdate0(T::Type<'a, _PlatformUpdate0>),
_AppletInstall0(T::Type<'a, _AppletInstall0>),
_AppletUninstall0(T::Type<'a, _AppletUninstall0>),
AppletExitStatus(T::Type<'a, AppletExitStatus>),
PlatformLock(T::Type<'a, PlatformLock>),
PlatformInfo(T::Type<'a, PlatformInfo>),
PlatformClearStore(T::Type<'a, PlatformClearStore>),
PlatformUpdate(T::Type<'a, PlatformUpdate>),
AppletInstall(T::Type<'a, AppletInstall>),
AppletReboot(T::Type<'a, AppletReboot>),
}Expand description
Protocol API parametric over the message direction.
Deprecated variants are only available to the host (to support older devices).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
ApiVersion(T::Type<'a, ApiVersion>)
Returns the device API version.
AppletRequest(T::Type<'a, AppletRequest>)
Sends a request to an applet.
AppletResponse(T::Type<'a, AppletResponse>)
Reads a response from an applet.
PlatformReboot(T::Type<'a, PlatformReboot>)
Reboots the platform.
AppletTunnel(T::Type<'a, AppletTunnel>)
Starts a direct tunnel with an applet.
_PlatformInfo0(T::Type<'a, _PlatformInfo0>)
host only.(deprecated) Returns platform information (e.g. serial and version).
This message is deprecated in favor of PlatformInfo.
PlatformVendor(T::Type<'a, PlatformVendor>)
Calls a vendor-specific platform command.
_PlatformUpdateMetadata(T::Type<'a, _PlatformUpdateMetadata>)
host only.(deprecated) Returns the metadata for platform update.
This message is deprecated in favor of PlatformVendor, which is the message for
vendor-specific messages.
_PlatformUpdate0(T::Type<'a, _PlatformUpdate0>)
host only.(deprecated) Updates the platform.
This message is deprecated in favor of PlatformUpdate.
_AppletInstall0(T::Type<'a, _AppletInstall0>)
host only.(deprecated) Installs an applet.
This message is deprecated in favor of AppletInstall.
_AppletUninstall0(T::Type<'a, _AppletUninstall0>)
host only.(deprecated) Uninstalls an applet.
This message is deprecated in favor of AppletInstall with an empty transfer.
AppletExitStatus(T::Type<'a, AppletExitStatus>)
Returns the exit status of an applet, if not running.
PlatformLock(T::Type<'a, PlatformLock>)
Locks a platform until reboot.
This is useful for testing purposes by locking a platform before flashing a new one.
PlatformInfo(T::Type<'a, PlatformInfo>)
Returns platform information (serial, version, running side, opposite version, etc).
PlatformClearStore(T::Type<'a, PlatformClearStore>)
Clears the store for the platform and all applets.
The argument is the number of keys to protect. Using zero will clear all entries.
PlatformUpdate(T::Type<'a, PlatformUpdate>)
Updates the platform.
AppletInstall(T::Type<'a, AppletInstall>)
Installs or uninstalls an applet.
AppletReboot(T::Type<'a, AppletReboot>)
Reboots an applet.