Go to the source code of this file.
|
SbgErrorCode | sbgEComTransferReceive (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, void *pBuffer, size_t *pActualSize, size_t bufferSize) |
|
static SbgErrorCode | sbgEComTransferReceiveData (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, void *pBuffer, size_t offset, size_t packetSize) |
|
static SbgErrorCode | sbgEComTransferReceiveEnd (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg) |
|
static SbgErrorCode | sbgEComTransferReceiveInit (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, size_t *pSize) |
|
SbgErrorCode | sbgEComTransferSend (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, const void *pBuffer, size_t size) |
|
static SbgErrorCode | sbgEComTransferSendData (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, const void *pBuffer, size_t offset, size_t packetSize) |
|
static SbgErrorCode | sbgEComTransferSendEnd (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg) |
|
static SbgErrorCode | sbgEComTransferSendInit (SbgEComHandle *pHandle, uint8_t msgClass, uint8_t msg, size_t size) |
|
◆ sbgEComTransferReceive()
SbgErrorCode sbgEComTransferReceive |
( |
SbgEComHandle * |
pHandle, |
|
|
uint8_t |
msgClass, |
|
|
uint8_t |
msg, |
|
|
void * |
pBuffer, |
|
|
size_t * |
pActualSize, |
|
|
size_t |
bufferSize |
|
) |
| |
Specific method to handle a large receive from the device.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[in] | pBuffer | Pointer to the buffer where to write data. |
[out] | pActualSize | The final size written into the buffer. |
[in] | size | The size of the buffer. |
- Returns
- SBG_NO_ERROR in case of a successful download.
Definition at line 569 of file sbgEComTransfer.c.
◆ sbgEComTransferReceiveData()
static SbgErrorCode sbgEComTransferReceiveData |
( |
SbgEComHandle * |
pHandle, |
|
|
uint8_t |
msgClass, |
|
|
uint8_t |
msg, |
|
|
void * |
pBuffer, |
|
|
size_t |
offset, |
|
|
size_t |
packetSize |
|
) |
| |
|
static |
Receive one packet of data on a initiated download transfer.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[in] | pBuffer | Pointer to the buffer where to write the packet. |
[in] | offset | The offset from the start of the buffer. |
[in] | packetSize | The size of the data asked to the device. |
- Returns
- SBG_NO_ERROR if the packet was successfully received.
Definition at line 314 of file sbgEComTransfer.c.
◆ sbgEComTransferReceiveEnd()
Function that ends a download sequence with a device.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
- Returns
- SBG_NO_ERROR when the transfer ended successfully.
Definition at line 419 of file sbgEComTransfer.c.
◆ sbgEComTransferReceiveInit()
Initiates a download sequences with a device.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[out] | pSize | Size of the transfer initiated, returned from the device. |
- Returns
- SBG_NO_ERROR when the transfer initiated successfully.
Definition at line 204 of file sbgEComTransfer.c.
◆ sbgEComTransferSend()
SbgErrorCode sbgEComTransferSend |
( |
SbgEComHandle * |
pHandle, |
|
|
uint8_t |
msgClass, |
|
|
uint8_t |
msg, |
|
|
const void * |
pBuffer, |
|
|
size_t |
size |
|
) |
| |
Specific method to handle a large send into multiple frames.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[in] | pBuffer | Pointer to the buffer containing the data to send. |
[in] | size | The size of the buffer. |
- Returns
- SBG_NO_ERROR in case of a successful upload.
Definition at line 484 of file sbgEComTransfer.c.
◆ sbgEComTransferSendData()
static SbgErrorCode sbgEComTransferSendData |
( |
SbgEComHandle * |
pHandle, |
|
|
uint8_t |
msgClass, |
|
|
uint8_t |
msg, |
|
|
const void * |
pBuffer, |
|
|
size_t |
offset, |
|
|
size_t |
packetSize |
|
) |
| |
|
static |
Send one packet of data on a initiated upload transfer.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[in] | pBuffer | Pointer to the buffer containing the data to send. |
[in] | offset | The offset from the start of the transfer. |
[in] | packetSize | The size of this packet. |
- Returns
- SBG_NO_ERROR if the packet was sent and acknowledged by the device.
Definition at line 81 of file sbgEComTransfer.c.
◆ sbgEComTransferSendEnd()
Ends ongoing upload transfer sequence with a device.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
- Returns
- SBG_NO_ERROR when the transfer ended successfully.
Definition at line 144 of file sbgEComTransfer.c.
◆ sbgEComTransferSendInit()
Initiates an upload transfer sequence with a device.
- Parameters
-
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
[in] | size | Total size of the upload. |
- Returns
- SBG_NO_ERROR when the transfer was initiated successfully.
Definition at line 18 of file sbgEComTransfer.c.