#include "sbgEComTransfer.h"
#include "../sbgEComCmdCommon.h"
#include <streamBuffer/sbgStreamBuffer.h>
#include <splitBuffer/sbgSplitBuffer.h>
Go to the source code of this file.
Functions | |
SbgErrorCode | sbgEComTransferReceive (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, void *pBuffer, size_t *pActualSize, size_t bufferSize) |
SbgErrorCode | sbgEComTransferReceiveData (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, void *pBuffer, size_t offset, size_t packetSize) |
SbgErrorCode | sbgEComTransferReceiveEnd (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg) |
SbgErrorCode | sbgEComTransferReceiveInit (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, size_t *pSize) |
SbgErrorCode | sbgEComTransferSend (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, const void *pBuffer, size_t size) |
SbgErrorCode | sbgEComTransferSendData (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, const void *pBuffer, size_t offset, size_t packetSize) |
SbgErrorCode | sbgEComTransferSendEnd (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg) |
SbgErrorCode | sbgEComTransferSendInit (SbgEComHandle *pHandle, uint8 msgClass, uint8 msg, size_t size) |
SbgErrorCode sbgEComTransferReceive | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
void * | pBuffer, | ||
size_t * | pActualSize, | ||
size_t | bufferSize | ||
) |
Specific method to handle a large receive from the device.
[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. |
Definition at line 590 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferReceiveData | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
void * | pBuffer, | ||
size_t | offset, | ||
size_t | packetSize | ||
) |
Receive one packet of data on a initiated download transfer.
[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. |
Definition at line 326 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferReceiveEnd | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg | ||
) |
Function that ends a download sequence with a device.
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
Definition at line 434 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferReceiveInit | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
size_t * | pSize | ||
) |
Initiates a download sequences with a device.
[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. |
Definition at line 213 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferSend | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
const void * | pBuffer, | ||
size_t | size | ||
) |
Specific method to handle a large send into multiple frames.
[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. |
Definition at line 502 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferSendData | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
const void * | pBuffer, | ||
size_t | offset, | ||
size_t | packetSize | ||
) |
Send one packet of data on a initiated upload transfer.
[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. |
Definition at line 84 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferSendEnd | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg | ||
) |
Ends ongoing upload transfer sequence with a device.
[in] | pHandle | Pointer to a valid SbgEComHandle. |
[in] | msgClass | Original protocol class asking for transfer. |
[in] | msg | Original protocol message id asking for transfer. |
Definition at line 150 of file sbgEComTransfer.c.
SbgErrorCode sbgEComTransferSendInit | ( | SbgEComHandle * | pHandle, |
uint8 | msgClass, | ||
uint8 | msg, | ||
size_t | size | ||
) |
Initiates an upload transfer sequence with a device.
[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. |
Definition at line 18 of file sbgEComTransfer.c.