Functions | |
| void | Cy_ISOUART_HostInit (ISOUART_Type *base, const cy_stc_isouart_host_config_t *config) |
| Full Init of the iso UART in host mode. More... | |
| void | Cy_ISOUART_HostEnableWakeSequence (ISOUART_Type *base, uint32_t wakeCmdDelay) |
| Enables the transmission of wake sequence. More... | |
| __STATIC_INLINE uint8_t | Cy_ISOUART_HostReadLowInterface (const ISOUART_Type *base) |
| Reads the latest frame data from the Low interface. More... | |
| __STATIC_INLINE uint8_t | Cy_ISOUART_HostReadHighInterface (const ISOUART_Type *base) |
| Reads the latest frame data from the High interface. More... | |
| void | Cy_ISOUART_HostSendWriteCommand (ISOUART_Type *base, uint32_t blockId, uint32_t nodeId, uint32_t address, uint16_t data) |
| Sends a write command frame (sequenced mode) to a node. More... | |
| void | Cy_ISOUART_HostSendReadCommand (ISOUART_Type *base, uint32_t blockId, uint32_t nodeId, uint32_t address) |
| Sends a read command frame (sequenced mode) to a node. More... | |
| void | Cy_ISOUART_HostSendManualCommand (ISOUART_Type *base, uint8_t data) |
| Sends a single 8-bit frame in manual mode. More... | |
| bool | Cy_ISOUART_HostVerifyCRC (uint8_t frameData) |
| Verifies the CRC contained in a write response byte. More... | |
| void Cy_ISOUART_HostInit | ( | ISOUART_Type * | base, |
| const cy_stc_isouart_host_config_t * | config | ||
| ) |
Full Init of the iso UART in host mode.
| base | The base address for the iso UART. |
| config | Configuration options for the iso UART in host mode. See cy_stc_isouart_host_config_t. |
| void Cy_ISOUART_HostEnableWakeSequence | ( | ISOUART_Type * | base, |
| uint32_t | wakeCmdDelay | ||
| ) |
Enables the transmission of wake sequence.
The registered wake sequence will be sent prior to next command transmission.
| base | The base address for the iso UART. |
| wakeCmdDelay | Amount of delay between wake sequence and command frame. Each count corresponds to 1/(iso UART IP input clock [Hz]) seconds. Valid range is [0x2EE0 ... 0x3FFC]. The appropriate delay value is specific to the node hardware - refer to the target node IC datasheet for the required delay specification. |
| __STATIC_INLINE uint8_t Cy_ISOUART_HostReadLowInterface | ( | const ISOUART_Type * | base | ) |
Reads the latest frame data from the Low interface.
| base | The base address for the iso UART. |
| __STATIC_INLINE uint8_t Cy_ISOUART_HostReadHighInterface | ( | const ISOUART_Type * | base | ) |
Reads the latest frame data from the High interface.
| base | The base address for the iso UART. |
| void Cy_ISOUART_HostSendWriteCommand | ( | ISOUART_Type * | base, |
| uint32_t | blockId, | ||
| uint32_t | nodeId, | ||
| uint32_t | address, | ||
| uint16_t | data | ||
| ) |
Sends a write command frame (sequenced mode) to a node.
If a wake sequence was previously enabled with Cy_ISOUART_HostEnableWakeSequence(), the wake sequence is transmitted automatically before this frame.
| base | The base address for the iso UART. |
| blockId | Block ID placed in the frame when block ID feature is enabled. Valid range: 0..6 (ignored if block ID is disabled). |
| nodeId | Target node ID. 0 : Enumeration 1..30 : Normal node IDs 63 : Broadcast |
| address | Target register / SRAM address. Valid range: 0..127. |
| data | 16-bit payload to be written. |
| void Cy_ISOUART_HostSendReadCommand | ( | ISOUART_Type * | base, |
| uint32_t | blockId, | ||
| uint32_t | nodeId, | ||
| uint32_t | address | ||
| ) |
Sends a read command frame (sequenced mode) to a node.
If a wake sequence was previously enabled with Cy_ISOUART_HostEnableWakeSequence(), the wake sequence is transmitted automatically before this frame.
| base | The base address for the iso UART. |
| blockId | Block ID placed in the frame when the block ID feature is enabled. Valid range: 0..6 (ignored if the feature is disabled). |
| nodeId | Target node ID. 0 : Enumeration 1..30 : Normal node IDs 63 : Broadcast |
| address | Target register / SRAM address. Valid range: 0..127. |
| void Cy_ISOUART_HostSendManualCommand | ( | ISOUART_Type * | base, |
| uint8_t | data | ||
| ) |
Sends a single 8-bit frame in manual mode.
If a wake sequence was previously enabled with Cy_ISOUART_HostEnableWakeSequence(), the wake sequence is transmitted automatically before this frame.
| base | The base address for the iso UART. |
| data | 1 byte frame to transmit. |
| bool Cy_ISOUART_HostVerifyCRC | ( | uint8_t | frameData | ) |
Verifies the CRC contained in a write response byte.
Compares the lower 3 bits (CRC) of the supplied write response byte against the expected CRC looked up using the upper 5 bits as index. The response can be obtained via Cy_ISOUART_HostReadLowInterface() or Cy_ISOUART_HostReadHighInterface(). An interrupt after the write command completion indicates the reply is available.
| frameData | Write response frame byte (bits[7:3] = payload, bits[2:0] = CRC). |