User manual

www.ti.com
Bluetooth Low Energy
Table 23-115. Descriptions of the Actions to Take on Received Packets
Action Number bCrcErr bIgnore Description
1 0 1 End operation with BLE_DONE_OK status
2 0 0 Transmit SCAN_RSP message
3 1 0 End operation with BLE_DONE_RXERR status
4 0 0 End operation with BLE_DONE_CONNECT status
Stop receiver immediately and end operation with
5
BLE_DONE_NOSYNC status
If a SCAN_REQ packet is received with a length of 12 (or less), it is viewed as an empty packet. This
means that if pParams->RXConfig.bAutoflushEmpty is 1 and bCrcErr and bIgnore are both 0, the packet
is removed from the RX buffer. If a packet is flagged by bIgnore or bCrcErr, it may also be removed,
based on the bits in pParams->RXConfig.
If the packet received did not fit in the RX queue, the packet is received to the end, but the received bytes
are not stored. If the packet would normally not have been discarded from the RX queue based on the bits
in pParams->RXConfig, the command ends.
If the next action according to Table 23-114 and Table 23-115 is to transmit a SCAN_RSP, the radio CPU
starts the transmitter to transmit this packet. It consists of a header, an advertiser address, and advertising
data. The radio CPU constructs these packets as follows. In the header, the PDU Type bits are 0100b.
The TXAdd bit is as shown in pParams->advConfig.devicAddrType. The length is calculated from the size
of the scan response data, pParams->scanRspLen + 6. The RXAdd bit is not used and is 0, along with the
RFU bits. The payload starts with the 6-byte device address, which is read from pParams-
>pDeviceAddress. The rest of the payload is read from the pParams->pScanRspData buffer. After the
SCAN_RSP has been transmitted, the command ends.
A trigger to end the operation is set up by pParams->endTrigger. If the trigger defined by this parameter
occurs, the radio operation continues to completion, but the status code after ending is
BLE_DONE_ENDED and the result is False. This can, for instance, be used to stop execution instead of
proceeding with the next chained operation by use of the condition in the command structure. If the
immediate command CMD_STOP is received by the radio CPU, it has the same meaning as the end
trigger occurring, except that the status code after ending is CMD_DONE_STOPPED.
The output structure pOutput contains fields which give information on the command being run. The radio
CPU does not initialize the fields, so this must be done by the system CPU when a reset of the counters is
desired. The fields are updated by the radio CPU as described below. The list also indicates when
interrupts are raised in the system CPU.
When the ADV*_IND packet has been transmitted, nTXAdvInd is incremented and a TX_DONE
interrupt is raised.
If a SCAN_RSP packet has been transmitted, nTXScanRsp is incremented afterwards, and a
TX_DONE interrupt is raised.
If a SCAN_REQ is received with CRC OK and the bIgnore flag cleared, nRXScanReq is incremented.
If the payload length is 12 or less, an RX_EMPTY interrupt is raised. If the payload length is greater
than 12, an RX_OK interrupt is raised.
If a CONNECT_REQ is received with CRC OK and the bIgnore flag cleared, nRXConnectReq is
incremented and an RX_OK interrupt is raised.
If a packet is received with CRC error, nRXNok is incremented and an RX_NOK interrupt is raised.
If a packet is received and the bIgnore flag is set, nRXIgnored is incremented and an RX_IGNORED
interrupt is raised.
If a packet is received that did not fit in the RX queue, nRXBufFull is incremented and an
RX_BUF_FULL interrupt is raised.
If a packet is received, lastRssi is set to the RSSI of that packet
If a packet is received, timeStamp is set to a time stamp of the start of than packet. For a
CONNECT_REQ, this can be used to calculate the anchor point of the first packet.
If the first RX data entry in the RX queue changed state to Finished after a packet was received, an
RX_ENTRY_DONE interrupt is raised.
1533
SWCU117AFebruary 2015Revised March 2015 Radio
Submit Documentation Feedback
Copyright © 2015, Texas Instruments Incorporated