Difference between revisions of "Orange Pi 3"
Line 148: | Line 148: | ||
=== '''Build a compilation environment''' === | === '''Build a compilation environment''' === | ||
− | * Install JDK | + | * '''Install JDK''' |
Android 7.0 development can only use the version of openjdk8, higher or lower than this version and Oracle's JDK will cause the compilation to fail. Openjdk-8 installation command is as follows: | Android 7.0 development can only use the version of openjdk8, higher or lower than this version and Oracle's JDK will cause the compilation to fail. Openjdk-8 installation command is as follows: | ||
Line 157: | Line 157: | ||
</div> | </div> | ||
− | * | + | *'''Configure JAVA environment variables''' |
For example, the installation path is / usr / lib / jvm / java-8-openjdk-amd64. You can run the following command in the terminal to configure the environment variables: | For example, the installation path is / usr / lib / jvm / java-8-openjdk-amd64. You can run the following command in the terminal to configure the environment variables: | ||
Line 166: | Line 166: | ||
</div> | </div> | ||
− | * Install platform support software | + | * '''Install platform support software''' |
For Ubuntu 14.04: | For Ubuntu 14.04: | ||
Line 186: | Line 186: | ||
lichee/tools #Solution hardware configuration, packaging tools, etc. | lichee/tools #Solution hardware configuration, packaging tools, etc. | ||
</div> | </div> | ||
− | + | <br> | |
− | * | + | * '''Kernel compilation process''' |
− | + | <br> | |
Enter the following command in the lichee directory: | Enter the following command in the lichee directory: | ||
+ | <div style="background:#f1f1f1;border:1px solid #000;"> | ||
+ | $ cd OrangePi_3/lichee<br> | ||
+ | $ ./build.sh config<br> | ||
+ | <br> | ||
+ | Welcome to mkscript setup progress<br> | ||
+ | All available chips:<br> | ||
+ | <p style="padding-left:20px;"> | ||
+ | # sun50iw1p1 | ||
+ | # sun50iw2p1 | ||
+ | # sun50iw6p1 | ||
+ | # sun8iw11p1 | ||
+ | # sun8iw12p1 | ||
+ | # sun8iw6p1 | ||
+ | # sun8iw7p1 | ||
+ | # sun8iw8p1 | ||
+ | # sun9iw1p1 | ||
+ | </p> | ||
+ | Choice: 2<br> | ||
+ | All available platforms: | ||
+ | <p style="padding-left:20px;"> | ||
+ | # android | ||
+ | # dragonboard | ||
+ | # linux | ||
+ | # eyeseelinux | ||
+ | </p> | ||
+ | Choice: 0<br> | ||
+ | All available business: | ||
+ | <p style="padding-left:20px;"> | ||
+ | # 5.1 | ||
+ | # 4.4 | ||
+ | # 7.x | ||
+ | </p> | ||
+ | Choice: 2 | ||
+ | </div> | ||
+ | <br> | ||
+ | The output after compilation is as follows:<br> | ||
+ | <br> | ||
+ | <div style="background:#f1f1f1;border:1px solid #000;"> | ||
+ | regenerate rootfs cpio <br> | ||
+ | 15757 blocks<br> | ||
+ | 17099 blocks<br> | ||
+ | build_ramfs<br> | ||
+ | Copy boot.img to output directory ...<br> | ||
+ | Copy modules to target ...<br> | ||
+ | <br> | ||
+ | sun50iw6p1 compile Kernel successful<br> | ||
+ | INFO: build kernel OK.<br> | ||
+ | <br> | ||
+ | INFO: build rootfs ...<br> | ||
+ | INFO: skip make rootfs for android<br> | ||
+ | INFO: build rootfs OK.<br> | ||
+ | <span style="border-top:1px dashed #000;border-bottom:1px dashed #000;display:inline-block;">build sun50iw6p1 android 7.x lichee OK</span> | ||
+ | </div> |
Revision as of 15:46, 17 June 2022
Contents
Basic Features of Orange Pi 3
What is Orange Pi 3
Orange Pi is an open source single board card computer, a new generation of arm64 development board, which can run Android 7.0, Ubuntu and Debian operating systems. The Orange Pi single board computer uses Allwinner H6 system-on-chip and has 1GB or 2GB LPDDR3 memory.
Use of Orange Pi 3
We can use it to build:
- A computer
- A web server
- Game console
- HD video player
- Speaker
- Android
- ......
Who is the Orange Pi 3 designed for?
Orange Pi 3 is not just a consumer product, it is also designed for anyone who wants to use technology for creative creation. It is a very simple, fun and practical tool that you can use to build the world around you.
Orange Pi 3 hardware parameters
GPIO specifications
The following figure is the GPIO pin function diagram of Orange Pi 3:
Orange Pi 3 pin correspondence table | ||
CON12-P01 | VCC-3.3V | VCC-IO |
CON12-P02 | VCC-5V | DCIN |
CON12-P03 | TWI0-SDA | PD26 |
CON12-P04 | VCC-5V | DCIN |
CON12-P05 | TWI0-SCK | PD25 |
CON12-P06 | GND | GND |
CON12-P07 | PWM0 | PD22 |
CON12-P08 | S-UART-TX | PL02 |
CON12-P09 | GND | GND |
CON12-P10 | S-UART-RX | PL03 |
CON12-P11 | UART3-RX | PD24 |
CON12-P12 | PD18 | PD18 |
CON12-P13 | UART3-TX | PD23 |
CON12-P14 | GND | GND |
CON12-P15 | PL10 | PL10 |
CON12-P16 | PD15 | PD15 |
CON12-P17 | VCC-3.3V | VCC-IO |
CON12-P18 | PD16 | PD16 |
CON12-P19 | SPI1_MOSI | PH05 |
CON12-P20 | GND | GND |
CON12-P21 | SPI1_MISO | PH06 |
CON12-P22 | PD21 | PD21 |
CON12-P23 | SPI1_CLK | PH04 |
CON12-P24 | SPI1_CS | PH03 |
CON12-P25 | GND | GND |
CON12-P26 | PL08 | PL08 |
Development board instructions
Prepare hardware and software tools
Hardware requirements:
- Orange Pi 3 development board
- TF card, minimum 8GB capacity, class 10, it is recommended to use brand TF card, such as SanDisk 16G TF card
- For a compiling host, the configuration should preferably meet the following conditions:
64bit CPU;
8 GB and above;
100GB of free disk space;
The operating system is preferably
Ubuntu14.04 (for compiling Android source code)
Ubuntu18.04 (for compiling Linux source code)
Software Requirements:
- Orange Pi 3 SDK
- Orange Pi 3 firmware
- Android and Linux programming tools
The above software can be obtained through Github, Google Web Disk and Baidu Cloud Disk.
http://www.orangepi.online/downloadresources/
http://www.orangepi.cn/downloadresourcescn/
Power supply mode of development board
There are two ways to power the development board:
- DC (5V 2A) power supply: Power on after inserting the DC adapter
- Micro USB (5V 2A) OTG power supply:Plug in the Micro USB adapter to power on.
Android compilation environment
The following operations are performed on a PC with Ubuntu 14.04 installed. Other versions of Ubuntu systems or Linux distributions may have some differences.
Get SDK source code zip
After downloading the Android source package, first you need to combine multiple compressed files into one and then decompress them.
$ mkdir OrangePi_3
$ cat H6-2018-1-2.tar.gza* > OrangePi_3.tar
$ tar xf OrangePi_3.tar -C OrangePi_3
Build a compilation environment
- Install JDK
Android 7.0 development can only use the version of openjdk8, higher or lower than this version and Oracle's JDK will cause the compilation to fail. Openjdk-8 installation command is as follows:
$ sudo add-apt-repository ppa:openjdk-r/ppa
$ sudo apt-get update
$ sudo apt-get install openjdk-8-jdk
- Configure JAVA environment variables
For example, the installation path is / usr / lib / jvm / java-8-openjdk-amd64. You can run the following command in the terminal to configure the environment variables:
$ export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
$ export PATH=$JAVA_HOME/bin:$PATH
$ export CLASSPATH=.:$JAVA_HOME/lib:$JAVA_HOME/lib/tools.jar
- Install platform support software
For Ubuntu 14.04:
$ sudo apt-get update
$ sudo apt-get install git gnupg flex bison gperf build-essential \ zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 \ lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z1-dev ccache \ libgl1-mesa-dev libxml2-utils xsltproc unzip
$ sudo apt-get install u-boot-tools
Compile SDK source code
After the SDK is decompressed, there will be two subdirectories andorid and lichee under the decompressed directory. The main contents of the lichee directory are as follows:
lichee/brandy/u-boot-2014.07 #uboot Code directory
lichee/bootloader/uboot_2014_sunxi_spl #boot0 Code directory
lichee/linux-3.10 #Kernel code
lichee/tools #Solution hardware configuration, packaging tools, etc.
- Kernel compilation process
Enter the following command in the lichee directory:
$ cd OrangePi_3/lichee
$ ./build.sh config
Welcome to mkscript setup progress
All available chips:
- sun50iw1p1
- sun50iw2p1
- sun50iw6p1
- sun8iw11p1
- sun8iw12p1
- sun8iw6p1
- sun8iw7p1
- sun8iw8p1
- sun9iw1p1
Choice: 2
All available platforms:
- android
- dragonboard
- linux
- eyeseelinux
Choice: 0
All available business:
- 5.1
- 4.4
- 7.x
Choice: 2
The output after compilation is as follows:
regenerate rootfs cpio
15757 blocks
17099 blocks
build_ramfs
Copy boot.img to output directory ...
Copy modules to target ...
sun50iw6p1 compile Kernel successful
INFO: build kernel OK.
INFO: build rootfs ...
INFO: skip make rootfs for android
INFO: build rootfs OK.
build sun50iw6p1 android 7.x lichee OK