BALTECH Docs |
C API for BALTECH SDK
|
This command group provides direct access to the USB host functionality of the uC. More...
#include "../typedefs.h"
Go to the source code of this file.
Macros | |
#define | BRP_UsbHost_UsbhstErrNotconnected BRP_ERR_STATUS(0x4400, 0x01) |
No device connected. More... | |
#define | BRP_UsbHost_UsbhstErrTimeout BRP_ERR_STATUS(0x4400, 0x02) |
Device did not respond within Timeout. More... | |
#define | BRP_UsbHost_UsbhstErrNack BRP_ERR_STATUS(0x4400, 0x03) |
Device responded only with NACK within Timeout. More... | |
#define | BRP_UsbHost_UsbhstErrStall BRP_ERR_STATUS(0x4400, 0x04) |
Device responded with STALL. More... | |
#define | BRP_UsbHost_UsbhstErrTransfer BRP_ERR_STATUS(0x4400, 0x05) |
Error on transferring data (CRC, Invalid PID, ...). More... | |
#define | BRP_UsbHost_UsbhstErrUnexpectedPkt BRP_ERR_STATUS(0x4400, 0x06) |
Device sent unexpected data. More... | |
#define | BRP_UsbHost_UsbhstErrBufferoverflow BRP_ERR_STATUS(0x4400, 0x07) |
Received too much data. More... | |
#define | BRP_UsbHost_UsbhstErrSetupPipes BRP_ERR_STATUS(0x4400, 0x20) |
Failure on setting up pipes. More... | |
Functions | |
brp_errcode | brp_UsbHost_Enable (brp_protocol protocol, bool Enable) |
Enable/Disable the USB-Host-Interface of the uC. More... | |
brp_errcode | brp_UsbHost_IsConnected (brp_protocol protocol, bool *Connected) |
Check if a device is connected. More... | |
brp_errcode | brp_UsbHost_SetupPipes (brp_protocol protocol, brp_UsbHost_SetupPipes_Pipes_Entry *Pipes, size_t Pipes_len) |
Setup all Pipes Definitions (uC's internal configuration). More... | |
brp_errcode | brp_UsbHost_SetAddr (brp_protocol protocol, unsigned Address) |
Set Address of device. More... | |
brp_errcode | brp_UsbHost_Reset (brp_protocol protocol) |
Send a Reset via USB interface, Remove all Pipes Definitions and reset address of device to 0. More... | |
brp_errcode | brp_UsbHost_TransRawSetup (brp_protocol protocol, brp_buf SetupData, unsigned PipeNo, unsigned Timeout) |
Transfers a raw SETUP packet. More... | |
brp_errcode | brp_UsbHost_TransSetupIn (brp_protocol protocol, brp_buf SetupData, unsigned PipeNo, unsigned Timeout, brp_buf *InData, size_t *InData_len, brp_mempool *mempool) |
Transfers a SETUP transaction with a IN DATA stage. More... | |
brp_errcode | brp_UsbHost_TransSetupOut (brp_protocol protocol, brp_buf SetupData, brp_buf OutData, size_t OutData_len, unsigned PipeNo, unsigned Timeout) |
Transfers a SETUP transaction with a OUT DATA stage. More... | |
brp_errcode | brp_UsbHost_TransIn (brp_protocol protocol, unsigned PipeNo, unsigned Timeout, brp_buf *InData, size_t *InData_len, brp_mempool *mempool) |
Transfers an IN transaction. More... | |
brp_errcode | brp_UsbHost_TransOut (brp_protocol protocol, brp_buf OutData, size_t OutData_len, unsigned PipeNo, bool Continue, unsigned Timeout) |
Transfers an OUT transaction. More... | |
brp_errcode | brp_UsbHost_Suspend (brp_protocol protocol) |
Send a Suspend via USB interface. More... | |
brp_errcode | brp_UsbHost_Resume (brp_protocol protocol) |
Send a Resume via USB interface. More... | |
This command group provides direct access to the USB host functionality of the uC.
Definition in file usbhost.h.