Texas Instruments CC2650DK Benutzerhandbuch

Seite von 1570
Bluetooth Low Energy
In a generic receiver operation, the only assumption made on the packet format is that the 6 least
significant bits of the second received byte is a length field which indicates the length of the payload
following that byte, and that a standard BLE-type CRC is appended to the packet.
When tuned to the correct channel, the radio CPU starts listening for a packet. If sync is obtained on the
demodulator, the message is received into the RX queue (if any). If the length is greater than the
maximum allowed length for BLE advertising packets (37, but can be overridden), reception is stopped
and restarted.
If pParams->pRXQ is NULL, the received packets are be stored. The counters are still updated and
interrupts generated.
If a packet is received with CRC error, the bCrcErr bit is set. The bIgnored flag is never set for the generic
RX command.
If the packet being 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 buffer, the
operation ends.
A trigger to end the operation is set up by pParams->endTrigger and pParams->endTime. If the trigger
defined by this parameter occurs, the radio operation ends as soon as possible. If the trigger occurs while
waiting for sync, the operation ends immediately. If the trigger occurs at another time, the operation
continues until the current packet has been fully received, and then ends. 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.
If a packet is received with CRC OK, nRXOk 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 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
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.
After a packet has been received, reception is restarted on the same channel if pParams->bRepeat = 1,
the end event has not been observed, and the packet fits in the receive queue. If pParams->bRepeat = 0,
the operation always ends after receiving a packet.
A generic RX operation ends with one of the statuses listed in
. The status field of the
command structure after the operation is ended indicates the reason why the operation ended. In all
cases, a COMMAND_DONE interrupt is raised. In each case, it is indicated if the result is True, False, or
Abort, which decides the next action. The pNextOp field of a generic RX command structure may point to
the same command structure. That way, RX may be performed until the end trigger, or until the RX buffer
goes full.
Table 23-128. End of Generic RX Operation
Condition
Status Code
Result
Received a packet with CRC OK and pParams->bRepeat = 0
BLE_DONE_OK
True
Received a packet with CRC error and pParams->bRepeat = 0
BLE_DONE_RXERR
True
Observed trigger indicated by pParams->endTrigger while waiting for
BLE_DONE_ENDED
False
sync
Observed trigger indicated by pParams->endTrigger, then finished
BLE_DONE_ENDED
False
receiving packet
Observed CMD_STOP while waiting for sync
BLE_DONE_STOPPED
False
Observed CMD_STOP, then finished receiving packet
BLE_DONE_STOPPED
False
Received CMD_ABORT
BLE_DONE_ABORT
Abort
1543
SWCU117A – February 2015 – Revised March 2015
Radio
Copyright © 2015, Texas Instruments Incorporated