8,367
edits
Changes
no edit summary
Interface like the following:
<div>[[文件:Orange-pi-3g-iot-img7.png|800px|]]</div>
Using method for both Windows and Linux versions are same, here will illustrate with Linux version<br>
<br>
=== '''Method for Image Flashing''' ===
<br>
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
MTK suggesting Ubuntu12.04 version, if it is not this version and cannot connect to the computer, then you need to:<br>
$sudo apt-get remove modemmanager<br>
$sudo /etc/init.d/udev retstart<br>
Reboot your computer<br>
<br>
Download corresponding MTK driver according to your OS when running on Windows<br>
Unzip Driver_Auto_Installer_EXE_v5.1453.03.rar<br>
Install
</div>
<br>
* '''Unzip and open flash tool'''
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
$ unzip SP_Flash_Tool_v5.1644_Linux.zip<br>
$ cd SP_Flash_Tool_v5.1644_Linux<br>
$ sudo ./flash_tool.sh
</div>
<br>
If it is the first time you use this software, you might receive the warn like the following. It is normal to receive this, you could click OK enter into the software. In the future you could manually specified the path of Scatter File.
<div>[[文件:Orange-pi-3g-iot-img8.png|800px|]]</div>
* '''Enter into flash mode'''
a.Switch into Download page like the following:
<div>[[文件:Orange-pi-3g-iot-img9.png|800px|]]</div>
b.Click choose on the right side of Scatter-loading File and select the path of Scatter File like the following:
<div>[[文件:Orange-pi-3g-iot-img10.png|800px|]]</div>
c.After double click the selection, the '''partition information display section''' will automatically fill the path of each partition file and the absolute starting address to which they are to be flashed.
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img11.png|800px|]]</div>
d.In the top left corner of '''partition information display section''', there would be a drop-down menu. Three of this options:<br>
Format All + Download // Format all information on the partitions and re-download the selected partition<br>
Firmware Upgrade // Update the difference on the selected partition <br>
Download Only // Re-download no matter there is difference or not<br>
Please note it: Usually update firmware you only need to select '''Firmware Upgrade''', please <span style="color:red;">do not</span>
select '''Format All + Download'''<br>
It you select Format All, you will lose the calibration information which we worked before sending out products. If this situation is inadvertent, please contact the Orange Pi service and obtain the calibration parameters through the machine code, and re-flash the calibration parameters.<br>
e.Insert Jumper cap:
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img12.png|800px|]]</div>
f.Then connect with USB on PC and Mirco USB on Orange Pi via USB cable, the red LED will light up.<br>
g.Click Download button[[文件:Orange-pi-3g-iot-img13.png|100px|]]<br>
h.The interface would show like the following after downloaded:
<div>[[文件:Orange-pi-3g-iot-img14.png|800px|]]</div>
i.Take of the USB cable and insert Micro USB power supply<br>
Wait around 5 seconds, it will display the charging interface of shutdown<br>
When the Power button is loosened after 5 seconds, the system will start to enter the system<br>
When the updated partition is more, the first boot will take a long time (the full partition update needs 8min), please be patient.<br>
<br>
Windows OS would require to download SP_Flash_Tool_v5.1644_Win.zip, unzip and install it. Then could refer to the manual of Linux to flash image.
== '''Linux Compilation Environment Construction''' ==
=== '''Get Linux Source Code''' ===
<br>
* '''Orange Pi Source Code Downloader'''
<br>
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
$ sudo apt-get install git<br>
$ git clone https://github.com/orangepi-xunlong/OrangePi_Build.git<br>
$ cd OrangePi_Build<br>
$ ls<br>
Build_OrangePi.sh lib README.md
</div>
<br>
* '''Run the Downloader'''
<br>
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
$ ./Build_OrangePi.sh
</div>
<br>
Enter the root password and press Enter
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img15.png|800px|]]</div>
Choose 0 Build system with kernel/uboot/rootfs, enter the development board model selection interface.
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img16.png|800px|]]</div>
Choose 22 orangepi 3G-iot,Press Enter and start download Orange Pi 3G-iot Linux Source Code
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img17.png|800px|]]</div>
The downloaded source code will be stored in the same directory as OrangePi_Build. Orange Pi 3G-IOT Linux source code directory structure is as follows
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
├── bootloader Store preloader and lk source code<br>
├─ build.sh -> scripts/build.sh Compile the startup script<br>
├── external Store additional configuration files and partial code<br>
├── kernel Linux Kernel source<br>
├── output; Store the output file, generate it after compiling the source code<br>
├── scripts; Script file used by the compilation process<br>
└── toolchain; Cross compilation toolchain<br>
<br>
6 directories, 1 file
</div>
=== '''Compilation of Linux Source Code''' ===
<br>
* '''Execute the compilation start up script'''
<br>
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
$ cd OrangePi3G-iot<br>
$ ./build.sh
</div>
<br>
According to the board model to choose and press Enter.
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img18.png|800px|]]</div>
Enter the root password and press Enter, then select the function needed to execute.
<div style="padding-left:200px;">[[文件:Orange-pi-3g-iot-img19.png|800px|]]</div>
<br>
The functions of each option are as follows:<br>
* '''0 Build Release Image Compile full image'''
* '''1 Build Rootfs Compile Rootfs'''
* '''2 Build Uboot Compile preloader and lk'''
* '''2 Build Linux Compile kernel source code'''
<br>
<br>
Take the A board as an example, choose 0 Build Release Image, generate the following complete firmware package
<div style="border:1px solid #dddddd;background:#f1f1f1;padding:5px;">
output/images/<br>
├── OrangePi_3g-iot-A_ubuntu_xenial_server_linux3.4.67_v1.1<br>
│ ├── boot.img<br>
│ ├── boot_nand.img<br>
│ ├── boot_sd.img<br>
│ ├── lk.bin<br>
│ ├── logo.bin<br>
│ ├── MT6572_Android_scatter.txt<br>
│ ├── preloader_hexing72_cwet_lca.bin<br>
│ └── rootfs.img<br>
├── OrangePi_3g-iot-A_ubuntu_xenial_server_linux3.4.67_v1.1.tar.gz
</div>
Android burning tool can be used to burn the above image file into flash, please refer to Android firmware burning chapter.
== '''Linux Firmware Flashing''' ==
<br>
At present, the Linux system do not support modem and LCD screen。<br>
You can only login system via a serial port。After connecting to wifi, you can log in via ssh。<br>
When programming the system, the jumper cap connection method is as follows.
<div>[[文件:Orange-pi-3g-iot-img20.png|500px|]]</div>