Detailed description of how to build the MTK Development Environment

Source: Internet
Author: User

MTK Development EnvironmentThis document describes how to create a learning tutorial.MTK Development EnvironmentFor details about how to create the content, see this article.

1. Development Host Requirements and required tools:

Operating System: Windows 2000, WinXP. Windows 2000 with SP2 or later is recommended.

Editor: ADS (Arm Developer Suite) v1.2 [Build 842]

Perl parsing: ActivePerl. ActivePerl 5.6.1 is recommended.

Simulation tool: mtk pc Simulator

Tracking Tool: Catcher_L1 v3.10.01. It outputs debugging information from the serial port. If you only use common UI applications, it will not be used. Just use the PC simulation tool.

Burning tool: FlashTool_UI v3.1.05 or FlashTool_v3.0844.00

He: PL2303_Driver_XP2K v204102, which is the USB serial port driver used in the download line. Previously, the PL2303 driver was installed on the machine. We recommend using this driver. Otherwise, there may be a blue screen problem.

2. Development Environment establishment process:

Create a directory in English. Otherwise, some tools do not know the Chinese path. Here E: \ Documents "is used ".

1) install ADS1.2

Decompress the huayu109_ads1.2.rar file to a directory. For example, extract the file to "E: \ MTK_P1300" and run "E: \ MTK_P1300 \ ADS1.2 \ Setup.exe" after decompression, finally, the selected file "E: \ MTK_P1300 \ ADS1.2 \ CRACK \ License" was installed. dat ", and then continue to the next step until the installation is complete. After installation, delete the directory "E: \ MTK_P1300 \ ADS1.2 \" to save disk space.

2) install the ADS patch

Run ads_patch_window.exe in the huayu102_ads12_patch_windows.rarcompressed file. This is a self-extracting compressed file. Select Unzip and decompress it to the installation directory of the ADS in the previous step (C: \ Program Files \ ARM \ ADSv1_2 ), if you ask whether to overwrite the data during decompression, overwrite all the data.

3) install the script interpreter Perl

Directly run the installation file with the extension msi in the compressed package huayu106_perlzip.rar. The default installation is good, all the way to Next, haha.

After completing the preceding steps, the compiling environment is basically created. You can open a dos window (Start Menu> RUN> input cmd> OK) to check the environment, if the installation is normal, run the following command successfully: armcc

Note that the version number should be ADS1.2 [Build 842]. If it is not, it may not be patched, or the position of the patch is incorrect. Please refer to the description in step 1 of ADS patch and try again, until the version number is correct, haha.

Perl -- version

NOTE 1: The above installation process will automatically create the environment variables required for the compilation environment. If the compilation is abnormal, it may be caused by the installation of other compilation tools, in this case, we recommend that you check the system environment variables, set the installation directories of Perl and ADS to the beginning, and remove the paths that may cause conflicting compilation tool chains (such as winavr) from the path)

4) code editing Environment

Run the installation file in the compressed file huayustm_source Insight3.5.rar to install it. As for the editor, I like it personally, but it is quite convenient to read the code from Source Inside.

5) PC Simulator

The Simulator mtk pc Simulator is used for simulation and debugging on the PC. You need to install VC6 SP6 (Uuicode static and dynamic databases must be installed at the same time. If there is no unicodelibrary, you can use the library in javashuayu103_mtksimulator dllpatch .zip, copy it to the system directory "% windir % \ system32 ). The VC on my machine has a Unicode library. If the Unicode library is not installed in the simulator compilation or running, we recommend that you reinstall VC6 and check the Unicode library during installation, and Patch sp6.

The simulator can simulate most of the actions of a real machine, which can bring great convenience for debugging and does not need to be burned every change.

Upload "to the directory" E: \ MTK_P1300 ", the directory" E: \ MTK_P1300 \ Taobao "appears to the directory

"E: \ MTK_P1300 \ P1300_V1.7_Release". during decompression, select full coverage to replace the modified files. If you have modified the files in the directory tree before patching, manually add them.

Before compiling a PC simulator, you need to build the directory tree you just obtained first, open a dos window, and convert the drive letter and directory to the drive letter and directory corresponding to the Code directory tree, for example:

 
 
  1. E:  
  2. cd E:\MTK_P1300\P1300_V1.7_Release\  
  3. make new 

NOTE 3: "make new" must be used for the first make operation. make new takes a long time (it takes more than two hours for a slow machine to make a new one ), some files cannot be found during the compilation process. As long as the compilation process is not terminated unexpectedly, the information can be ignored. Location of the compiled log File: build \ NEOTEL25_06B \ log \. To check the compilation process, check the files in this directory. The location of the generated binfile is build \ NEOTEL25_06B \*. bin. Download the burn-in is to burn the binfile.

The Command Format of build is introduced below:

Clear make new and re-compile the entire project

Make resgen re-generate resources

Make remake re-compile the linked Project

Make viewlog xxx view the compilation log of module xxx

Make

Note 4: If other gcc compilation tool chains (such as winavr) are installed on the machine, you may need to manually change the Path. Otherwise, the compilation will fail. For details about how to modify the Path, see note 1, you can also modify the batch file "E: \ MTK_P1300 \ P1300_V1.7_Release \ make. bat ", add the following two sentences before" perl make2.pl %:

 
 
  1. set PERL5LIB=D:\perl\lib  
  2.  
  3. set PATH=D:\perl\bin;d:\progra~1\arm\adsv1_2\bin;E:\MTK_P1300\P1300_V1.7_Release\tools;c:\windows\system32;c:\windows;c:\windows\system 

Note: The above path is on my machine. It is not the default installation path. You must modify it based on your actual installation path.

Next, compile the PC simulator. Use VC6 to open the project file "E: \ MTK_P1300 \ P1300_V1.7_Release \ plutommi \ mmi \ PC_Simulator.dsw". Then, compile the program for a long time, depending on the machine configuration, you can do something else.

Because the simulator project involves a large number of files and the compilation time is time-consuming, it is recommended that less windows be opened on the computer during the compilation process, especially for network-type ones, such as QQ. Sometimes, after QQ is opened, during compilation, VC will be suspended. It may be that after QQ is enabled, the firewall filters network data to occupy more system resources. If you find that VC compilation is particularly slow or simply crashes, you can restart the computer and open only necessary windows, then start compiling.

If a strange problem is found during compilation, such:

 
 
  1. Incomingstringiddef. h (120): error C2059: syntax error: 'constant' or
  2. Error C2065: 'str _ CM_REDIAL ': undeclared identifier

At this time, you may need to check the configuration sequence of your VC-related paths.

6) Tracer tracking tool

Decompress the file p1300_build_guide.rar to E: \ MTK_P1300, and then go to the directory "E: \ MTK_P1300 \ shortcuts to the desktop in the File Manager.

When TRACE is required, use the function in the code

 
 
  1. void kal_prompt_trace(module_type mod_id, const kal_char *fmt,...);  

Print the information you want to view and use the Catcher trace to view the information.

This is similar to the Linux Kernel.

7) burning tools

Decompress the file "E: \ MTK_P1300 \ P1300_Build_Guide \ FlashTool_UI_exe_v3.1.05.zip" to the current directory, and enter the "E: \ MTK_P1300 \ P1300_Build_Guide \ release shortcut to the desktop.

There is also a download tool flashtool_v3.0844.00.rar, which does not need to be installed. It is directly used after decompression. It is said that the burning speed is faster than the one above.

.

8) USB serial download Line Driver

Run compressed files

 
 
  1. “E:\MTK_P1300\P1300_Build_Guide\PL2303_Driver_XP2K_v204102.zip” 

To install the executable files.

Summary: I have explained the content of the MTK Development Environment establishment learning tutorial. I hope this article will help you!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.