Flex Config User Guide

Flex Config User Guide

The "Flex Config" application is mainly for internal ON Semiconductor use only, targeted mainly to Application Engineers, but is also available to customers.
Note: if something goes wrong with a Demo3 FW updated, follow these instructions to recover.

It enables a user to store a sensor or ISP configuration on the Demo3 that gets applied upon power-up, and optionally can enable the HDMI port of the Demo3.It can also optionally setup the UVC default Descriptor and download FW that converts the Demo3 in to a UVC device.
Intended use-cases include;

  • Automotive (SOCs and ISPs); in conjunction with headboard Flash programming of the headboard, demonstrate that by only applying power to the Demo3 that images can be streamed.
    • The configuration binary must be programmed in to the headboard Flash/EEPROM before proceeding.
  • Mobile; for ICP (AP1301/AP1302), store custom configurations that don't require DevWare initialization.
  • Enable the Demo3 be an UVC plug-and-play device with the default Descriptor.

Note; follow these steps before running the Flex Config application;

  1. Run DevWareX and run the Preset that will be used.
    1. For ISPs, that will be the configuration from the binary programmed in the headboard's Flash/EEPROM device for self-booting.
    2. For SOCs, that will be "Demo Initialization for the "Interface" in the table below.
    3. For ICPs, that will be the configuration for the attached sensor.
  2. Once an image is shown, record the following information.
    1. From the "Info" dialog, record "Width", "Height", and "FPS (Sensor)".
    2. From the "Control / Diagnostics / Serial Receiver", record the "Connection Type", "Lanes" (if not parallel), and "Serial Bit Depth".
    3. If the headboard is not using the on-board Oscillator go to "Control / Diagnostics / Demo 3" - record the value of "XMCLK".

Supported SOCs.

The Demo3 can be updated with UVC FW to enable select SOCs to be UVC devices,. This same tool is used to program a Demo3 back to a USB device.

Each supported SOC has its own unique UVC FW image that must be programmed in to the Demo3 in order to enable it to be be used as a UVC device.
The following is a list of the supported SOCs along with their revision and interface; note that these must be a direct match for SOC to work properly.

Note; use the headboard's on-board Oscillator - in most cases, the jumper will be labeled as "CLKGEN".

SOCRevI2C_addrInterface

MT9M114

REV20x90Parallel
AS0260REV20x90MIPI-2lane
MT9V114REV20x7AParallel
MT9V115REV10x7AParallel
MT9V117REV10x90Parallel
ASX340REV20x90Parallel
ASX370REV30x78Parallel
MT9V124REV20x7AParallel
MT9V128REV40x90Parallel

HW Configuration

Connect the Demo3 board to the PC/laptop. From the "Start" menu select  All Programs → Aptina Imaging → Tools → Flex_Config Tool. The intro page should show up.

Intro Page

This page shows the mode of the connected Demo3 device. It tells you whether the device is in USB/UVC mode. It also tells you the version of the stage-2 firmware on the Demo3. If the Demo3 board is not connected or it did not boot correctly, you will see "Device Not Found". Unplug the device and plug it back in. Please wait for the device to register with Windows (wait for the sound feedback from Windows indicating that the device has been connected), before starting the tool. Click Next to continue.

Note; if the application doesn't launch, open Windows "Task Manager / Process", select "Flex_Config.exe" and then "End Process". Then unplug/plug-in the USB3 cable to reset the Demo3.


Reboot Page

To read and program the flex Config, the Demo3 must be rebooted to Flash Programming firmware.
The tool will do this when you click the Reboot Device button. It should take 15 to 30 seconds. Once the device Reboot is complete, click Next to continue.

Note; if this step fails, exit the application and unplug/plug-in the USB3 cable to reset the Demo3 and try again.
If it fails again, remove the sensor headboard.


Current Flex Config Page

This page gives details about the current flex configuration stored on the Demo3. It tells you whether the flex configuration is valid, and it displays a text description about the configuration.
It also tells you the output format it is configured for, the output interface it uses, whether HDMI interface was configured, and whether XMCLK was programmed on the Demo3.


Next, it gives 3 options in the form of radio buttons.

  1. No change to Config – This means that the current settings are acceptable and you do not want to change them. Just click Next to Continue.
    In most cases this is only to program new UVC FW.
  2. Invalidate Current Config – This invalidates the current configurations, so that the Demo3 does not load it the next time it boots.
    Once invalidated, the configuration cannot be re-validated. It must be re-programmed with the USB Demo3 FW.
    Important Note; you MUST program the USB FW back in to the Demo3 in the dialog "Current FW Mode" - 100E02*.img (the "*" is the version, but there will only be 1 file with that name).
  3. Program a New Config – If this option is selected, it enables a drop-down box with options for the type of the new configuration.
    This option is used to convert a USB Demo3 in to a UVC Demo3.
    1. For ISPs (AP010x/AP020x with per-programmed Flash/EEPROM); "Program a new Config" and "No config file".
    2. For SOCs; "Program a new Config" and "No config file".
    3. For ICPs (AP1301/AP1302);  "Program a new Config" and "ICP-2/ICP-3 XML File".

Click Next to Continue.

Program New Config Page

This page asks for a few inputs from the user in order to program the flex configuration correctly, and to get the Demo3 up with the right settings.

 
Configuration file – This is an XML file with bootdata section for ICP configuration.
The tool extracts the bootdata section from the XML and programs it on the SPI.It is only enabled when either of the ICP options were selected from the previous page.
Note; this option is only enabled when you have select "ICP" for the "Select New Configuration Type" from the previous dialog.
Configuration Description – Enter a text description of the config. This text will be displayed in the Current Flex Config page the next time you run this tool.
Output Settings

  • Enter the output width, height and frame rate recorded earlier.
  • Enter the Output Interface recorded earlier.
  • Optionally enable HDMI output.
  • If the headboard oscillator is not being used, select the checkbox for "Program XMCLK (Mhz) and enter the recorded value.
    The frequency value is in MHz; for example, for 24MHz output, enter 24.

Click "Program Flex Config" button to program the configuration on the Demo3 SPI flash. Once the programming is completed the message "All Done!" is displayed.
Click Next to Continue.

Current FW mode Page

This page asks you whether you want to switch the mode of the Demo3 from USB to UVC or vice versa.
Click the YES radio button if you wish to update the stage-2 firmware on Demo3.

Important Note; if you selected "Invalidate Current Config", you MUST program the USB FW back in to the Demo3 in the dialog "Current FW Mode" - 100E02*.img (the "*" is the version, but there will only be 1 file with that name).
If you forget to do this, the Demo3 may become inoperable. If that has occurred, please follow the directions found here.


Program New Firmware Page

This page gives you a list of options of "IMSG" available to load onto SPI.

  • To return the Demo3 to USB mode, select "100E02*.img".
  • To enable UVC for an SOC, select "100E*_<sensor name>.img".
  • To enable UVC for an ISP (AP010x/AP020x) for ICP (AP1301/AP1302), select "100E*_FlexConfig.img".

Select one, and click on "Program New Firmware" button to program the new firmware. Wait for the status to say "Programming Done"
Click Next to Continue.


Conclusion Page

Click Finish to cancel. Reboot device by unplugging and plugging in the Demo3 device again.

Recovery Instructions

It is possible that a FW update could render the Demo3 inoperative.
Here's a link to Recovery Instructions in case that happens.