SLAA450G April 2010 – April 2020
This is the primary loop function of the BSL. This function receives all bytes for a Core Command and returns a value to the Core Command based on the results. The return value definitions are:
DATA_RECEIVED
The data was successfully received. No checks were performed to verify whether or not the command itself is valid; however, the bytes were correctly received as sent by the host and can be safely processed.
RX_ERROR_RECOVERABLE
Some error occurred during receiving of a packet. The packet is lost, but the receive function can be called again.
RX_ERROR_REINIT
Reserved for when an error occurs during receiving of a packet that would require the PI_init() function be called again before receiving further packets.
RX_ERROR_FATAL
Reserved for when an error occurs during receiving of a packet that renders further communication impossible. A complete system restart is required.
PI_DATA_RECEIVED
Indicates that a packet was received and processed by the Peripheral Interface. No action is required other than calling the PI_receivePacket() function again.