11 #ifndef __BRP_BALTECH_API_CMDS_FTOB_H__ 12 #define __BRP_BALTECH_API_CMDS_FTOB_H__ 13 #include "../typedefs.h" 18 #define BRP_Ftob_ErrInvalidFilename BRP_ERR_STATUS(0x0300, 0x01) 23 #define BRP_Ftob_ErrFileAccessDenied BRP_ERR_STATUS(0x0300, 0x02) 28 #define BRP_Ftob_ErrWriteBlock BRP_ERR_STATUS(0x0300, 0x03) 33 #define BRP_Ftob_ErrReadBlock BRP_ERR_STATUS(0x0300, 0x04) 38 #define BRP_Ftob_ErrNoFileActive BRP_ERR_STATUS(0x0300, 0x05) 43 #define BRP_Ftob_ErrOutOfMemory BRP_ERR_STATUS(0x0300, 0x06) 48 #define BRP_Ftob_ErrBroken BRP_ERR_STATUS(0x0300, 0x07) unsigned int brp_errcode
This type is used library-wide for passing error codes in the return value of functions.
struct brp_protocol_t * brp_protocol
This is a generic handle of a protocol.
struct brp_mempool_object_t * brp_mempool
mempool handle.
brp_errcode brp_Ftob_OpenWriteFile(brp_protocol protocol, brp_buf Filename, size_t Filename_len, unsigned *MaxBlockLen)
brp_errcode brp_Ftob_ReadFileBlock(brp_protocol protocol, bool ToggleBit, unsigned MaxBlockLength, brp_buf *BlockData, size_t *BlockData_len, brp_mempool *mempool)
brp_errcode brp_Ftob_WriteFileBlock(brp_protocol protocol, bool ToggleBit, brp_buf BlockData, size_t BlockData_len)
brp_errcode brp_Ftob_CloseFile(brp_protocol protocol, bool Success)
unsigned char * brp_buf
represents a pointer to a protocol data buffer.
brp_errcode brp_Ftob_OpenReadFile(brp_protocol protocol, brp_buf Filename, size_t Filename_len)