This section describes error codes that occur on the module and in the IRI host library code. These error codes indicate when module, RFID, or host library operations fail, and can be used to indicate what has gone wrong.
Each error code has both a category and an error ID, which are combined into a single value when reported in most circumstances. For example, the E_IPJ_ERROR_GEN2_TAG_MEMORY_OVERRUN error, which has a category constant of 1 and an error ID of 2, will be presented with a combined error constant of 0x01000002.
When an error occurs in a module, the error code is stored in the key E_IPJ_KEY_LAST_ERROR, at value_index 0. If the error has additional reported paramters, they will be stored at value_index of 1 through 4. Errors that occur on the module will usually be communicated to the IRI host, resulting in API function error return types.
When an error occurs in the IRI host library API code execution, it is returned by the called API function. Almost all of the IRI host library API functions have a return type of ipj_error. This makes it easy to capture and examine error events.
Error codes will also be printed by the Indy module on the debug UART, UART2, as they occur, as described in the debugging section under Error Printing Behavior.
When writing IRI host firmware, logic should be implemented to examine these error codes and respond appropriately. The Example Programs demonstrate a very basic error handling behavior, simply printing the error codes and ending operation.
The error handling configuration examples contain 2 examples pertaining to error codes. The first example shows how to read error codes from the keys. The second example shows how to clear stored errors.
Name | Category | Error constant | Description |
---|---|---|---|
E_IPJ_ERROR_SUCCESS | 0 | 0x00000000 | Successfully performed last operation, or no error since boot |
E_IPJ_ERROR_GENERAL_ERROR | 0 | 0x00000001 | Generic error |
E_IPJ_ERROR_SET_KEY_INVALID | 0 | 0x00000002 | Key set attempted with invalid key ID or other parameter |
E_IPJ_ERROR_SET_KEY_READ_ONLY | 0 | 0x00000003 | Key set attempted on read only key |
E_IPJ_ERROR_SET_KEY_OUT_OF_RANGE | 0 | 0x00000004 | Key set attempted with value out of valid range |
E_IPJ_ERROR_GET_KEY_INVALID | 0 | 0x00000005 | Key get attempted with an invalid key ID or other parameter |
E_IPJ_ERROR_GET_KEY_WRITE_ONLY | 0 | 0x00000006 | Key get attempted on write only key |
E_IPJ_ERROR_COMMAND_INVALID | 0 | 0x00000007 | IRI host library start() API function call had an invalid action argument |
E_IPJ_ERROR_COMMAND_START_FAILURE | 0 | 0x00000008 | IRI host library command start failed for an unknown reason |
E_IPJ_ERROR_COMMAND_DECODE_FAILURE | 0 | 0x00000009 | IRI host library failed to decode module packet |
E_IPJ_ERROR_COMMAND_ENCODE_FAILURE | 0 | 0x0000000A | IRI host library failed to encode a packet to a module |
E_IPJ_ERROR_COMMAND_STALLED | 0 | 0x0000000B | Command has failed to complete within the required time |
E_IPJ_ERROR_VALUE_INVALID | 0 | 0x0000000C | Module configuration value invalid |
E_IPJ_ERROR_MORE_THAN_ONE_COMMAND_RECEIVED | 0 | 0x0000000D | Module received multiple conflicting commands |
E_IPJ_ERROR_NOT_IMPLEMENTED | 0 | 0x0000000E | Module’s application image does not support the requested feature |
E_IPJ_ERROR_INVALID_PRODUCT_CONFIGURATION | 0 | 0x0000000F | Module contains an invalid configuration |
E_IPJ_ERROR_INVALID_FACTORY_SETTINGS | 0 | 0x00000010 | Module contains invalid factory settings |
E_IPJ_ERROR_RESPONSE_ENCODE_FAILURE | 0 | 0x00000011 | Module encountered an error while trying to encode a report or response |
E_IPJ_ERROR_COMMAND_VERIFY_FAILURE | 0 | 0x00000012 | Module detected that the intended data was not properly written |
E_IPJ_ERROR_INTERNAL_NON_RECOVERABLE | 0 | 0x00000013 | Module encountered an internal non-recoverable error. |
E_IPJ_ERROR_TEMPLATE_DECODE_FAILURE | 0 | 0x00000014 | Module was unable to properly decode the command template |
E_IPJ_ERROR_SYSTEM_IN_ERROR_STATE | 0 | 0x00000015 | Module is in an error state due to a non-recoverable error |
E_IPJ_ERROR_TEST_ERROR | 0 | 0x00000016 | Manually generated test error has occured |
E_IPJ_ERROR_STORED_SETTING_DECODE | 0 | 0x00000017 | Error decoding the stored settings |
E_IPJ_ERROR_VALUE_INDEX_OUT_OF_RANGE | 0 | 0x00000018 | Key set or get value_index parameter is out of range |
E_IPJ_ERROR_BANK_INDEX_OUT_OF_RANGE | 0 | 0x00000019 | Key set or get API bank_index parameter is out of range |
E_IPJ_ERROR_INVALID_PRODUCT_CALIBRATION | 0 | 0x0000001A | Module contains invalid calibration data |
E_IPJ_ERROR_REPORT_SIZE_WOULD_OVERFLOW | 0 | 0x0000001B | Requested report fields and data would overflow the IRI tag operation report buffer. |
E_IPJ_ERROR_FIXED_HARDWARE_SETTINGS_LOAD_ERROR | 0 | 0x0000001C | Fixed hardware settings were not loaded properly |
E_IPJ_ERROR_GEN2_TAG_OTHER_ERROR | 1 | 0x01000001 | Tag error catch-all for tag errors not covered by other codes |
E_IPJ_ERROR_GEN2_TAG_MEMORY_OVERRUN | 1 | 0x01000002 | Tag memory location does not exist or the EPC length field is not supported |
E_IPJ_ERROR_GEN2_TAG_MEMORY_LOCKED | 1 | 0x01000003 | Tag memory location cannot be accessed |
E_IPJ_ERROR_GEN2_TAG_INSUFFICIENT_POWER | 1 | 0x01000004 | Tag has insufficient power to perform the memory write operation |
E_IPJ_ERROR_GEN2_TAG_NON_SPECIFIC_ERROR | 1 | 0x01000005 | Tag error when tag does not support specific error codes |
E_IPJ_ERROR_API_DEVICE_NOT_INITIALIZED | 2 | 0x02000001 | IRI host library structure iri_device not properly initialized |
E_IPJ_ERROR_API_SERIAL_PORT_ERROR | 2 | 0x02000002 | IRI host library unable to control UART serial port |
E_IPJ_ERROR_API_CONNECTION_READ_TIMEOUT | 2 | 0x02000003 | IRI host library timed out waiting for UART traffic from module |
E_IPJ_ERROR_API_CONNECTION_WRITE_TIMEOUT | 2 | 0x02000004 | IRI connection write timeout |
E_IPJ_ERROR_API_CONNECTION_WRITE_ERROR | 2 | 0x02000005 | IRI host library failed to write data to the UART transmit properly |
E_IPJ_ERROR_API_RX_BUFF_TOO_SMALL | 2 | 0x02000006 | IRI host receive buffer too small |
E_IPJ_ERROR_API_MESSAGE_INVALID | 2 | 0x02000007 | IRI host detected an invalid message |
E_IPJ_ERROR_API_NO_HANDLER | 2 | 0x02000008 | IRI host library has no handler function registered to handle this action |
E_IPJ_ERROR_API_INVALID_LOADER_BLOCK | 2 | 0x02000009 | IRI host library flash loader API was passed an invalid block |
E_IPJ_ERROR_API_RESPONSE_MISMATCH | 2 | 0x0200000A | IRI host library received a response which does not match the command that was sent |
E_IPJ_ERROR_API_INVALID_PARAMETER | 2 | 0x0200000B | IRI host library API detected an invalid parameter |
E_IPJ_ERROR_API_NON_LT_PACKET_DETECTED | 2 | 0x0200000C | IRI-LT host library receive routine detected a non-LT packet |
E_IPJ_ERROR_IRI_FRAME_DROPPED | 3 | 0x03000001 | IRI host library received a missing or malformed IRI packet |
E_IPJ_ERROR_IRI_FRAME_INVALID | 3 | 0x03000002 | IRI host library received an IRI packet with an invalid frame CRC or parity |
E_IPJ_ERROR_MAC_GENERAL | 4 | 0x04000001 | A non-specific communication error occurred inside the module |
E_IPJ_ERROR_MAC_CRC_MISMATCH | 4 | 0x04000002 | Module detected a CRC mismatch on tag response |
E_IPJ_ERROR_MAC_NO_TAG_RESPONSE | 4 | 0x04000003 | Module detected no tag response |
E_IPJ_ERROR_MAC_TAG_LOST | 4 | 0x04000004 | Module detected the tag was lost mid-transaction |
E_IPJ_ERROR_BTS_DEVICE_WATCHDOG_RESET | 5 | 0x05000001 | Module experienced a watchdog reset |
E_IPJ_ERROR_BTS_VALUE_INVALID | 5 | 0x05000002 | Module bootloader command contains an invalid value |
E_IPJ_ERROR_BTS_FLASH_WRITE | 5 | 0x05000003 | Module bootloader error writing to flash |
E_IPJ_ERROR_BTS_FLASH_READ | 5 | 0x05000004 | Module bootloader error reading from flash |
E_IPJ_ERROR_BTS_FLASH_ADDRESS | 5 | 0x05000005 | Module bootloader error erasing flash because address is protected |
E_IPJ_ERROR_BTS_FLASH_ERASE | 5 | 0x05000006 | Module bootloader error erasing flash |
E_IPJ_ERROR_BTS_UNKNOWN_COMMAND | 5 | 0x05000007 | Module bootloader received an unknown command |
E_IPJ_ERROR_BTS_COMMAND_DECODE_FAILURE | 5 | 0x05000008 | Module bootloader was unable to decode a command |
E_IPJ_ERROR_TRANSCEIVER_FAILURE | 6 | 0x06000001 | Module error communicating with internal transceiver |
E_IPJ_ERROR_LIMIT_PA_TEMPERATURE_MAX | 7 | 0x07000001 | Module PA temperature exceeded part specification |
Successfully performed last operation, or no error since boot
This error code is returned or stored in the E_IPJ_KEY_LAST_ERROR key when the module boots up, and when operations complete successfully. It does not indicate an error has occurred.
Generic error
This error occurs in various unlikely scenarios that are not given their own error codes, including many errors that occur when using the test commands.
Key set attempted with invalid key ID or other parameter
This error occurs if a key set operation is attempted with an invalid key ID, or some other invalid parameter.
Check the key listing for a ist of valid key IDs, and ensure that sets are not being attempted with invalid key IDs.
Key set attempted on read only key
This error occurs when there is an attempt to set a key that is read only.
Check the key listing for write permissions for each key, and ensure that sets are not being attempted on read only keys.
Key set attempted with value out of valid range
This error occurs when a key is set to a value that is out of its valid range.
Check the key listing for the minimum and maximum values for the key associated with this error, and ensure that keys aren’t being set out of range.
Key get attempted with an invalid key ID or other parameter
This error occurs when a key get or bulk get is performed with an invalid key ID, or some other invalid parameter.
Check the key listing for key IDs for each key, and ensure that gets are not being attempted with invalid key IDs.
Key get attempted on write only key
This error occurs when there is an attempt to get a key value that is write only.
Check the key listing for read permissions for each key, and ensure that gets are not being attempted on write only keys.
IRI host library start() API function call had an invalid action argument
This error occurs when a start() API function call has an invalid action argument.
IRI host library command start failed for an unknown reason
This error occurs when a start() API function call fails for a reason other than the others listed here.
IRI host library failed to decode module packet
This error occurs when the IRI host library API fails to decode a packet from a module.
IRI host library failed to encode a packet to a module
This error occus when the IRI host library API fails to encode a packet to be sent to a module.
Command has failed to complete within the required time
This error occurs when an IRI host configures the module to perform a command or action that must complete within a specified amount of time, and the action fails to complete in that time.
One example is a UART baud rate detection that fails to detect a valid baud rate within the internal time limit.
Module configuration value invalid
This error occurs when the internal logic of the module determines that some aspect of the configuration is invalid.
For example, it will occur if the automatically detected UART baud rate is detected to be out of range of valid values.
Module received multiple conflicting commands
Module’s application image does not support the requested feature
This error occurs when an IRI host requests a module use a specific feature that was not yet implemented in the version of the application image that is loaded on the module.
To update the application image on a module, use the bootloader.
Module contains an invalid configuration
This error occurs when a start() API function call is attempted on a module with an invalid product configuration.
This usually indicates that the product configuration stored in module non-volatile memory was not initialized or was damaged after initialization.
Module contains invalid factory settings
This error occurs when a start() API function call is attempted on a module with invalid factory settings.
This usually indicates that the factory settings stored in module non-volatile memory were not initialized or were damaged after initialization.
Module encountered an error while trying to encode a report or response
Module detected that the intended data was not properly written
Module encountered an internal non-recoverable error.
Module was unable to properly decode the command template
Module is in an error state due to a non-recoverable error
This error occurs when a non-recoverable error has occurred and the module is in an error state.
When this error occurs, more information will be stored in the key E_IPJ_KEY_SYSTEM_ERROR.
Issuing a E_IPJ_ACTION_CLEAR_ERROR action with the start() API will clear the error.
Manually generated test error has occured
This error occurs when an IRI host configures a module to execute the error control test by setting the E_IPJ_KEY_TEST_ID key to the value E_IPJ_TEST_ID_ERROR_CONTROL.
For more details on using the test commands, see the Test Commands configuration examples.
Error decoding the stored settings
This error occurs when decoding stored settings fails at a particular key code.
The failing key code is reported in the first error parameter, stored in key E_IPJ_KEY_LAST_ERROR at value_index 1.
For more details on this error, see the Stored Settings documentation.
Key set or get value_index parameter is out of range
This error occurs when there is an attempt to set or get a key value with an invalid value_index.
Check the key listing for the number of vales for each key.
For more information about the bank and value index arguments of the ipj_set() and ipj_get() APIs, see the Configuration Commands configuration examples.
Key set or get API bank_index parameter is out of range
This error occurs when there is an attempt to set or get a key value with an invalid bank_index.
Check the key listing for the number of banks for each key.
For more information about the bank and value index arguments of the ipj_set() and ipj_get() APIs, see the Configuration Commands configuration examples.
Module contains invalid calibration data
This error occurs when a start() API function call is attempted on a module with invalid calibration data.
This usually indicates that the calibration data stored in module non-volatile memory was not initialized or was damaged after initialization.
Requested report fields and data would overflow the IRI tag operation report buffer.
This error occurs when a tag operation report, with contents as configured by key E_IPJ_KEY_REPORT_CONTROL_TAG, would exceed the maximum size.
Fixed hardware settings were not loaded properly
This error occurs when the module’s firmware fails to load the fixed hardware settings that are programmed into it at calibration.
It has been observed to occur when power supply conditions are unusual or out of spec during startup. If this error occurs during development, the power supply topology and behavior should be inspected. If it occurs in the field, the module should be reset by either a software reset(using the ipj_reset(...) API) or a hardware reset(using the nRST or ENABLE pin).
Tag error catch-all for tag errors not covered by other codes
Tag memory location does not exist or the EPC length field is not supported
This error occurs when tag access operations are attempted with invalid parameters, such as an invalid memory locations or an invalid EPC length field. If this error is encountered, verify the tag’s memory configuration using its technical documentation.
Tag memory location cannot be accessed
This can occur because the specified tag memory location is locked or permalocked, or is either not writeable or not readable.
Tag has insufficient power to perform the memory write operation
This error occurs when a tag memory write is attempted and the tag responds with an error indicating that it does not have sufficient power to perform the write. Tags have different power thresholds to perform different operations, and memory write operations are the most power intensive.
Tag error when tag does not support specific error codes
IRI host library structure iri_device not properly initialized
This error occurs when the IRI host library does not properly initialize the iri_device structure.
IRI host library unable to control UART serial port
This error occurs when the IRI host library is unable to control the UART serial port used to implement IRI communication with the module.
IRI host library timed out waiting for UART traffic from module
This error occurs when the IRI host library runs out of time while waiting for IRI traffic to return from the module.
This usually indicates the module lost power or was disconnected from the host partway through communication, or traffic from the module to the host is being lost somehow.
IRI connection write timeout
IRI host library failed to write data to the UART transmit properly
This error occurs when the IRI host library attempts to transmit an IRI packet via the UART and fails to send a complete packet. This usually indicates some problem with the implementation of UART functionality of the platform specific port code.
IRI host receive buffer too small
IRI host detected an invalid message
IRI host library has no handler function registered to handle this action
This error occurs when the IRI host library’s iri_device struct does not have a valid handler function defined to handle a required action for IRI operation.
iri_device function handlers are registered using the IRI library API function ipj_register_handler().
IRI host library flash loader API was passed an invalid block
This error occurs when the IRI host library’s ipj_flash_handle_loader_block() API is passed a data block with an invalid CRC during an application image bootload operation.
IRI host library received a response which does not match the command that was sent
This error occurs when the IRI host library sends a command, then receives a response that does not correspond to that command.
This can happen if multiple commands are sent, or a response is somehow missed or lost by the host.
IRI host library API detected an invalid parameter
This error occurs when the IRI host library APIs are called with invalid parameters.
Some examples of invalid parameters are a NULL pointer, an array length that is too large, etc.
For more details on the IRI host library APIs and their parameters, see the IRI API functions reference.
IRI-LT host library receive routine detected a non-LT packet
This error occurs when the host is configured for IRI-LT operation, and the module communicates a non-IRI-LT packet to it unexpectedly.
IRI host library received a missing or malformed IRI packet
This error occurs when the IRI host library detects a packet from a module without the proper length or structure.
IRI host library received an IRI packet with an invalid frame CRC or parity
This error occurs when the calculated IRI frame CRC or parity did not match the value that was sent.
It usually indicates some error in packet formation or transmission.
A non-specific communication error occurred inside the module
Module detected a CRC mismatch on tag response
Module detected no tag response
Module detected the tag was lost mid-transaction
Module experienced a watchdog reset
This error occurs when a module’s watchdog reset functionality detects that it has reached an unrecoverable firmware operating state, and has reset it.
Module bootloader command contains an invalid value
This error occurs when a module’s bootloader has detected that a command was sent from a host with an invalid command argument.
Module bootloader error writing to flash
This error occurs when a module’s bootloader is incapable of performing a flash write as instructed by the IRI host, due to an invalid address or other configuration error.
Module bootloader error reading from flash
This error occurs when a module’s bootloader is incapable of performing a flash read as instructed by the IRI host, due to an invalid address or other configuration error.
Module bootloader error erasing flash because address is protected
This error occurs when a module’s bootloader is incapable of erasing the flash as instructed by the IRI host, because the address is protected from erasure.
Module bootloader error erasing flash
This error occurs when a module’s bootloader is incapable of erasing the flash as instructed by the IRI host, because of a reason other than flash protection.
Module bootloader received an unknown command
This error occurs when a module’s bootloader receives an unknown command from the IRI host.
Module bootloader was unable to decode a command
This error occurs when a module’s bootloader receives a command from the IRI host but is unable to properly decode it.
Module error communicating with internal transceiver
This error occurs when internal communications with the radio transciever inside the module fail.
Module PA temperature exceeded part specification
This error occurs when the power amplifier temperature exceeds the maximum allowed value. The occurrence of this error will stop any ongoing RFID operation immediately to allow the PA to cool.
The temperature of the PA should be monitored using the E_IPJ_KEY_TEMPERATURE_PA key, and when it has returned to a lower value, RFID operations may be resumed.
For more information on managing module temperatures, see the device datasheets and hardware user’s guides.