S
ERIAL
I
NTERFACE
D
EVELOPERS
G
UIDE
It is also recommended that the host check regularly (including the boot sequence) for the
UNCONFIGURED_CONTROLLER and the FAULT_DETECTED codes.
The FAULT_DETECTED code is set by the embedded application when a built-in test fails or when a
mismatch between the configured hardware and detected hardware occurs. The embedded software
will jump to an idle loop to give the host a chance to read error data (see paragraph
X
6.6
X
) and then set
the continue flag (structure member ‘continueFlag’, paragraph
X
6.2.3
X
). This idle routine has a timeout
and will automatically return after time expires.
The UNCONFIGURED_CONTROLLER code is set by the embedded application when it detects
erased product ID’s, missing Xilinx FPGA configuration files, or an error programming the FPGA
occurs. The embedded software will jump to an idle loop to give the host an opportunity to configure
the controller (load product ID’s, upload a Xilinx FPGA configuration file). This routine can not be
exited, a power on/reset is required to return to normal operation.
6.6 Error Code Detection (CAMERA_ERRORS)
During the boot process several checks are made of the hardware. If a fault is detected then an error
code is set along with any additional error data using the CAMERA_ERRORS data structure (see
paragraph
X
6.2.5
X
). Once the error data has been logged the code jumps to an idle state routine.
Inside this routine the global configuration member progress code (paragraph
X
6.2.5
X
) is set to
FAULT_DETECTED and a timer is started.
While in this idle state the host has the opportunity to determine that a fault has occurred, read the
error information and then set the continue flag (see paragraph
X
6.2.3
X
). If the host does not
acknowledge the error and the timer expires the code will continue operation. It should be noted that it
may take a significantly longer time to boot if errors are present and the host does not acknowledge
them appropriately.
The following is a list of possible error codes.
/* Camera Error Codes */
#define
ERR_NONE
0x0000
#define
ERR_PC_MSTR
0x8001
#define
ERR_FPGA_LOAD
0x8002
#define
ERR_FPGA_TEST
0x8003
#define
ERR_MEM_TEST
0x8004
#define ERR_VID_ENCODER
0x8005
#define
ERR_FORCE_ZERO
0x8006
#define
ERR_FORCE_ONE
0x8007
#define ERR_FORCE_COUNT
0x8008
#define
ERR_HISTO_GRAB
0x8009
#define ERR_GAIN_OFFSET
0x800A
#define ERR_FORCE_COUNT_COADD
0x800B
#define ERR_CONFIG_MISMATCH
0x800C
#define ERR_NUC_FLASH_PARAM
0x800D
#define
ERR_TEST_SKIPPED 0x8FFF
6.6.1 Configuration ID Error
This check is of the configuration ID’s stored in flash versus the ID’s read back via the ADC.
Data from CameraConfig.camErrors:
ErrorCode: ERR_CONFIG_MISMATCH define.
ErrorSubCode: a more specific description of the error from the following enumeration.
/* Cfg Board ID Error SubCodes (#define ERR_CONFIG_MISMATCH 0x800C) */
enum
{
ERR_LENS_MISMATCH = 1,
ERR_FPA_SPRT_BD_MISMATCH,
ERR_FPA_MISMATCH,
ERR_CAM_CTRL_BD_MISMATCH,
31