I.MX6 platform as an example to explain the principles of programming software NXP MFGTool

Using NXP i.MX6 time series chips will be used to transfer software MFGTool Micro USB line by connecting the PC and development board USB A-type mouth to give the corresponding chip burning process, this paper explains MFGTool software programming principles .

 

First, the software configuration

To the official website to download L4.1.15_2.0.0-ga_mfg-tools.tar.gz package as an example. In the local decompression after the official website to download a good package, as shown in Figure unpacked as follows, in which the red arrow is pointing to files and folders need to modify and pay attention to when configuring the download tool place.

File Description:

cfg.ini File: to configure file mirroring the folder location, and a list of instructions which ucl2.xml executed, the definition of some initialization parameters.

UICfg.ini: MfgTool software can simultaneously define the SoC few burn, official documentation maximum set value 4, corresponding to four.

Document /: use of documentation on Mfgtool;

Drivers/: USB iMX_BulkIO_Driver;

Profiles /: storing the image files you want to burn and ucl.xml;

mfgtool.log: log records of Mfgtool during use.

mfgtool2 - *** vbs:. .vbs file is used to perform MfgTool2.exe script and pass parameters to the software, if cfg.ini file also defines the default .vbs same parameters in the parameters covered in cfg.ini the parameter values.

 

Two, Mfgtool works

Reference  517-MFGTOOLCustomizationGuide.pptx official start ppt flowchart which describes the Mfgtool.

 

1, when the board is powered on i.MX6, nothing initialization, only Chip ROM (internal chip ROM) can run. Chip ROM will be the default program to initialize USB, and configure it as a HID device. That's why the board is set to Download mode and after power on the PC side of the Device Manager can be seen on HID-compliant device is connected.

2, once the PC is detected on HID devices are connected, then the PC (USB Host) will go to enumerate the device and establish a connection. Establishing a first thing after the connection is a transport mini uboot (firmware) to the target board the SoC Chip RAM (chip internal RAM) and then starts running mini uboot (firmware). mini uboot will initialize the target board, mainly to initialize DDR / external ROM and other equipment, so after DDR and external ROM already visited. mini uboot memory initialization code or data extracted from the mini uboot to perform tasks. You can also use memory initialization script to obtain initial data.

3, the basic external interfaces after initialization, PC side will mini kernel (firmware), mini system (firmware), dtb (firmware) and transmitted to the SoC into DDR (external RAM) specified address. The PC then sends commands (ucl2.xml in <CMD state = "BootStrap" type = "jump"> Jumping to OS image. </ CMD>) Chip ROM allowed to jump to the kernel first address of the DDR to do it.

4, then jump to the Kernel, initialize the USB drive, and enumerated as a MSC device case can SoC high speed data transmission and host.

5, after the PC MFGTool tools ucl2.xml script in the rest of the instructions executed one by one until the last encounter Done command.

Note:

* Mini mentioned above uboot, mini kernel, mini system, dtb files are \ Profiles \ Linux \ OS Firmware \ firmware folder in the software directory.

* Mini kernel must configure USB, USB mass storage drive, SD card, UTP and so on. See: mfgtools \ Document \ V2 \ Manufacturing Tool V2 Linux or Android Firmware Development Guide V2.docx document.

* Mini kernel start linuxrc as the first process, linuxrc is actually a script to start the final UTP transmission protocol by performing uuc. UTP is driven as an extension USB Mass Storage (v4 Kernel), so start UTP must be reset and then re-enumerate USB.

The basic principle of this MFGTool to explain finished. After work will help understand the mechanism MFGTool developers easier to find problems in the future development process, or may be based on their need to provide a customized MFGTool future reference.

Original link: https://www.forlinx.com/article_view_367.html

Related Products:

Guess you like

Origin www.cnblogs.com/armbord/p/12555479.html