FlashTool

Overview and Features

Summary

Flash Tool is part of the DevSuite software toolset, and allows you to generate binary images and write them to non-volatile memory. Most Flash Tool functionality requires a Sensor Data (.xsdat) file to be loaded. If a sensor is attached to the computer via USB, Flash Tool will automatically find the Sensor Data file for you. The following sensors are supported:  A-356SOC (MT9V126-138), AP0100AT/CS, AP0101AT, and ASX340AT/CS.

The images Flash Tool generates are composed of records such as register sets, variable sets, bitmap overlays, string overlays, patches, Host Command Interface (HCI) commands, and vendor-specific records. Records can be placed in initialization tables that are run when the sensor starts up and placed in command sequences which can be invoked from an initialization table or via the I2C protocol during run-time).

HCI commands are powerful tools to control sensor operation. In fact, Flash Tool itself uses HCI commands to write the binary image to memory. To help you create commands, there is a Host Command Interface Plug-In built into DevWareX. From this Plug-In, HCI command sequences can be copied (in .ini format) and imported into Flash Tool. Other .ini sources (such as DevWare’s preset .ini files) can also be imported into Flash Tool. 

This page is intended as an overview and introduction to Flash Tool. For a more in-depth discussion of Flash Tool use, please refer to Flash Tool’s in-application Help.

Installation

Flash Tool comes packaged with the DevSuite installer. By default, Flash Tool will be installed to C:\Aptina Imaging\flashtool

Within this install folder you will find:

    • Flashtoolgui.exe -- the main application (a shortcut is also placed in the Start Menu) 
    • Folders full of sensor-specific sample files.

Support NVM Devices

Flashtool can be used with several types of non-volatile memory (NVM): SPI Flash, SPI EEPROM, and ‘Virtual Flash’ OTPM (one-time programmable memory). The device type is configured within Flash Tool, and support varies by sensor. If you have questions about what devices are supported for your sensor, please contact an Aptina Application Engineer.

Quick Start Tutorial

Start up

1) Start Flash Tool

Open Start Menu ->All Programs -> Aptina Imaging -> Tools -> Flash Tool

2) Load the Sensor Data file(s) - Sensor Info Tab

If you have a sensor attached via USB: the Sensor Data file will load automatically.

If you DO NOT have a sensor attached: manually load a Sensor Data File by clicking “Load” and selecting the .xsdat file for your sensor. The default location is C:\Aptina Imaging\sensor_data. If you are using an AP010x or AP020x sensor, you will have an option to also load a Superset/Far Sensor, default location: C:\Aptina Imaging\sensor_data\configurations

3) Load a Configuration File - Configuration Tab

Click the “Load” button to the right of the Configuration file field, open the folder for your sensor and select a sample configuration file (FCFG file). The default location is C:\Aptina Imaging\flashtool\YOUR_SENSOR.

Depending on the particular Configuration file you have loaded, the various "Table" contents of this tab will vary and may be empty. See Help within Flash Tool for more details.

4) Click through the Initialization Tables

When the sensor starts up, it will automatically load and run all the records within each initialization table, in the order left to right in the "Select Table" section. Which tables are available to you depends on your sensor, but will certainly include Global, Patch, and Calibration.

Click on each of the Radio Buttons in the "Select Table" section to see what records have been loaded by your Configuration file.

Creating Records

1)    Create a Command Sequence and a Record
    • Click the "Command Sequence" Radio button and then the “Add New Record” button.

    • Use "Select "Record Type" to select a value and then fill in the parameters.
    • Click the “Finish” button; you'll see the new entry in the "List of Command Sequences" section.
2)   Create other Records as required
    • Select the appropriate Table via the "Select Table" Radio button.

Load HCI commands from DevWare plug-in into Flash Tool

    • Open DevWare with a sensor attached
    • Go to the “Plug-ins” menu and select “Host Command Interface”
    • With the “System Manager” tab selected, double-click “0x8100 Set State”
    • Set the “STATE” Parameter to “0x28 …”
    • Click the big “Run” button. The command’s Result Status will show in the bottom-right, and the command will show up under “Log”
    • Change the “STATE” Parameter to another value and hit “Run” again

Now let's import those commands into Flash Tool!

    • First check the “ini” radio button under Log, then click the “Copy All” button
    • Switch to Flash Tool and select The "Command" that you created.
    • Click the “Convert INI” button, and click “Load Text” in the pop-up window
    • Paste (Ctrl-v) into this window and click “OK
    • Click the “Convert” button

    • Click “Add and Close”

You should notice two records inserted into your command sequence. Select each one and you’ll see that one of them is ignored by Flash Tool because it is not supported.

Hit the “Delete Records” button to remove it.

Save your Configuration to File

    • Select the "Save FCFG" button. 
    • Specify a location and file name and then hit Save.

All of the records in the “Table of Content Setting” and “Initialization Table Setting” have been saved and can be reloaded in future Flash Tool sessions.

Prepare to Generate and Write Images

To generate images and write them to Flash, you must specify the memory type/size that your image will be written to.

    • Select the “Generate Image and Program” tab
    • Specify the Memory Type (optional)

For all sensors except for the MT9V126-138 series, you can select between EEPROM and Flash. Make sure you also select the correct sub-type. If you select “Standard Flash” then fill in the Block Size and Page Size for your device. 

    • Specify the Device Size

Fill in the device’s Memory Size (if necessary) and choose a Maximum Image Size greater than 0 but less than Memory Size. Flash Tool will make sure the image it generates is smaller than the Maximum Image Size.

Generate a Flash Image and Write to NVM

  • Click the “Generate Image” button and specify a name/location for the binary image.
  • Click “Program Image Into Flash” and select the binary image file you specified in step 1.

Graduation!

You are now a successful alumni of the Flash Tool Quick Start Tutorial. Use your power wisely.

If you need further help, please reference Flash Tool’s in-application help, the Detailed Help File,  or contact an Aptina Application Engineer.