Cypress PSoC 6 Bluetooth Low Energy Middleware Library 3.60
cy_stc_ble_hci_tx_packet_info_t Struct Reference

Description

Standard HCI command/data packet.

Data Fields

uint8_t * data
 Buffer to hold the HCI packet HCI Command Packet guide: More...
 
uint16_t dataLength
 Length of the parameters in HCI packet buffer in bytes.
 
uint8_t packetType
 HCI packet type : +___________________________________________+ | Packet Type | Value | |_______________________________|___________| | HCI Command packet type | 0x1 | | HCI ACL data packet type | 0x2 | | HCI Synchronous packet type | 0x3 | | HCI Event packet type | 0x4 | +----------------------------—|--------—+. More...
 

Field Documentation

◆ data

uint8_t* cy_stc_ble_hci_tx_packet_info_t::data

Buffer to hold the HCI packet HCI Command Packet guide:

0 4 8 12 16 20 24 28 32 Octet 0 Octet 1 Octet 2 Octet 3 +--------—+--------—+--------—+--------—+ | Opcode | Parameter | | ---------------------—| Total |Parameter 0| | OCF | OGF | Length | | +--------—+--------—+--------—+--------—+ |Parameter 1| | Parameter ... | +--------—+--------—+--------—+--------—+ | | | * | | * | | * | | | +--------—+--------—+--------—+--------—+ | Param N-1 | Parameter N | +--------—+--------—+--------—+--------—+

HCI Event Packet guide:

0 4 8 12 16 20 24 28 32 Octet 0 Octet 1 Octet 2 Octet 3 +--------—+--------—+--------—+--------—+ |Event Code | Parameter | | | | | Total |Parameter 0|Parameter 1| | | Length | | | +--------—+--------—+--------—+--------—+ |Parameter 1| Parameter ... | +--------—+--------—+--------—+--------—+ | | | * | | * | | * | | | +--------—+--------—+--------—+--------—+ | Param N-1 | Parameter N | +--------—+--------—+--------—+--------—+

HCI ACL Packet Guide:

0 4 8 +--------------------—+--------—+----------—+ | HCI HEADER | L2CAP HEADER | | |(only in Start of packet)| |--------------------—|----------------------—| |PDU Octet 1 |2 |3 |4 |5 |6 | ***** | |--------------------—+----------------------—| | * | | * | | * | |--------------------—+----------------------—| | ****|N-2 |N-1 |PDU Octet N (upto 247)| +--------------------—+----------------------—+

The ACL Packet HCI Header contains the following information: +___________________________________________________+ |–Conn Handle (12 bits)–|–Pkt Boundary (2 bits)–| |----------------------—|----------------------—+ |–HCI_LLID(2 bits)---— |–Length(16 bits)– | +----------------------—|----------------------—+

Note:

  1. Packet Boundary data indicates the following: +----------—+---------------—+---------------—+ | | Application to | Controller to | | | Controller | Application | +----------—|---------------—|---------------—| | 0x0u | Start of PDU | RESERVED | | 0x1u | Continuation PDU | RESERVED | | 0x2u | RESERVED | Start of PDU | | 0x3u | RESERVED | Continuation PDU | +----------—+---------------—+---------------—+
  2. HCI_LLID data indicates the following: +----------—+---------------—| | 0x0u | Start of PDU | | 0x1u | Continuation PDU | | 0x2u | RESERVED | | 0x3u | RESERVED | ------------------------------—|
  3. The value in the Length field does NOT include L2CAP header length (4 bytes).

◆ packetType

uint8_t cy_stc_ble_hci_tx_packet_info_t::packetType

HCI packet type : +___________________________________________+ | Packet Type | Value | |_______________________________|___________| | HCI Command packet type | 0x1 | | HCI ACL data packet type | 0x2 | | HCI Synchronous packet type | 0x3 | | HCI Event packet type | 0x4 | +----------------------------—|--------—+.

Note: HCI Synchronous packet type (0x3) HCI packets are not supported by PSoC 6 BLE