bota_recipient.h File Reference

Table of contents Table of contents

BOTA recipient service. More...

Data Structures

struct  BotaDestinationMemory
 
struct  BotaRecipientMissingChunk
 Structure describing a missing chunk of data. More...
 
struct  BotaRecipientTransferStatus
 Structure describing the status of the transfer. More...
 
struct  BotaRecipientTransfer
 Structure describing a single BOTA transfer at the recipient side. More...
 
struct  BotaRecipient
 

Typedefs

typedef BotaTransferReaction(* BotaOnTransferStartedCallback) (BotaTransferId transferId, const EMBENET_IPV6 *senderAddr, size_t bulkSize, void const *transferInfo, size_t transferInfoSize, BotaDestinationMemory *destinationMemory)
 Type defining a function that will be called when a new incoming BOTA transfer is started in the recipient.
 
typedef void(* BotaOnTransferReceivedCallback) (BotaTransferId transferId, BotaDestinationMemory const *memory, size_t size, void const *transferInfo, size_t transferInfoSize)
 Type defining a function that will be called when an incoming BOTA transfer is received.
 
typedef void(* BotaOnTransferAbortedCallback) (BotaTransferId transferId, BotaDestinationMemory const *memory, size_t size, void const *transferInfo, size_t transferInfoSize, BotaAbortReason abortReason)
 Type defining a function that will be called when an incoming BOTA transfer is aborted.
 
typedef void(* BotaOnTransferDataMissingCallback) (BotaTransferId transferId, size_t receivedSize, size_t totalSize, void const *transferInfo, size_t transferInfoSize)
 Type defining a function that will be called when an incoming BOTA transfer is missing too much data to continue.
 

Enumerations

enum  BotaAbortReason {
  BOTA_ABORT_REASON_TIMEOUT = 0 , BOTA_ABORT_REASON_CRC_MISMATCH = 1 , BOTA_ABORT_REASON_REUSED_ID = 2 , BOTA_ABORT_REASON_DESTINATION_MEMORY_ERROR = 3 ,
  BOTA_ABORT_REASON_TOO_MUCH_DATA_MISSING = 4 , BOTA_ABORT_REASON_USER = 5
}
 Possible reasons for aborting the transfer. More...
 
enum  BotaRecipientTransferState {
  BOTA_RECIPIENT_TRANSFER_STATE_UNKNOWN = 0 , BOTA_RECIPIENT_TRANSFER_STATE_ACCEPTED = 1 , BOTA_RECIPIENT_TRANSFER_STATE_REJECTED = 2 , BOTA_RECIPIENT_TRANSFER_STATE_RECEIVING_DATA = 3 ,
  BOTA_RECIPIENT_TRANSFER_STATE_RECEIVED = 4 , BOTA_RECIPIENT_TRANSFER_STATE_HALTED = 5
}
 Possible states of a single transfer. More...
 

Functions

BotaResult BOTA_RECIPIENT_Init (BotaRecipient *botaRecipient, uint16_t port, BotaTimeFunc timeFunc, BotaOnTransferStartedCallback onTransferStarted, BotaOnTransferReceivedCallback onTransferReceived, BotaOnTransferAbortedCallback onTransferAborted, BotaOnTransferDataMissingCallback onTransferDataMissing)
 
void BOTA_RECIPIENT_Deinit (BotaRecipient *botaRecipient)
 
BotaResult BOTA_RECIPIENT_Start (BotaRecipient *botaRecipient)
 Starts the BOTA Recipient service.
 
BotaResult BOTA_RECIPIENT_Stop (BotaRecipient *botaRecipient)
 Stops the BOTA Recipient service.
 
void BOTA_RECIPIENT_Proc (BotaRecipient *botaRecipient)
 
BotaRecipientTransferStatus BOTA_RECIPIENT_GetTransferStatus (BotaRecipient *botaRecipient, BotaTransferId transferId)
 
void BOTA_RECIPIENT_AbortTransfer (BotaRecipient *botaRecipient, BotaTransferId transferId)
 

Detailed Description

BOTA recipient service.

License: ${PROJECT_LICENSE}
Version
${PROJECT_VERSION}
Purpose: Bulk Over-The-Air service

Contact us

Any question or remarks? Just write us a message!

Contact Information

Feel free to get in touch