BleDeviceRequests

Implementation of DeviceRequests for communicating with Bluetooth Low Energy (BLE) devices.

This class handles the specifics of satellite device communication over BLE, providing methods for device configuration, status monitoring, and firmware updates.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
suspend fun batteryLevel(): Response<Int>

Retrieves the current battery level of the connected device.

Link copied to clipboard
suspend fun checkInAck(checkInAckRequest: CheckInAck): Response<Boolean>

Acknowledges a check-in message from the device.

Link copied to clipboard
suspend fun clearLog(): Response<Boolean>

Clears the logs in the connected device.

Link copied to clipboard

Sends a command request to the device.

Link copied to clipboard

Retrieves device information from the connected satellite device.

Link copied to clipboard

Downloads the log from the connected device and responds with DownloadLog.

Link copied to clipboard
Link copied to clipboard

Checks if a firmware update is available for the connected device.

Link copied to clipboard
suspend fun logStatus(logStatusRequest: LogStatusRequest): Response<LogStatus>

Updates/Retrieves the current log status of the connected device.

Link copied to clipboard
suspend fun quota(): Response<UserQuota>

Retrieves the user's quota information from the device.

Link copied to clipboard

Updates/Retrieves the current remote device status of the connected device.

Link copied to clipboard
suspend fun setAPN(): Response<Boolean>

Configures the Access Point Name (APN) settings on the device.

suspend fun setAPN(setAPNRequest: SetAPNRequest): Response<Boolean>
Link copied to clipboard
suspend fun setCheckInConfig(checkInRequest: CheckInConfig): Response<Boolean>

Configures the check-in settings on the connected device.

Link copied to clipboard

Sets a new quota allocation for the user on the device.

Link copied to clipboard
suspend fun sosCloseAck(sosCloseAckRequest: SosCloseAck): Response<Boolean>

Acknowledges the closing of an SOS incident to the device.

Link copied to clipboard
suspend fun sosOpenAck(sosOpenAckRequest: SosOpenAck): Response<Boolean>

Acknowledges the opening of an SOS incident to the device.

Link copied to clipboard
suspend fun sosStatus(sosSyncRequest: SosSyncRequest): Response<Sos>

Retrieves the current SOS status from the device or updates SOS status on the device.

Link copied to clipboard
suspend fun stopConnectionUpdates()

Stops the automatic updates about satellite connection status.

Link copied to clipboard
suspend fun stopNetworkUpdates()

Stops the automatic updates about satellite network status.

Link copied to clipboard
abstract suspend fun updateFirmware(file: File): Flow<StreamResponse<FotaUpdate>>

Initiates and monitors the firmware update process on the device.

Link copied to clipboard
suspend fun userConfig(): Response<Boolean>

Configures the user ID on the connected device.

Link copied to clipboard
open override fun wrapWithSendRequestListener(listener: () -> Unit): DeviceRequests