The Host <-> Device communication transport.
This contains the types used to transfer messages between the Host (typically a machine running a full OS) and the PIC device.
|
struct | IOVec |
| An IOVector, with a pointer to memory and a length attribute. More...
|
|
typedef void(* TransportRxFunction)(const uint8_t *, unsigned int) |
A function pointer to call when data is received from the host.
- Parameters
-
data | A pointer to the new data. |
size | The size of the data received. |
typedef bool(* TransportTXFunction)(uint8_t, Command, uint8_t, const IOVec *, unsigned int) |
A function pointer to send a message to the host.
- Parameters
-
token | The frame token, this should match the request. |
command | the Command identifier to send |
rc | The 8-bit return code. |
iov | A pointer to an array of IOVec structures. The data will be copied. |
iov_count | The number of IOVec structures in the array. |
Flags use in a response message.
Enumerator |
---|
TRANSPORT_FLAGS_CHANGED |
Flags have changed.
|
TRANSPORT_MSG_TRUNCATED |
The message has been truncated.
|