8,367
edits
Changes
→How to install Debian system
<span id="basic-features-of-orange-pi-zero-3"></span>= '''Basic features of Orange Pi Zero 3'''=
[[\l|2.8.2. How to use the debugging serial port on the Ubuntu platform [33](#howFile:zero3-toimg3-use-the-debugging-serial-port-on-the-ubuntu-platform)1.png]]
[[\l|2File:zero3-img4.9. Instructions for using the 5v pin in the 26pin or 13pin interface of the development board to supply power [39](#instructions-for-using-the-5v-pin-in-the-26pin-or-13pin-interface-of-the-development-board-to-supply-power)png]]
[[\l|3.1File:zero3-img5. Supported linux image types and kernel versions [43](#supported-linux-image-types-and-kernel-versions)png]]
[[\l|3File:zero3-img6.2. Linux kernel driver adaptation [44](#linux-kernel-driver-adaptation)png]]
::[[\l|3.4.4File:zero3-img7. The setting method of root user automatic login in Linux desktop version system [49](#the-setting-method-of-root-user-automatic-login-in-linux-desktop-version-system)png]]
<p>[[\lFile:zero3-img8.png|3180px]][[File:zero3-img9.5png|195px]][[File:zero3-img10. Onboard LED Light Test Instructions png|198px]][50](#onboard[File:zero3-ledimg11-light-test-instructions)1.png|190px]]</p>
[[\l|3.6File:zero3-img12.png]]</ol><ol start="3. The method of manually expanding the capacity of the rootfs partition in the TF card [56](#the" style="list-method-of-manually-expandingstyle-type: decimal;"><li>Micro HDMI to HDMI cable, used to connect the-capacity-of-the-rootfs-partition-in-the-tf-card)]]development board to an HDMI monitor or TV for display</li>
[[\l|3.6.4File:zero3-img13. How to reduce the capacity of the rootfs partition in the TF card [62](#how-to-reduce-the-capacity-of-the-rootfs-partition-in-the-tf-card)png]]
[[\lFile:zero3-img14.png|3.7.1. Ethernet port test [66center]](#ethernet|}</ol><ol start="4" style="list-portstyle-test)]]type: decimal;"><li>Power supply, if you have a 5V/2A or 5V/3A power head, you only need to prepare a USB-to-Type C interface data cable as shown in the picture on the left below, and you can also use a cable similar to the picture on the right below A 5V/2A or 5V/3A high-quality USB Typc C interface power adapter integrated with the power head.</li>
[[\l|3File:zero3-img15.7png]] [[File:zero3-img16.2. WIFI connection test [68png]](#wifi</ol><ol start="5" style="list-style-connectiontype: decimal;"><li><p>13pin expansion board</p><ol style="list-test)]]style-type: lower-alpha;"><li>The physical object of the expansion board is as follows</li>
[[\l|3File:zero3-img17-1.7.3. The method of creating WIFI hotspot through create_ap [76png]](#the</ol><ol start="2" style="list-methodstyle-oftype: lower-creating-wifi-hotspot-through-create_ap)]]alpha;"><li>The way to insert the expansion board into the development board is as follows, remember not to insert it backwards</li>
[[\l|3File:zero3-img18.7.4. How to set static IP address [83png]](#how-to</ol><ol start="3" style="list-setstyle-statictype: lower-ip-address)]]alpha;"><li>The 13pin pin header on the Orange Pi Zero 3 development board can be connected to the expansion board to expand the functions that are not on the development board. The functions that the expansion board can use are as follows</li>
[[\l|3File:zero3-img19.8. SSH remote login development board [96png]](#ssh-remote</ol></li></ol><ol start="6" style="list-loginstyle-type: decimal;"><li><p>The mouse and keyboard of the USB interface, as long as the mouse and keyboard of the standard USB interface are acceptable, the mouse and keyboard can be used to control the Orange Pi development-board)]]</p></li><li><p>Infrared remote control, mainly used to control Android TV system</p></li>
[[\l|3File:zero3-img20.8.1. SSH remote login development board under Ubuntu [96](#ssh-remote-login-development-board-under-ubuntu)png]]
[[\l|3File:zero3-img21.9. HDMI test [99png]](#hdmi</ol><ol start="10" style="list-style-test)]]type: decimal;"><li>Heat sink, if you are worried that the temperature of the development board is too high, you can add a heat sink, and the heat sink can be pasted on the H618 chip</li>
[[\l|3.9File:zero3-img22.png]] [[File:zero3-img23-1. HDMI display test [99png]](#hdmi</ol><ol start="11" style="list-displaystyle-test)]]type: decimal;"><li>5V cooling fan, as shown in the figure below, both 5V and GND pins on the 26pin and 13pin interfaces of the development board can be connected to the cooling fan. The spacing between the 26pin and 13pin headers is 2.54mm. Refer to this Specifications can be purchased.</li>
[[\l|3File:zero3-img24-1.9.3. How to set HDMI resolution in Linux5.4 system [101png]]</ol><ol start="12" style="list-style-type: decimal;"><li><p>Matching shell '''(#how-pictures to-set-hdmi-resolution-in-linux5.4-systembe added)]]'''</p></li><li><p>USB to TTL module and DuPont line, when using the serial port debugging function, need USB to TTL module and DuPont line to connect the development board and computer</p></li>
[[\l|3File:zero3-img25-1.9.4. How to Modify the Framebuffer Width and Height of Linux5.4 System png]] [[102](#how-toFile:zero3-modify-the-framebuffer-width-and-height-of-linux5img26.4-system)png]]
::{| class="wikitable" style="width:800px;" |-| [[\l|http://www.orangepi.org/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-Zero-3.11html '''http://www. USB interface test [110](#usborangepi.org/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-interfaceZero-test)]3.html''']|}
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Note that the Linux image mentioned here specifically refers to the image of Linux distributions such as Debian or Ubuntu downloaded from the [[\l|3http://www.11orangepi.4. USB camera test [112](#usborg/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-cameraZero-test)]3.html Orange Pi data download page].'''</big>|}
::{| class="wikitable" style="width:800px;" |-| [[\l|3https://www.balena.12io/etcher/ '''https://www.2balena. Testing audio methods on desktop systems [116](#testing-audio-methods-on-desktop-systems)]io/etcher/''']|}
[[\l|3File:zero3-img27.14png]]</ol><ol start="6" style="list-style-type: decimal;"><li>Then you can choose to download the Portable version of balenaEtcher software. Temperature sensor [120](#temperatureThe Portable version does not need to be installed, and you can use it by double-sensor)]]clicking to open it</li>
[[\l|3File:zero3-img28.15. 13 Pin Description of the Pin Expansion Board Interface [122png]](#pin</ol><ol start="7" style="list-descriptionstyle-type: decimal;"><li>If the downloaded version of-balenaEtcher needs to be installed, please install it before using it. If you downloaded thePortable version of balenaEtcher, just double-pin-expansion-board-click to open it. The opened balenaEtcher interface)]]is shown in the figure below</li>
[[\l|3File:zero3-img29.16. 26 Pin Interface Pin Description [123](#pin-interface-pin-description)png]]
[[\lFile:zero3-img30.png|3.18. 26pin interface GPIO, I2C, UART, SPI and PWM test [126](#pin-interface-gpio-i2c-uart-spi-and-pwm-test)center]]
[[\lFile:zero3-img31-1.png|center]]|3.18.2. 26 How to set the pull}</ol><ol start="8" style="list-down resistance of pin GPIO port [128](#howstyle-type: decimal;"><li><p>The specific steps to use balenaEtcher to-set-burn theLinux image are as follows</p><ol style="list-pullstyle-down-resistancetype: lower-alpha;"><li><p>First select the path of the Linux image file to be burned</p></li><li><p>Then select the drive letter ofthe micro SD card</p></li><li><p>Finally click Flash to start burning the Linux image to the micro SD card</p>[[File:zero3-pin-gpio-port)img32.png]]</li></ol></li><li><p>The interface displayed in the process of burning the Linux image by balenaEtcher is shown in the figure below, and the progress bar displays purple, indicating that the Linux image is being burned into the micro SD card</p></li>
[[\l|3File:zero3-img33.18.3. 26pin SPI test [129png]](#pin</ol><ol start="10" style="list-spistyle-test)]]type: decimal;"><li>After burning the Linux image, balenaEtcher will also verify the image burned to the micro SD card by default to ensure that there is no problem in the burning process. As shown in the figure below, a green progress bar indicates that the image has been burnt, and balenaEtcher is verifying the burnt image.</li>
[[\l|3File:zero3-img34.18png]]</ol><ol start="11" style="list-style-type: decimal;"><li>After successful burning, the display interface of balenaEtcher is as shown in the figure below. If the green indicator icon is displayed, it means that the image burning is successful.4At this time, you can exit balenaEtcher, and then pull out the micro SD card and insert it into the micro SD card slot of the development board. 26pin I2C test [131](#_Toc31340)]].</li>
[[\l|3File:zero3-img35.18.6. PWM test method [136](#pwm-test-method)png]]
{| class="wikitable" style="width:800px;" |-| [[\l|3https://www.sdcard.org/downloads/formatter/eula_windows/SDCardFormatterv5_WinEN.zip '''https://www.19sdcard.3org/downloads/formatter/eula_windows/SDCardFormatterv5_WinEN. 26pin SPI test [145zip'''](#pin|}</ol><ol start="2" style="list-spistyle-testtype: lower-1)]]alpha;"><li><p>After downloading, unzip and install directly, and then open the software</p></li><li><p>If only a micro SD card is inserted into the computer, the drive letter of the micro SD card will be displayed in the " '''Select card''' " column. If multiple USB storage devices are inserted into the computer, you can select the corresponding drive letter of the micro SD card through the drop-down box</p></li>
[[\l|3.19.5File:zero3-img36. 26pin UART test [151](#pin-uart-test-1)png]]
[[\l|3File:zero3-img37.21. Check the chipid of the H618 chip [154png]](#check</ol><ol start="5" style="list-thestyle-chipid-oftype: lower-alpha;"><li>After formatting the micro SD card, the message shown in the-h618-chip)]]figure below will pop up, click OK</li>
[[\l|File:zero3-img38.png]]</ol></li></ol><ol start="4" style="list-style-type: decimal;"><li><p>Download the Linux operating system image file compression package that you want to burn from the [http://www.orangepi.org/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-Zero-3.22html '''Orange Pi data download page'''], and then use the decompression software to decompress it. Among the decompressed files, the file ending with ". Python related instructions [154](#pythonimg" is the image file of the operating system. The size is generally more than 1GB</p></li><li><p>Use Win32Diskimager to burn the Linux image to the micro SD card</p><ol style="list-style-relatedtype: lower-instructions)]]alpha;"><li>The download page of Win32Diskimager is</li>
{| class="wikitable" style="width:800px;" |-| [[\l|3.22http://sourceforge.1net/projects/win32diskimager/files/Archive/ '''http://sourceforge. Python source code compilation and installation method [154net/projects/win32diskimager/files/Archive/'''](#python|}</ol><ol start="2" style="list-sourcestyle-codetype: lower-compilationalpha;"><li><p>After downloading, install it directly. The interface of Win32Diskimager is as follows</p><ol style="list-andstyle-installation-methodtype: none;"><li><p>a) First select the path of the image file</p></li><li><p>b) Then confirm that the drive letter of the micro SD card is consistent with that displayed in the "'''Device'''" column</p></li><li><p>c)]]Finally click "'''Write'''" to start burning</p></li><div class="figure">
[[\l|3File:zero3-img39.22.2. Python to replace the pip source method [155](#python-to-replace-the-pip-source-method)png]]
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Note that the Linux image mentioned here specifically refers to the image of Linux distributions such as Debian or Ubuntu downloaded from the [[\l|3http://www.24orangepi.1. Install via docker [157](#installorg/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-viaZero-docker)]3.html Orange Pi data download page], and the Ubuntu PC refers to the personal computer with the Ubuntu system installed.'''</big>|}
::{| class="wikitable" style="width:800px;" |-| [[\l|3https://www.balena.io/etcher/ '''https://www.25balena. OpenCV installation method [163](#opencv-installation-method)]io/etcher/''']|}
[[\l|3File:zero3-img27.26. The installation method of the aapanel Linux panel [164png]](#the</ol><ol start="5" style="list-installation-methodstyle-type: decimal;"><li>Then choose to download the Linux version of-the-aapanel-linux-panel)]]software</li>
[[\l|3File:zero3-img40.27. face_recognition The installation and testing method png]]</ol><ol start="6" style="list-style-type: decimal;"><li>Download the image file compression package of the face recognition library Linux operating system that you want to burn from the [167](#face_recognitionhttp://www.orangepi.org/html/hardWare/computerAndMicrocontrollers/service-theand-installationsupport/Orange-andPi-testing-methodZero-3.html '''Orange Pi data download page'''], and then use the decompression software to decompress it. Among the decompressed files, the file ending with "'''.img'''" is the image file of-the-face-recognition-library)]]operating system. The size is generally above 1GB. The decompression command for the compressed package ending in 7z is as follows:</li>
[[\l|3File:zero3-img41.28.3. How to install Ubuntu 22.04 system [192png]](#how</ol><ol start="9" style="list-style-type: decimal;"><li><p>The specific steps touse balenaEtcher to burn the Linux image are as follows</p><ol style="list-installstyle-ubuntutype: lower-22.04-system)]]alpha;"><li><p>First select the path of the Linux image file to be burned</p></li><li><p>Then select the drive letter of the micro SD card</p></li><li><p>Finally click Flash to start burning the Linux image to the micro SD card</p></li>
[[\l|3.29.1File:zero3-img32. Remote login using NoMachine [197](#remote-login-using-nomachine)png]]
[[\l|3File:zero3-img42.30. How to install QT [204png]](#how</ol><ol start="11" style="list-style-type: decimal;"><li>After burning the Linux image, balenaEtcher will also verify the image burned into the micro SD card by default to-install-qt)]]ensure that there is no problem in the burning process. As shown in the figure below, a green progress bar indicates that the image has been burnt, and balenaEtcher is verifying the burnt image</li>
[[\l|3File:zero3-img43.31. How to install ROS [212png]](#how</ol><ol start="12" style="list-tostyle-install-ros)]]type: decimal;"><li>After successful burning, the display interface of balenaEtcher is as shown in the figure below. If a green indicator icon is displayed, it means that the image burning is successful. At this time, you can exit balenaEtcher, and then pull out the micro SD card and insert it into the micro SD card slot of the development board for use</li>
[[\l|3File:zero3-img44.31.1. How to install ROS 1 Noetic on Ubuntu 20.04 [212png]](#</ol><span id="how-to-installburn-rosandroid-1image-noeticto-ontf-ubuntu-20.04)]]card"></span>
::[[\l|3.33.2File:zero3-img45. Debian Bookworm System [224](#debian-bookworm-system)png]]
[[\l|3.34File:zero3-img46. The method of uploading files to the Linux system of the development board [230](#the-method-of-uploading-files-to-the-linux-system-of-the-development-board)png]]
[[\l|3File:zero3-img47.png]] [[File:zero3-img48.34png]]</ol><ol start="4" style="list-style-type: decimal;"><li><p>Then prepare a micro SD card with 8GB or larger capacity.2The transmission speed of the micro SD card must be '''class 10 or above'''. How It is recommended to upload files use a micro SD card of SanDisk and other brands</p></li><li><p>Then use the card reader to insert the micro SD card into the computer</p></li><li><p>Download the Android image and PhoenixCard programming tool from the development board Linux system in Windows PC [234](#howhttp://www.orangepi.org/html/hardWare/computerAndMicrocontrollers/service-toand-uploadsupport/Orange-filesPi-toZero-3.html '''Orange Pi data download page''']. '''<span style="color:#FF0000">Please ensure that theversion of the PhonenixCrad tool is PhonixCard-development-board-linux-system-in-windows-pc)]]4.2.8.</span>''' Please do not use the PhonixCard software version lower than 4.2.8 to burn the Android image. There may be problems with the Android image flashed by this version of the PhonixCard tool</p></li>
[[\l|3File:zero3-img49-1.35. Instructions for using the switch logo [239png]](#instructions</ol><ol start="7" style="list-for-usingstyle-type: decimal;"><li>Then use decompression software to decompress '''PhonixCard4.2.8.zip''', this software does not need to be installed, just find PhoenixCard in the-switch-logo)]]decompressed folder and open it</li>
[[\l|3File:zero3-img51.36. How to shut down png]]</ol><ol start="8" style="list-style-type: decimal;"><li>After opening PhoenixCard, if the micro SD card is recognized normally, the drive letter and restart capacity of the micro SD card will be displayed in the development board [239](middle list. '''<span style="color:#how-FF0000">Please make sure that the displayed drive letter is consistent with the drive letter of the micro SD card you want to burn</span>'''. If there is no display, you can try to-shut-down-and-restart-unplug the micro SD card, or click the-development-board)]]"'''Refresh Drive Letter'''" button in PhoenixCard</li>
[[\l|4File:zero3-img52-1. Linux SDK——orangepi-build instruction [240png]](#linux</ol><ol start="9" style="list-sdkorangepistyle-build-instructiontype: decimal;"><li>After confirming the drive letter, format the micro SD card first, and click the "'''Recover Card'''" button in PhoenixCard (if the "'''Recover Card'''" button is gray and cannot be pressed, you can first click the "'''Refresh Drive Letter'''" button)]]</li>
[[\l|4.2File:zero3-img53. Get the source code of linux sdk [242](#get-the-source-code-of-linux-sdk)png]]
[[\l|4File:zero3-img54-1.3. Compile u-boot [247png]](#compile</ol></li></ol><ol start="11" style="list-ustyle-boot)]]type: decimal;"><li>After burning, the display of PhoenixCard is as shown in the figure below. At this time, click the "'''Close'''" button to exit PhoenixCard, and then you can pull out the micro SD card from the computer and insert it into the development board to start</li>
[[\l|4.5File:zero3-img55-1. Compile rootfs [254](#compile-rootfs)png]]
[[\lFile:zero3-img56.png|5.1. Supported Android versions [261](#supported-android-versions)center]]
[[\lFile:zero3-img57.png|5.3. Onboard LED light display instructions [261](#onboard-led-light-display-instructions)center]]
[[\lFile:zero3-img58.png|5.5. How to use ADB [262center]](#how|}</ol><span id="instructions-for-using-the-micro-linux-system-in-the-toonboard-usespi-adb)]]flash"></span>
[[\l|5.6. View the method of setting HDMI display resolution [264](#viewFile:zero3-theimg59-method-of-setting-hdmi-display-resolution)1.png]]
<span id/div><ol start="what2" style="list-isstyle-orange-pi-zero-3type: decimal;"><li>The corresponding relationship between GND, TX and RX pins of the debugging serial port of the development board is shown in the figure below</spanli>== What is Orange Pi Zero 3 ==
[[File:zero3-img62.png]] {| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''The TX and RX of the serial port need to be cross-connected. If you don’t want to carefully distinguish the order of TX and RX, you can connect the TX and RX of the serial port casually first. If there is no output from the test serial port, then exchange the order of TX and RX. One order is right.'''</big>|}</ol><span id="purposehow-ofto-use-the-debugging-serial-port-orangeon-pithe-zeroubuntu-3platform"></span>== Purpose of Orange Pi Zero 3 ==
<span idol start="hardware-features-of-orange-pi2" style="list-zerostyle-3type: decimal;"><li>Then use the following command to install putty on Ubuntu PC</spanli>== Hardware Features of Orange Pi Zero 3 ==
{| class="wikitable" style="width:800px;"
|-
| test@test:~$ '''Introduction to hardware featuressudo apt update'''||-| CPU| Allwinner H618 quad-core 64-bit 1.5GHz high-performance Cortex-A53 processor|-| GPU| Mali G31 MP2
{| class="wikitable" style="width:800px;"
|-
| Memorytest@test:~$ '''sudo putty'''| 1GB}</ol><ol start="4" style="list-style-type: decimal;"><li>After executing the putty command, the following interface will pop up</li> [[File:zero3-img63.png]]</1ol><ol start="5" style="list-style-type: decimal;"><li>First select the setting interface of the serial port</li> <div class="figure"> [[File:zero3-img64.5GBpng]] </div></ol><ol start="6" style="list-style-type: decimal;"><li><p>Then set the parameters of the serial port</p><ol style="list-style-type: lower-alpha;"><li><p>Set '''Serial line to connect to'''to as '''dev/ttyUSB0''' (modify to the corresponding node name, usually /dev/ttyUSB0)</2GBp></4GB LPDDR4 li><li><p>Set '''Speed(shared with GPUbaud)''' to 115200 (the baud rate of the serial port)</p></li><li><p>Set '''Flow control''' as '''None'''</p></li> <div class="figure"> |[[File:zero3-img65-1.png]] </div></ol></li></ol>| Onboard storage<ol start="7" style="list-style-type: decimal;">| TF card slot<li><p>After setting the setting interface of the serial port, 16MB SPI Flashreturn to the Session interface</p>|<ol style="list-style-type: lower-alpha;">| Ethernet<li><p>First select the '''Connection type''' as Serial</p></li>| Support 10<li><p>Then click the '''Open''' button to connect to the serial port</100Mp></1000M Ethernetli> |<div class="figure"> [[File:zero3-img66.png]]| WIFI+Bluetooth| • AW859A chip, support IEEE 802.11 a</bdiv></gol></nli></acol><ol start="8" style="list-style-type: decimal;"><li>Then start the development board, BT5.0and you can see the Log information output by the system from the opened serial port terminal</li> |[[File:zero3-img67.png]]| Video Output</ol>| • Micro HDMI 2.0a<span id="how-to-use-the-debugging-serial-port-on-windows-platform"></span>
{| class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
| Audio output<big>'''There are many serial port debugging software that can be used under Windows, such as SecureCRT, MobaXterm, etc. The following demonstrates how to use MobaXterm. This software has a free version and can be used without buying a serial number.'''</big>| • Micro HDMI output}
{| class="wikitable" style="width:800px;"
|-
| Power Supply| USB Type C interface input|-| USB 2[https://mobaxterm.mobatek.net/ '''https://mobaxterm.0 port| 3 USB 2mobatek.0 HOST (two of them are through 13pin expansion board)net/''']|-}| 26pin connector</ol>| With I2Cx1, SPIx1, UARTx1 and multiple GPIO ports|-| 13pin connector| With USB <ol start="2.0 HOSTx2, TV" style="list-OUT, LINE OUT, IRstyle-RX, and 3 GPIO ports|type: lower-alpha;">| Debug serial port| UART-TX<li>After entering the MobaXterm download page, UART-RX and GND|-| LED light| Power light and status light|-| Infrared receiver| Support infrared remote control (via 13pin expansion board)|-| Supported OS| Android12 TV, Ubuntu, Debian, etc.|-| click '''Introduction of Appearance SpecificationsGET XOBATERM NOW!'''||-| Product Size| 85mm×56mm|-| Weight| 30g|-| [[File:media</image1.%20png]]{width=“0.255 55555555555554in” h eight=“0.27638888 88888889in”}range Pi™ is a registered trademark of Shenzhen Xunlong Software Co., Ltd.||}li>
[[File:zero3-img68.png]]<span id/ol><ol start="top-view-and-bottom-view-of-orange3" style="list-pistyle-zerotype: lower-3alpha;"><li>Then choose to download the Home version</spanli>== Top view and bottom view of Orange Pi Zero 3 ==
[[File:zero3-img71.png]]<span id/ol><ol start="interface3" style="list-detailsstyle-oftype: decimal;"><li><p>After opening the software, the steps to set up the serial port connection are as follows</p><ol style="list-orangestyle-pi-zerotype: lower-3alpha;"><li><p>Open the session settings interface</p></li><li><p>Select the serial port type</p></spanli>== Interface details <li><p>Select the port number of Orange Pi Zero 3 == [the serial port (select the corresponding port number according to the actual situation), if you cannot see the port number, please use [Filehttp:media/image5/weishi.png|485x787px]360.cn/qudongdashi/ '''360 Driver Master''']to scan and install the driver for the USB-to-TTL serial port chip</p></li><li><p>Select the baud rate of the serial port as '''115200'''</p></li><li><p>Finally click the "'''OK'''" button to complete the setup</p></li>
<span id/div></ol></li></ol><ol start="4" style="introduction-to-the-use-of-thelist-developmentstyle-boardtype: decimal;"></spanli>= After clicking the "'''OK'''Introduction to " button, you will enter the use of following interface. At this time, start the development board''' =and you can see the output information of the serial port</li>
<span iddiv class="prepare-the-required-accessoriesfigure"></span>== Prepare the required accessories ==
<ol start="52" style="list-style-type: decimal;"><li><p>If there is no 13pin expansion board, you can use a 4pin 2.54mm DuPont to USB2.0 female cable to expand the USB interface. The specific method is as follows:</p>
<ol style="list-style-type: lower-alpha;">
<li>The physical object of First, you need to prepare a 4pin 2.54mm Dupont to USB2.0 female cable (this cable can be bought on Amazon, please search and buy by yourself), as shown in the expansion board is as followsfigure below:</li></ol></li></ol>
[[File:media/image17zero3-img75-1.png]] [[File:zero3-img76.png|252x154px]]</ol><ol start="2" style="list-style-type: lower-alpha;"><li>The schematic diagram of the 13pin interface is shown below</li>
[[File:zero3-img19.png]] [[File:zero3-img77.png]]</ol><ol start="23" style="list-style-type: lower-alpha;"><li>The way to insert the expansion board into the development board wiring of USB2 is as follows, remember not to insert it backwards</li></ol>
[[File:media/image18zero3-img78.png|246x162px]]</ol><ol start="4" style="list-style-type: lower-alpha;"><li>The wiring of USB3 is as follows</li>
[[File:zero3-img79.png]]</ol><ol start="35" style="list-style-type: lower-alpha;"><li>The If you need to connect two USB devices to the 13pin pin header on interface at the Orange Pi Zero 3 development board can be connected to same time, you will find that the expansion board to expand 5V and GND pins on the functions that 13pin interface are not on the development boardenough. The functions that At this time, one of the expansion board USB devices can use are the 5V and GND pins in the 26pin interface. The location is as followsshown in the figure below Shown:</li></ol>
[[File:zero3-img24-1.png]]</ol></li></ol><span id="instructions-for-use-of-debianubuntu-server-and-xfce-desktop-system"></span> = '''Instructions for use of Debian/Ubuntu Server and Xfce desktop system''' = <span id="supported-linux-image-types-and-kernel-versions"></span>== Supported linux image types and kernel versions == {| class="wikitable"style="width:800px;"|-|style="text-align: center;"| '''Linux image type'''| style="text-align: leftcenter;"| 1'''kernel version'''| style="text-align: center;"| '''server version'''| style="text-align: center;"| '''desktop version'''|-| style="text-align: leftcenter;"| Microphone (Mic)'''Ubuntu 20.04 - Focal'''| style="text-align: leftcenter;"| '''No support, no support, no support! ! !<br />Linux5.4'''<br />| style="text-align: center;"| '''Support'''| style="text-align: center;"| '''Support'''The 13pin expansion board is a general|-| style="text-purpose expansion board, which is suitable for various development boards of Orange Pi, but the 13pin interface of Orange Pi Zero3 has no Mic function, so although there is a Mic on the 13pin expansion board, it is on the Orange Pi Zero 3align: center;"| '''Ubuntu 22. Unusable, the 13pin expansion board is mainly used to expand functions other than Mic on Orange Pi Zero 304 - Focal'''| style="text-align: center;"| '''Linux5.4'''| style="text-align: center;"| '''Support'''| style="text-align: center;"| '''Support'''
|-
| style="text-align: leftcenter;"| 2'''Debian 11 - Bullseye'''| style="text-align: leftcenter;"| Analog audio and video output interface'''Linux5.4'''| style="text-align: leftcenter;"| Supported, it can be used to connect headphones to play music, or connect to TV through AV cable to output analog audio and video signals '''(Android system only).Support'''| style="text-align: center;"| '''Support'''
|-
| style="text-align: leftcenter;"| 3'''Ubuntu 22.04 - Jammy'''| style="text-align: leftcenter;"| USB 2'''Linux6.0 Host x 21'''| style="text-align: center;"| '''Support'''| style="text-align: leftcenter;"| '''Support, used to connect USB keyboard, mouse and USB storage device.'''
|-
| style="text-align: leftcenter;"| 4'''Debian 11 - Bullseye'''| style="text-align: center;"| '''Linux6.1'''| style="text-align: leftcenter;"| Infrared receiving function'''Support'''| style="text-align: leftcenter;"| '''Support, Android system can be controlled by infrared remote control'''|-| style="text-align: center;"| '''Debian 12 - Bookworm'''| style="text-align: center;"| '''Linux6.1'''| style="text-align: center;"| '''Support'''| style="text-align: center;"| '''Support'''
|}
[[File:media/image19zero3-img80.png|264x142px]]
<ol style="list-style-type: lower-alpha;"><li><p>'''Note The model of the development board''':Both are '''orangepizero3'''. The model names of different development boards are generally different. Before burning the image, please make sure that the remote control model name of the selected image matches the development board.</p></li><li><p>'''Version number''':For example, '''1.x.x''', this version number will increase with the update of the air conditioner or image function, and the last number of the remote control version number of the TV cannot control Linux image on the Orange Pi development boardis an even number.</p></li><li><p>'''Types of Linux distributions''': '''Ubuntu''' and '''Debian''' are currently supported. By Since Ubuntu is derived from Debian, there is not much difference between the two systems in terms of usage. However, there are still some differences in the defaultconfiguration of some software and the use of commands. In addition, only both Ubuntu and Debian have their own software warehouses supported by maintenance, and there are also some differences in the remote supported and installable software packages. These need to be experienced in person to have a deeper understanding. For more details, you can refer to the official documentation provided by Ubuntu and Debian.</p></li><li><p>'''Release code name''': Used to distinguish between different versions of a specific Linux distribution such as Ubuntu or Debian. Among them, both '''focal''' and '''jammy''' are Ubuntu distributions, focal means Ubuntu20.04, and jammy means Ubuntu22.04. The biggest difference between different versions is that the software in the software warehouse maintained by the new version of Ubuntu system is much better than that of the old version of Ubuntu system. The ones in it should be new, such as Python and GCC compilation tool chains. '''bullseye''' is the specific version code of Debian, bullseye means Debian11, and bookworm means Debian12.</p></li><li><p>'''Server or Desktop''':It is used to indicate whether the system has a desktop environment. If it is server, it means that the system does not have a desktop environment. The storage space and resources occupied by the image are relatively small, and the command line is mainly used to operate and control provided the system. If it is '''desktop_xfce''', it means that the system is installed with the XFCE desktop environment by default. The storage space and resources occupied by Orange Pi the image are relatively large. You can connect the monitor, mouse and keyboard to operate the system through the interface. Of course, the desktop version of the system canalso be operated through the command line like the server version of the system.</p></li><li><p>'''Kernel version''':Used to indicate the version number of the linux kernel, currently supports '''linux5.4''' and '''linux6.1.'''</p></li></ol>
<ol startspan id="8" style="listlinux-kernel-styledriver-type: decimal;adaptation"><li><p>100M or 1000M network cable, used to connect the development board to the Internet</p></li><li><p>AV video cable, if you want to display video through the AV interface instead of the HDMI interface, then you need to connect the development board to the TV through the AV video cable</p></li></olspan>
|-
| style="text-align: leftcenter;"| 1'''USB2.0 x 3'''| style="text-align: leftcenter;"| Ubuntu22.04 PC'''OK'''| style="text-align: leftcenter;"| Optional, used to compile Android and Linux source code'''OK'''
|-
| style="text-align: leftcenter;"| 2'''micro SD card start'''| style="text-align: leftcenter;"| Windows PC'''OK'''| style="text-align: leftcenter;"| For burning Android and Linux images'''OK'''|}-| style="text-align: center;"| '''Gigabit Ethernet'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''Infrared receiver'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''WIFI'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''Bluetooth'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''headphone audio'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''usb camera'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''LED light'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''26pin GPIO'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''26pin I2C'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''26pin SPI1'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''26pin UART'''| style="text-align: center;"| '''OK'''| style="text-align: center;"| '''OK'''|-| style="text-align: center;"| '''PWM'''| style="text-align: center;"| '''OK'''<span id| style="downloadtext-thealign: center;"| '''OK'''|-image| style="text-ofalign: center;"| '''Temperature Sensor'''| style="text-thealign: center;"| '''OK'''| style="text-developmentalign: center;"| '''OK'''|-board| style="text-andalign: center;"| '''hardware watchdog'''| style="text-relatedalign: center;"| '''OK'''| style="text-materialsalign: center;"| '''OK'''|-| style="text-align: center;"| '''Mali GPU'''| style="text-align: center;"| '''<span style="color:#FF0000">NO</span>'''| style="text-align: center;"| '''<span style="color:#FF0000">NO</span>'''|-| style= Download the image of the development board and related materials "text-align: center;"| '''Video codec'''| style="text-align: center;"| '''<span style="color:#FF0000">NO</span>'''| style="text-align: center;"| '''<span style="color:#FF0000">NO</span>'''|-| style="text-align: center;"| '''TV-OUT'''| style="text-align: center;"| '''<span style="color:#FF0000">NO</span>'''| style="text-align: center;"| '''<span style="color:# The website for downloading the English version isFF0000">NO</span>'''|}
|}<ol start="52" style="list-style-type: decimal;"><li>After entering <p>Description of the prompt type in front of the balenaEtcher download page, click command</p><ol style="list-style-type: lower-alpha;"><li>The prompt in front of the green download button to jump command refers to the place where content of the red part in the software box below, which is downloadednot part of the linux command, so when entering the command in the linux system, please do not enter the content of the red font part.</li></ol>
'''<ol start="6" span style="list-style-typecolor: decimal;#FF0000">root@orangepi:~#<li/span>Then you can choose to download the Portable version of balenaEtcher software. The Portable version does not need to be installed, and you can use it by double-clicking to open it<''' '''vim /li><boot/ol>boot.cmd'''
'''<span style="color:#FF0000">test@test:~$</span> ssh [[Filemailto:media/image28root@192.168.1.36 root@192.168.1.png|468x173px]]xxx'''
'''<span style="color:#FF0000">root@test:~#</span> ls'''|}</ol><ol start="72" style="list-style-type: decimallower-alpha;"><li>If <p>'''<span style="color:#FF0000">root@orangepi:~$</span>''' The prompt indicates that this command is entered in the downloaded version '''linux system of balenaEtcher needs the development board'''. The '''<span style="color:#FF0000">$</span>''' at the end of the prompt indicates that the current user of the system is a normal user. When executing a privileged command, you need to be installedadd '''sudo'''</p></li><li><p>'''<span style="color:#FF0000">root@orangepi:~#</span>''' The prompt indicates that this command is entered in the linux system of the development board, and the '''<span style="color:#FF0000">#</span>''' at the end of the prompt indicates that the current user of the system is the root user, who can execute any desired command</p></li><li><p>'''<span style="color:#FF0000">test@test:~$</span>''' The prompt indicates that this command is entered in the Ubuntu PC or Ubuntu virtual machine, please install it before using itnot in the linux system of the development board. If you downloaded The '''<span style="color:#FF0000">$</span>''' at the end of the prompt indicates that the Portable version current user of balenaEtcherthe system is an ordinary user. When executing privileged commands, just double-click '''sudo''' needs to open itbe added</p></li><li><p>'''<span style="color:#FF0000">root@test:~#</span>''' The prompt indicates that this command is entered in the Ubuntu PC or Ubuntu virtual machine, not in the linux system of the development board. The opened balenaEtcher interface '''<span style="color:#FF0000">#</span>''' at the end of the prompt indicates that the current user of the system is shown in the figure belowroot user and can execute any command you want</p></li></ol></li></ol><!-- --><ol start="3" style="list-style-type: decimal;"><li><p>What are the commands that need to be entered?</p><olstyle="list-style-type: lower-alpha;"><li>As shown below, '''the black bold part''' is the command that needs to be input, and the content below the command is the output content (some commands have output, some may not), and this part of the content does not need to be input</li>{| class="wikitable" style="width:800px;" |-[[File| root@orangepi:media~# '''cat /image29boot/orangepiEnv.png|335x211px]]txt'''
'''When opening balenaEtcher, if the following error is prompted<span style="color:#FF0000">verbosity=7</span>'''
'''Please select balenaEtcher, right<span style="color:#FF0000">console=serial</span>'''|}</ol><ol start="2" style="list-style-type: lower-clickalpha;"><li>As shown below, some commands cannot be written in one line and select Run will be placed on the next line. As long as administratorthe black and bold parts are all commands that need to be input.When these commands are entered into one line, the last "\" of each line needs to be removed, this is not part of the command. In addition, there are spaces in different parts of the command, please don't miss it</li>{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''echo \'''
'''"deb [[File:media/image31.png|114x37px]]arch=$(dpkg --print-architecture) \'''
'''$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null'''|}</ol start="10" style="list-style-type: decimal;"></li>After burning the Linux image, balenaEtcher will also verify the image burned to the TF card by default to ensure that there is no problem in the burning process. As shown in the figure below, a green progress bar indicates that the image has been burnt, and balenaEtcher is verifying the burnt image.</liol><span id="linux-system-login-instructions"></olspan>
<ol startspan id="11" style="listlinux-system-default-login-account-styleand-type: decimal;password"><li/span>After successful burning, the display interface of balenaEtcher is as shown in the figure below. If the green indicator icon is displayed, it means that the image burning is successful. At this time, you can exit balenaEtcher, === Linux system default login account and then pull out the TF card and insert it into the TF card slot of the development board. .</li></ol>password ===
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| </divbig>'''When the wrong password is prompted, or there is a problem with the ssh connection, please note that as long as you are using the Linux image provided by Orange Pi, <span idstyle="how-to-use-win32diskimager-to-burn-linux-imagecolor:#FF0000">please do not suspect that the above password is wrong, but look for other reasons</span>.'''</big>=== How to use Win32Diskimager to burn Linux image ===|}
<ol stylespan id="listhow-styleto-set-automatic-type: decimal;"><li><p>First prepare a TF card with a capacity of 8GB or more. The transmission speed of the TF card must be '''class 10 or above'''. It is recommended to use a TF card of SanDisk and other brands</p></li><li><p>Then use the card reader to insert the TF card into the computer</p></li><li><p>Then format the TF card</p><ol style="listterminal-login-stylein-type: lowerlinux-alpha;system"><li>'''SD Card Formatter'''can be used to format the TF card. The download link is</li></ol></li></olspan>
# The Linux system automatically logs in to the terminal by default, and the default login user name is '''<ol start="2" span style="list-style-typecolor: lower-alpha;#FF0000"><li><p>After downloading, unzip and install directly, and then open the software</p>orangepi</lispan><li><p>If only a TF card is inserted into the computer, the drive letter of the TF card will be displayed in the " '''Select card''' " column. If multiple USB storage devices are inserted into the computer, you can select the corresponding drive letter of the TF card through the drop-down box</p></li></ol>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''sudo auto_login_cli.sh root'''|}</divol><ol start="43" style="list-style-type: lower-alphadecimal;"><li>hen click " '''Format''' ", a warning box will pop up before formatting, and formatting will start after selecting "Yes (Y)"Use the following command to disable automatic login terminal</li></ol>
<div class="figure">
::[[File:media/image39zero3-img82.png|297x206px|C:\Users\orangepi\Desktop\用户手册插图\Pi5 Plus\a8fda8737c5b0b3b38fbb75ef68acfc.pnga8fda8737c5b0b3b38fbb75ef68acfc]]
</div>
<ol start="32" style="list-style-type: lower-alphadecimal;"><li>After the image writing is completed, click Run the "'''Exit'''" button following command to exit, and then you can pull out prohibit the TF card and insert it desktop system from automatically logging into the development board to startdesktop</li></ol>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''sudo disable_desktop_autologin.sh'''|}</ol><span idol start="method-of-burning-linux-image-to-tf3" style="list-cardstyle-based-on-ubuntu-pctype: decimal;"></spanli>== Method of burning Then restart the system and a login dialog box will appear, at which point a [[Orange Pi Zero 3#Linux system default login account and password|'''Linux image system default login account and password''']] is required to TF card based on Ubuntu PC ==enter the system</li>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''orangepizero3_1sudo desktop_login.0.0_ubuntu_focal_desktop_linux6.1.31.imgsh orangepi''' # mirror file|}</ol><span id="the-method-of-disabling-the-desktop-in-the-linux-desktop-version-system"></span>
<ol start="82" style="list-style-type: decimal;"><li>Then double-click '''balenaEtcher-1.14.3-x64.AppImage''' on restart the graphical interface of Ubuntu PC to open balenaEtcher (no installation required), Linux system and you will find that the interface after balenaEtcher is opened is desktop will not be displayed as shown in the figure below</li></ol>
orangepi@orangepi:~$ '''sudo systemctl enable lightdm.service'''|}<div class/ol><span id="figureonboard-led-light-test-instructions"></span>
{| class="wikitable" style="width:800px;" |-| root@orangepi:~# '''In addition, the PhoenixCard software does not have versions for Linux and Mac platforms, so it is impossible to burn Android images to TF cards under Linux and Mac platforms.cd /sys/class/leds/green_led'''|}</ol><ol start="2" style="list-style-type: lower-alpha;"><li>The command to set the green light to stop flashing is as follows</li>
{| class="wikitable" style="width:800px;" |-| root@orangepi:/sys/class/leds/green_led# First, please make sure that the Windows system has installed '''Microsoft Visual C++ 2008 Redistrbutable - x86echo none > trigger'''[[File:media|}</image45.png|449x293px]]ol># If not installed '''Microsoft Visual C++ 2008 Redistrbutable <ol start="3" style="list-style-type: lower- x86''', Using PhoenixCard alpha;"><li>The command to format TF card or burn Android image will prompt set the following errorgreen light to be on is as follows</li>
{| class="wikitable" style="width:800px;" |-| root@orangepi:/sys/class/leds/green_led# '''echo default-on > trigger'''|}<div class/ol><ol start="4" style="figurelist-style-type: lower-alpha;"><li>The command to set the green light to flash is as follows</li>
<ol start="3" style="list-style-type: decimal;">
<li>'''Microsoft Visual C++ 2008 Redistrbutable - x86''' the installation package can be downloaded from the '''official tool''' The method of Orange Pi Zero 3, or you can go to setting the '''official website of Microsoft''' to downloadred light on/off and flashing is as follows:</li></ol>
<ol start="4" style="list-style-type: decimallower-alpha;"><li><p>Then prepare a TF card with 8GB or larger capacity. The transmission speed of the TF card must be '''class 10 or above'''. It is recommended to use a TF card of SanDisk and other brands</p></li><li><p>Then use the card reader to insert the TF card into the computer</p></li><li><p>Download First enter the Android image and PhoenixCard programming tool from the '''Orange Pi data download page'''. '''Please ensure that the version setting directory of the PhonenixCrad tool is PhonixCard-4.2.8.''' Please do not use the PhonixCard software version lower than 4.2.8 to burn the Android image. There may be problems with the Android image flashed by this version of the PhonixCard tool</p>red light</li></ol>
{| class="wikitable" style="width:800px;" |-| root@orangepi:/sys/class/leds/red_led# '''echo default-on > trigger'''|}</ol><ol start="73" style="list-style-type: decimallower-alpha;"><li>Then use the decompression software The command to decompress the compressed package of the downloaded Android image. Among the decompressed files, the file ending with ".img" is the Android image file, and set the size flashing red light is more than 1GB. If you don't know how to decompress the compressed package of the Android image, you can install a '''compression software''' to decompress the image.as follows</li></ol>
{| class="wikitable" style="width:800px;" |-| root@orangepi:/sys/class/leds/red_led# '''echo none > trigger'''|}</ol></ol><ol start="84" style="list-style-type: decimal;"><li>Then <p>If you do not need the LED light to flash after booting, you can use decompression software the following method to decompress turn off the green light flashing</p><ol style="list-style-type: lower-alpha;"><li>First run '''PhonixCard4.2.8.ziporangepi-config''', this software does not need common users remember to be installed, just find PhoenixCard in the decompressed folder and open itadd '''sudo''' permission</li></ol>
[[File:zero3-img85.png]]</ol><ol start="93" style="list-style-type: decimallower-alpha;"><li>After opening PhoenixCard, if the TF card is recognized normally, the drive letter and capacity of the TF card will be displayed in the middle list. Then select '''Please make sure that the displayed drive letter is consistent with the drive letter of the TF card you want to burnHardware'''. If there is no display, you can try to unplug the TF card, or click the "'''Refresh Drive Letter'''" button in PhoenixCard</li></ol>
[[File:media/image52zero3-img86.png|575x137px]]</ol><ol start="4" style="list-style-type: lower-alpha;"><li>Then use the arrow keys on the keyboard to navigate to the position shown in the figure below, and then use the space to select '''disable-leds'''</li>
[[File:zero3-img87.png]]</ol><ol start="105" style="list-style-type: decimallower-alpha;"><li>After confirming the drive letter, format the TF card first, and click the "'''Recover CardThen selec '''"lt; button in PhoenixCard (if the Save"gt;'''Recover Card'''" button is gray and cannot be pressed, you can first click the "'''Refresh Drive Letter'''" button)</li></ol>
[[File:zero3-img88.png]]<div class/ol><ol start="6" style="figurelist-style-type: lower-alpha;"><li>Then select '''<Back>'''</li>
[[File:media/image53.jpeg|575x316px|C:\Users\orangepi\Desktop\用户手册插图\Zero3\未标题zero3-1img89.jpg未标题-1png]]</ol><ol start="7" style="list-style-type: lower-alpha;"><li>Then select '''<Reboot>''' to restart the system for the configuration to take effect</li>
[[File:zero3-img90.png]]</divol>'''If there is a problem with formatting, please try to unplug and insert the TF card and then test again. If the problem still exists after re-plugging and inserting the TF card, you can restart the Windows computer or try another computer.''' <ol start="118" style="list-style-type: decimal;"><li><p>Then start to write the Android image into the TF card</p><ol style="list-style-type: lower-alpha;"><li><p>First select After restarting and fully entering the path of system, you can see that the Android image in the "'''Firmware'''" column</p></li><li><p>Select "'''Activation Card'''" in "Card Type"</p></li><li><p>Then click two LED lights on the "'''burn card'''" button to start burning</p>development board will not light up</li></ol>
</li></ol>
<span id="instructions-for-operating-the-rootfs-partition-capacity-of-the-linux-system-in-the-tf-card"></span>
<ol startspan id="12" style="listthe-first-startup-will-automatically-expand-the-capacity-of-the-rootfs-partition-in-the-styletf-type: decimal;card"><li/span>After burning, === The first startup will automatically expand the display capacity of PhoenixCard is as shown the rootfs partition in the figure below. At this time, click the "'''Close'''" button to exit PhoenixCard, and then you can pull out the TF micro SD card from the computer and insert it into the development board to start</li></ol>===
<div classol start="figure1"style="list-style-type: decimal;"><li>After burning the Linux image of the development board into the micro SD card, you can check the capacity usage of the micro SD card on the '''<span style="color:#FF0000">Ubuntu computer</span>''', the steps are as follows:
</divol style="list-style-type: lower-alpha;">'''After burning <li>First install the Android system, gparted software on the TF card can only see a 128 MB partition in Windows, and the displayed partition is as shown in the figure below (some computers may pop up more than 20 disk partitions, but only the 128 MB partition can be opened. partition), please note that this is normal, please do not think that the TF card is burned out. The reason for this is that the Android system has a total of more than 20 partitions, but most of them cannot be recognized normally in the Windows system. At this point, please safely unplug the TF card and insert it into the development board to start it.'''Ubuntu computer</li>
<span idol start="3" style="startlist-thestyle-orange-pi-development-boardtype: decimal;"><li>Then switch the current user to the root user on the Ubuntu computer</spanli>== Start the Orange Pi development board ==
root@test:~'''Many unstable phenomena during the power<span style="color:#FF0000">#</span>'''|}</ol><ol start="4" style="list-on and startstyle-up process type: decimal;"><li>Then enter the root directory of the linux system are basically caused by power supply problems, so a reliable power adapter is very important. If you find that there is a phenomenon of continuous restart during the startup process, please replace in the power supply or Type C data cable micro SD card and try againcreate a new file named '''.no_rootfs_resize'''</li>
root@test:/media/test/opi_root/root# First, you need to prepare a 3'''ls .3v USB to TTL module, and then insert the USB interface end of the USB to TTL module into the USB interface of the computerno_rootfs*'''
'''.no_rootfs_resize'''|}<div class/ol><ol start="5" style="figurelist-style-type: decimal;"><li><p>Then you can uninstall the micro SD card, and then pull out the micro SD card and insert it into the development board to start. When the linux system starts, when the file'''.no_rootfs_resize''' is detected in the '''/root''' directory, the rootfs will not be automatically expanded.</p></li><li><p>After entering the Linux system after prohibiting automatic expansion of rootfs, you can see that the total capacity of the rootfs partition is only 4GB (the image of the desktop version is tested here), which is much smaller than the actual capacity of the micro SD card, indicating that the automatic expansion of rootfs is prohibited.</p></li>
{| class="wikitable" style="width:800px;"|-|<p>root@orangepi:~$ '''df -h'''</p><span style="margin-right: 80px;">Filesystem </span><span style="margin-right: 50px;">Size </span id><span style="howmargin-toright: 30px;">Used </span><span style="margin-useright: 30px;">Avail</span><span style="margin-theright: 50px;">Use% Mounted on</span><br><span style="margin-debuggingright: 110px;">udev</span><span style="margin-serialright: 60px;">925M </span><span style="margin-portright: 50px;">0</span><span style="margin-onright: 70px;">925M </span><span style="margin-right: 90px;">0% /dev</span><br><span style="margin-right: 100px;">tmpfs </span><span style="margin-theright: 50px;">199M </span><span style="margin-ubunturight: 30px;">3.2M </span><span style="margin-platformright: 70px;">196M </span><span style="margin-right: 90px;">2% /run</span><br><span style="margin-right: 25px;color:#FF0000">'''/dev/mmcblk0p1'''</span><span style="margin-right: 50px;color:#FF0000">'''15G'''</span><span style= How to use the debugging serial port on the Ubuntu platform "margin-right: 35px;color:#FF0000">'''3.2G '''</span><span style="margin-right: 80px;color:#FF0000">'''12G '''</span><span style="margin-right: 90px;color:#FF0000">'''23% /'''</span><br>|}</ol><span id="the-method-of-manually-expanding-the-capacity-of-the-rootfs-partition-in-the-tf-card"></span>
{| class="wikitable" style="background-color:# Firstffffdc;width:800px;" |-| <big>'''If the total capacity of the micro SD card is large, insert such as 128GB, you do not want the rootfs partition of the USB-Linux system to-TTL module into use all the USB port capacity of the Ubuntu computer. If micro SD card, but only want to allocate a part of the capacity, such as 16GB, to the connection Linux system, and identification then the remaining capacity of the USB-to-TTL module is normal, micro SD card can be used for other use. Then you can see use the corresponding device node name under content introduced in this section to manually expand the capacity of the rootfs partition in TF.'''</dev''' on the Ubuntu PC. Remember this node name, and then set the serial port software will be usedbig>|}
::{| class="wikitable" style="width:800px;" |-| <p>test@test:~$ '''ls /devmedia/test/opi_root/ttyUSB0'''</p><p>bin boot dev etc home lib lost+found media mnt opt proc root run <br> sbin selinux srv sys tmp usr var</p>|}
<ol start="23" style="list-style-type: decimal;"><li>Then use switch the following command current user to install putty the root user on the Ubuntu PCcomputer</li></ol>
{| class="wikitable" style="width:800px;" |-| test@test:~$ '''sudo apt update-i'''
root@test:~'''<span style="color:#FF0000">#</span>'''|}</ol><ol start="34" style="list-style-type: decimal;"><li>Then run putty, enter the root directory of the linux system in the micro SD card and create a new file named '''remember to add sudo permission.no_rootfs_resize'''</li></ol>
root@test:/media/test/opi_root/root# '''ls .no_rootfs*'''
'''.no_rootfs_resize'''
|}
</ol>
<ol start="5" style="list-style-type: decimal;">
<li>First select Then install the setting interface of gparted software on the serial portUbuntu computer</li></ol>
{| class="wikitable" style="width:800px;" |-| test@test:~$ '''sudo apt install -y gparted'''|}</ol><div classol start="6" style="figurelist-style-type: decimal;"><li>Then open gparted</li>
[[File:zero3-img91.png]]</divol><ol start="68" style="list-style-type: decimal;"><li><p>Then set select the parameters of the serial port</p><ol style="list-style-type: lower-alpha;"><li><p>Set '''Serial line to connect to'''to as '''dev/ttyUSB0''' rootfs partition (modify to the corresponding node name, usually /dev/ttyUSB0sdc1)</p></li><li><p>Set '''Speed(baud)''' to 115200 (the baud rate of the serial port)</p></li><li><p>Set '''Flow control''' as '''None'''</p></li></ol></li></ol>
[[File:zero3-img93.png]]<div class/ol><ol start="9" style="list-style-type: decimal;"><li>Click the right mouse button again to see the operation options shown in the figure"below. If the micro SD card has been mounted, first you need to Umount the rootfs partition of the micro SD card</li>
[[File:media/image65zero3-img94.jpeg|398x352px|10png]]</ol><ol start="10" style="list-style-type: decimal;"><li>Then select the rootfs partition again, click the right mouse button, and select '''Resize/Move''' to start expanding the size of the rootfs partition</li>
[[File:zero3-img95.png]]</divol><ol start="711" style="list-style-type: decimal;"><li><p>After setting the setting interface of the serial port, return to the Session interface</p><ol style="list-style-type: lower-alpha;"><li><p>First select the '''Connection type''' as Serial<Resize/p></li><li><p>Then click the Move'''Open''' button to connect to option is turned on, the serial port</p>following setting interface will pop up</li></ol></li></ol>
[[File:zero3-img96.png]]<div class/ol><ol start="12" style="list-style-type: decimal;"><li>Then you can directly drag the location shown in the figure"below to set the size of the capacity, or you can set the size of the rootfs partition by setting the number in '''New size(MiB)'''</li>
[[File:media/image66zero3-img97.jpeg|375x333px|11png]]</ol><ol start="13" style="list-style-type: decimal;"><li>After setting the capacity, click '''Resize/Move''' in the lower right corner</li>
[[File:zero3-img98.png]]</divol><ol start="814" style="list-style-type: decimal;"><li>After confirming that it is correct, click the green button shown in the figure below '''<span style="color:green">√</span>'''</li> [[File:zero3-img99.png]]</ol><ol start="15" style="list-style-type: decimal;"><li>Then select '''Apply''', it will officially start to expand the development board, and you can see the Log information output by capacity of the system from the opened serial port terminalrootfs partition</li> [[File:zero3-img100.png]]</ol><ol start="16" style="list-style-type: decimal;"><li>After the expansion is completed, click '''Close''' to close</li>
[[File:media/image67zero3-img101.png|376x249px]]</ol><ol start="17" style="list-style-type: decimal;"><li>Then you can pull out the micro SD card, insert it into the development board and start it up. After entering the Linux system of the development board, if you can see that the size of the rootfs partition is the same as the size set before, it means manual Expansion succeeded</li>
{| class="wikitable" style="width:800px;"|-|<p>root@orangepi:~# '''df -h'''</p><span style="margin-right: 80px;">Filesystem </span><span style="margin-right: 50px;">Size </span><span style="margin-right: 30px;">Used </span><span style="margin-right: 30px;">Avail</span id><span style="margin-right: 50px;">Use% Mounted on</span><br><span style="howmargin-toright: 110px;">udev</span><span style="margin-useright: 60px;">925M </span><span style="margin-theright: 50px;">0</span><span style="margin-right: 70px;">925M </span><span style="margin-debuggingright: 90px;">0% /dev</span><br><span style="margin-serialright: 100px;">tmpfs </span><span style="margin-portright: 50px;">199M </span><span style="margin-onright: 30px;">3.2M </span><span style="margin-windowsright: 70px;">196M </span><span style="margin-platformright: 90px;">2% /run</span><br><span style="margin-right: 25px;color:#FF0000">'''/dev/mmcblk0p1'''</span><span style="margin-right: 50px;color:#FF0000">'''7.7G '''</span><span style= How to use the debugging serial port on Windows platform "margin-right: 35px;color:#FF0000">'''3.2G '''</span><span style="margin-right: 80px;color:#FF0000">'''4.4G '''</span><span style="margin-right: 90px;color:#FF0000">'''42% /'''</span><br>|}</ol><span id="how-to-reduce-the-capacity-of-the-rootfs-partition-in-the-tf-card"></span>
{| class="wikitable" style="width:800px;" |-| test@test:~$ '''sudo gparted'''|}</ol><ol start="34" style="list-style-type: lower-alphadecimal;"><li>Then choose to download After opening gparted, you can select the micro SD card in the upper right corner, and then you can see the usage of the Home versionmicro SD card capacity</li></ol>
[[File:media/image69zero3-img102.png|353x231px]]</ol><ol start="5" style="list-style-type: decimal;"><li>Then select the rootfs partition (/dev/sdc1)</li>
[[File:zero3-img103.png]]</ol><ol start="46" style="list-style-type: lower-alphadecimal;"><li>Then select Click the Portable versionright mouse button again to see the operation options shown in the figure below. After downloadingIf the micro SD card has been mounted, first you don’t need to install it, just open it and use itUmount the rootfs partition of the micro SD card</li></ol>
[[File:zero3-img104.png]]<div class/ol><ol start="7" style="figurelist-style-type: decimal;"><li>Then select the rootfs partition again, click the right mouse button, and select '''Resize/Move''' to start setting the size of the rootfs partition</li>
[[File:media/image70zero3-img105.png|322x175px|选区_232]]</ol><ol start="8" style="list-style-type: decimal;"><li>After the '''Resize/Move''' option is turned on, the following setting interface will pop up</li>
[[File:zero3-img106.png]]</divol><ol start="29" style="list-style-type: decimal;"><li>After downloading, use decompression software Then you can directly drag the location shown in the figure below to decompress set the size of the downloaded compressed packagecapacity, or you can get set the executable software size of MobaXterm, and then double-click to openthe rootfs partition by setting the number in '''New size(MiB)'''</li></ol>
[[File:media/image71zero3-img97.png|576x83px]]</ol><ol start="10" style="list-style-type: decimal;"><li>After setting the capacity, click '''Resize/Move''' in the lower right corner</li>
[[File:zero3-img98.png]]</ol><ol start="311" style="list-style-type: decimal;"><li><p>After opening the softwareconfirming that it is correct, click the steps to set up green button shown in the serial port connection are as follows</p>figure below '''<ol span style="list-style-typecolor: lower-alpha;green"><li><p>Open the session settings interface</p></li><li><p>Select the serial port type</p></li><li><p>Select the port number of the serial port (select the corresponding port number according to the actual situation), if you cannot see the port number, please use 360 '''Driver Master''' to scan and install the driver for the USB-to-TTL serial port chip</p></li><li><p>Select the baud rate of the serial port as '''115200'''</p>√</lispan><li><p>Finally click the "'''OK'''" button to complete the setup</p></li></ol></li></ol>
[[File:zero3-img99.png]]<div class/ol><ol start="12" style="figurelist-style-type: decimal;"><li>Then select '''Apply''', and the expansion of the rootfs partition will officially start</li>
[[File:media/image72zero3-img100.jpeg|553x280px|12png]]</ol><ol start="13" style="list-style-type: decimal;"><li>After the expansion is completed, click '''Close''' to close</li>
[[File:zero3-img101.png]]</divol><ol start="414" style="list-style-type: decimal;"><li>After clicking Then you can pull out the "'''OK'''" buttonmicro SD card, you will enter insert it into the following interfacedevelopment board and start it up. At this time, start After entering the Linux system of the development board and , if you can use the '''df -h''' command to see that the output information size of the serial portrootfs partition is the same as the size set before, it means that the size has been reduced. capacity success</li></ol>
{| class="wikitable" style="width:800px;"|-|<p>root@orangepi:~# '''df -h'''</p><span style="margin-right: 80px;">Filesystem </span><span style="margin-right: 50px;">Size </span><span style="margin-right: 30px;">Used </span><span style="margin-right: 30px;">Avail</span><span style="margin-right: 50px;">Use% Mounted on</span><br><span style="margin-right: 110px;">udev</span><span style="margin-right: 60px;">925M </span><span style="margin-right: 50px;">0</span><span style="margin-right: 70px;">925M </span><span style="margin-right: 90px;">0% /dev</span><br><span style="margin-right: 100px;">tmpfs </span><span style="margin-right: 50px;">199M </span><span style="margin-right: 30px;">3.2M </span><span style="margin-right: 70px;">196M </span><span style="margin-right: 90px;">2% /run</span><br><span style="margin-right: 25px;color:#FF0000">'''/dev/mmcblk0p1'''</span><div classspan style="margin-right: 50px;color:#FF0000">'''7.7G '''</span><span style="margin-right: 35px;color:#FF0000">'''3.2G '''</span><span style="margin-right: 80px;color:#FF0000">'''4.4G '''</span><span style="margin-right: 90px;color:#FF0000">'''42% /'''</span><br>|}</ol><span id="figurenetwork-connection-test"></span>
:inet '''<span style="color:#FF0000">192.168.1.16</divspan>'''The power cord shown in the picture above can be bought on Amazon, please search and buy by yourself/24 brd 192.168.'''1.255 scope global dynamic noprefixroute eth0
<ol start="3" style="list-style-type: lowerupper-alpha;"><li>The wiring <p>'''First check whether the Linux system has started normally. If the green light of USB2 the development board is flashing, it is generally started normally. If only the red light is on, or the red and green lights are not on, it means that the system has not started normally;'''</p></li><li><p>'''Check whether the network cable is plugged in tightly, or try another network cable;'''</p></li><li><p>'''Try another router (I have encountered many problems with the router, such as followsthe router cannot assign the IP address normally, or the IP address has been assigned normally but cannot be seen in the router);'''</p></li><li><p>'''If there is no router to replace, you can only connect to an HDMI display or use the debugging serial port to check the IP address.'''</p></li></ol>
'''In addition, it should be noted that the development board DHCP automatically assigns an IP address without any settings.'''</big>|}</li></ol><ol start="4" style="list-style-type: lower-alphadecimal;"><li><p>The wiring of USB3 command to test the network connectivity is as follows, the ping command can be interrupted through the shortcut key of '''Ctrl+C'''</lip>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Please do not copy the following commands. For example, the network node name in debian12 is end0, and the following command needs to be changed to ping www.baidu.com -I end0, I is capital i,.'''</p></olbig>|}
{| class="wikitable"|-| style="text-align: left;"| '''Function'''| style="text-align: left;"| '''Linux5.4'''| style="text-align: left;"| '''Linux6.1'''|-| style="text-align: left;"| '''HDMI video'''| style="text-align: left;"| '''OK'''| style="textbackground-aligncolor: left#ffffdc;"| '''OK'''|-| style="text-align: left;"| '''HDMI audio'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''USB2.0 x 3'''| style="text-align: left;"| '''OK'''| style="text-alignwidth: left800px;"| '''OK'''
|-
| style="text-align: left;"| '''TF card start'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''Gigabit Ethernet'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''Infrared receiver'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| <big>'''Please do not connect to WIFI by modifying the /etc/network/interfaces configuration file. There will be problems connecting to the WIFInetwork in this way.'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''Bluetooth'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''headphone audio'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''usb camera'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''LED light'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''26pin GPIO'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''26pin I2C'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''26pin SPI1'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''26pin UART'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''PWM'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''Temperature Sensor'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''hardware watchdog'''| style="text-align: left;"| '''OK'''| style="text-align: left;"| '''OK'''|-| style="text-align: left;"| '''Mali GPU'''| style="text-align: left;"| '''NO'''| style="text-align: left;"| '''NO'''|-| style="text-align: left;"| '''Video codec'''| style="text-align: left;"| '''NO'''| style="text-align: left;"| '''NO'''|-| style="text-align: left;"| '''TV-OUT'''| style="text-align: left;"| '''NO'''| style="text-align: left;"| '''NO'''</big>
|}
<span id="the-formatserver-ofimage-linuxconnects-commandsto-inwifi-thisthrough-manualcommands"></span>==== The format of linux server image connects to WIFI through commands in this manual ====
{| class="wikitable" style="background-color:# In this manualffffdc;width:800px;" |-| <big>'''When the development board is not connected to Ethernet, not connected to HDMI display, but only connected to the serial port, all it is recommended to use the commands that need demonstrated in this section to be entered connect to the WIFI network. Because nmtui can only display characters in some serial port software (such as minicom), and cannot display the graphical interface normally. Of course, if the development board is connected to an Ethernet or HDMI display, you can also use the Linux system will be marked with commands demonstrated in this section to connect to the following boxWIFI network.'''</big>|}
<!-- --><ol start="2" style="list-style-type: decimallower-alpha;"><li><p>Description of If the development board is connected to the debugging serial port, you can use the prompt type serial port terminal to log in front of to the commandLinux system</p><ol style="list-style-type: lower-alpha;"/li><li>The prompt in front of <p>If the command refers development board is connected to the content of the red part in the box below, which is not part of the linux commandHDMI display, so when entering the command you can log in to the linux system, please do not enter through the content of terminal displayed on the red font part.HDMI</p></li></ol>
</li></ol>
<!-- --/div></li></ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>What are Then use the commands that need '''nmcli''' command to be entered?connect to the scanned WIFI hotspot, where:</p>
<ol style="list-style-type: lower-alpha;">
<li>As shown below, <p>'''the black bold partwifi_name''' is the command that needs Need to be input, and the content below the command is replace it with the output content (some commands have output, some may not), and this part name of the content does not need WIFI hotspot you want to connect to be input</lip></olli><li><p>'''wifi_passwd''' Need to change to the password of the WIFI hotspot you want to connect to</lip></olli>
Device 'wlan0'successfully activated with 'verbositycf937f88-ca1e-4411-bb50-61f402eef293'.|}</ol></li></ol><ol start=7"3" style="list-style-type: decimal;"><li>You can view the IP address of wifi through the '''ip addr show wlan0'''command</li>
{| class="wikitable" style="width:800px;"
|-
| style="text-align: left;"| '''Account'''| style="text-align: left;"| '''password'''|-| style="text-align: left;"| '''root'''| style="text-align: left;"| '''orangepi'''|-| style="text-align@orangepi: left;"| ~$ '''ping www.orangepi'''| style="text.org -align: left;"| '''orangepiI wlan0'''|}
rtt min/avg/max/mdev = 41.321/44.864/48.834/2.484 ms|}</ol start><span id="3" style="listthe-server-image-connects-to-wifi-in-a-stylegraphical-type: decimal;way"><li>Use the following command to disable automatic login terminal</li></olspan>
<ol startstyle="4list-style-type: decimal;" ><li><p>First log in to the linux system, there are the following three ways</p><ol style="list-style-type: decimallower-alpha;"><li>Use <p>If the development board is connected with a network cable''', [[Orange Pi Zero 3#SSH remote login development board under Ubuntu|'''SSH remote login development board under Ubuntu''']]'''</p></li><li><p>If the development board is connected to the debugging serial port, you can use the following command serial port terminal to log in to set the orangepi user linux system (please use MobaXterm for the serial port software, and the minicom cannot display the graphical interface)</p></li><li><p>If the development board is connected to automatically the HDMI display, you can log in to the linux system through the HDMI display terminal again</p></li></ol></li><li><p>Then enter the nmtui command in the command line to open the wifi connection interface</p>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''sudo auto_login_cli.sh orangepinmtui'''|}</li></ol><ol start="3" style="list-style-type: decimal;"><li>Enter the nmtui command to open the interface as shown below</li>
[[File:zero3-img108.png]]<span id/ol><ol start="instructions-for-automatic4" style="list-loginstyle-of-linux-desktop-version-systemtype: decimal;"><li>Select '''Activate a connect''' and press Enter</spanli>=== Instructions for automatic login of linux desktop version system ===
<div class="figure">
[[File:media/image82zero3-img110.png|576x324px|1]] </div></ol><ol start="6" style="list-style-type: decimal;"><li>Select the WIFI hotspot you want to connect to, then use the Tab key to position the cursor on '''Activate''' and press Enter</li>
</div><ol startclass="2figure" style="list-style-type: decimal;"><li>Run the following command to prohibit the desktop system from automatically logging into the desktop</li></ol>
</div></ol><ol start="37" style="list-style-type: decimal;"><li>Then restart the system and a login dialog box for entering a password will appearpop up, at which point a enter the corresponding password in '''passwordPassword''' is required and press Enter to enter the systemstart connecting to WIFI</li></ol>
<div class="figure">
[[File:media/image83zero3-img112.png|569x320px|IMG_256]]
</div></ol><span idol start="the-setting-method-of8" style="list-rootstyle-user-automatic-login-in-linux-desktop-version-systemtype: decimal;"><li>After the WIFI connection is successful, a "*" will be displayed in front of the connected WIFI name</spanli>=== The setting method of root user automatic login in Linux desktop version system ===
</div></ol><ol start="29" style="list-style-type: decimal;"><li>Then restart You can view the system, and IP address of wifi through the root user will automatically log in to the desktop'''ip a s wlan0''' command</li></ol>
:inet '''<ol start="3" span style="list-style-typecolor: decimal;#FF0000"><li>Execute the following command to set the desktop system to log in automatically with the orangepi user again192.168.1.11</lispan><'''/ol>24 brd 192.168.1.255 scope global dynamic noprefixroute wlan0
::valid_lft forever preferred_lft forever|}</ol><ol start="210" style="list-style-type: decimal;"><li>Then restart Use the '''ping''' command to test the connectivity of the Linux system wifi network, and you will find that the desktop will not '''ping''' command can be displayedinterrupted through the shortcut key '''Ctrl+C'''</li></ol>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''sudo rebootping www.orangepi.org -I wlan0'''
rtt min/avg/max/mdev = 41.321/44.864/48.834/2.484 ms|}</ol start><span id="2" style="listtest-method-of-styledesktop-type: decimal;image"><li>The method of setting the green light on and off and flashing is as follows:</li></olspan>
<ol start="2" style="list-style-type: lower-alphadecimal;"><li>The command Click '''More networks''' in the pop-up drop-down box to set see all scanned WIFI hotspots, and then select the green light WIFI hotspot you want to connect to stop flashing is as follows</li></ol>
[[File:zero3-img116.png]]</ol><ol start="34" style="list-style-type: lower-alphadecimal;"><li>The command After connecting to set WIFI, you can open the green light browser to be on check whether you can access the Internet. The entrance of the browser is as followsshown in the figure below</li></ol>
[[File:zero3-img118.png]]</ol start><span id="4" style="listthe-method-of-creating-wifi-stylehotspot-type: lowerthrough-alpha;create_ap"><li>The command to set the green light to flash is as follows</li></olspan>
[https://github.com/oblique/create_ap '''Note that the following operations should be performed under the root userhttps://github.com/oblique/create_ap''']</big>|}
<ol start="2" style="list-style-type: lower-alphadecimal;"><li>Then select <p>Enter the following command to create a WIFI hotspot named '''orangepi''' and password '''Systemorangepi'''in NAT mode</li></olp> [[File:media/image85.png{|398x194px]] <ol startclass="3wikitable" style="listbackground-style-typecolor:#ffffdc;width: lower-alpha800px;"|-| <big><lip>Then select '''HardwareNote that in the following commands, Debian12 needs to change eth0 to end0.'''</lip></olbig>|}
wlan0: EAPOL-4WAY-HS-COMPLETED ce:bd:9a:dd:a5:86|}</ol><ol start="3" style="list-style-type: decimal;"><li>Take out the mobile phone at this time, you can find the WIFI hotspot named '''orangepi'Note that this step does not affect the automatic expansion of the Linux system of '' created by the development board. Here I just want in the searched WIFI list, and then you can click '''orangepi''' to explain how connect to check the capacity of hotspot, the TF card after burning the Linux image on the TF card.password is set above '''orangepi'''</li>
[[File:zero3-img119-1.png]]</ol><ol start="4" style="list-style-type: lower-alphadecimal;"><li>First install After the gparted software on connection is successful, the Ubuntu computerdisplay is as shown in the figure below</li></ol>
::inet '''<ol start="3" span style="list-style-typecolor: lower-alpha;#FF0000"><li>After opening gparted, you can select the TF card in the upper right corner, and then you can see the usage of the TF card capacity</li>192.168.1.150</olspan>''' netmask 255.255.255.0 broadcast 192.168.1.255
By default, the DHCP service of the development board will assign an IP address of '''192.168.12.0/dev/mmcblk0p1 15G 915M 14G 7% /24''' to the device connected to the hotspot. At this time, click on the connected WIFI hotspot '''orangepi''', and then you can see that the IP address of the mobile phone is '''192.168.12.X'''
[[File:zero3-img121-2.png]]</li></ol><ol start="46" style="list-style-type: decimal;"><li>After starting the Linux system If you want to specify a different network segment for the first timeconnected device, we you can also remove the TF card from the development board and reinsert specify it into through the '''Ubuntu computer'''-g parameter, and then use gparted to check such as specifying the status network segment of the TF card again, access point AP through the -g parameter as shown in the figure below, the rootfs partition (/dev/ The capacity of sdc1) has been expanded to 14192.168.2.69GiB1</li></ol>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''It should be noted that the Linux system has only one partition in ext4 format, and does not use a separate BOOT partition to store files such as the kernel image, so there is sudo create_ap -m nat wlan0 eth0 orangepi orangepi -g 192.168.2.1 --no problem of expanding the BOOT partition.-virt'''|}
[sudo[File:zero3-img123-1.png] test 的密码:]</li></ol><span id="create_ap-method-to-create-wifi-hotspot-in-bridge-mode"></span>
<ol start="4" style="list-style-type: decimal;"><li>Then enter <p>Enter the root directory of the linux system in the TF card and following command to create a new file WIFI hotspot named '''orangepi''' and password '''orangepi''' in bridge mode</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Note that in the following commands, Debian12 needs to change eth0 to end0.no_rootfs_resize'''</lip></olbig>|}
[sudo[File:zero3-img124-1.png]] test 的密码: root@test:~'''#'''</ol><ol start="46" style="list-style-type: decimal;"><li>Then enter the root directory of the linux system in the TF card and create a new file named '''.no_rootfs_resize'''</li></olp> root@test:~# If the '''cd /media/test/opi_root/--freq-band''' root@test:/media/test/opi_root/# y band. If you want to create a hotspot in the 5G frequency band, you can specify the '''cd root''' root@test:/media/test/opi_root/root# --freq-band 5'''touch parameter.no_rootfs_resize''' root@test:The specific command is as follows</media/test/opi_root/root# '''ls .no_rootfs*'''p> '''.no_rootfs_resize''' <ol start{| class="5wikitable" style="listbackground-style-typecolor:#ffffdc;width: decimal800px;">|-| <libig>Then install the gparted software on the Ubuntu computer</lip></ol> test@test:~$ '''sudo apt install -y gpartedNote that in the following commands, Debian12 needs to change eth0 to end0.''' <ol start="6" style="list-style-type: decimal;"><li>Then open gparted</lip></olbig> test@test:~$ '''sudo gparted'''|}
{| class="wikitable" style="width:800px;"
|-
|
orangepi@orangepi:~$ '''sudo create_ap -m bridge wlan0 eth0 orangepi orangepi --freq-band 5 --no-virt'''
|}
</li></ol>
<ol start="7" style="list-style-type: decimal;">
<li>After opening gparted, <p>If you can select the TF card in need to hide the upper right cornerSSID, and then you can see specify the usage of '''--hidden''' parameter, the TF card capacity. The figure below shows the situation of the TF card after burning the Linux desktop version system. It can be seen that although the total capacity of the TF card specific command is 16GB (displayed as 14.84GiB follows</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Note that in GParted), the rootfs partition (/dev/sdc1) Only 4.05GiB were actually allocatedfollowing commands, leaving 10Debian12 needs to change eth0 to end0.79GiB unallocated'''</lip></olbig>|}
[[File:media/image93zero3-img123-1.png|575x211px]]</li></ol><span id="how-to-set-static-ip-address"></span>
<ol startspan id="10" style="listuse-the-nmtui-command-to-set-a-static-styleip-type: decimal;address"><li/span>Then select the rootfs partition again, click ==== Use the right mouse button, and select '''Resize/Move''' nmtui command to start expanding the size of the rootfs partition</li></ol>set a static IP address ====
<ol startspan id="12" style="listuse-the-nmcli-stylecommand-type: decimal;"><li>Then you can directly drag the location shown in the figure below to -set the size of the capacity, or you can set the size of the rootfs partition by setting the number in '''New sieze(MiB)'''</li-a-static-ip-address"></olspan>
<ol style="list-style-type: decimal;"><li><p>If you want to set the static IP address of the network port, please insert the network cable into the development board first. '''If you need to set the static IP address of WIFI''', please connect the WIFI first, and then startto set the static IP address</p></li><li><p>Then you can view the name of the network device through the '''nmcli con show''' command, as shown below</p><ol style="list-style-type: lower-alpha;"><li><p>'''orangepi''' is the name of the WIFI network interface (the name is not necessarily the same)</p></li><li><p>'''Wired connection 1''' is the name of the Ethernet interface</p>{| class="wikitable" style="width:800px;"|-|orangepi@orangepi:~$ '''nmcli con show'''<br><span style="margin-right: 180px;">NAME</span><span style="margin-right: 260px;">UUID </span><span style="margin-right: 45px;">TYPE </span><span style="margin-right: 50px;">DEVICE</span><br><span style="margin-right: 125px;">'''orangepi'''</span><span style="margin-right: 70px;">cfc4f922-ae48-46f1-84e1-2f19e9ec5e2a</span><span style="margin-right: 50px;">wifi </span><span style="margin-right: 50px;">wlan0</span><br><span style="margin-right: 50px;">'''Wired connection 1'''</span><span style="margin-right: 50px;">9db058b7-7701-37b8-9411-efc2ae8bfa30</span><span style="margin-right: 30px;">ethernet </span><span style="13margin-right: 50px;" >eth0</span><br>|}</li></ol></li><li><p>Then enter the following command, where</p><ol style="list-style-type: decimallower-alpha;"><li>After setting <p>'''"Wired connection 1"''' means to set the static IP address of the Ethernet port. If you need to set the static IP address of the WIFI, please modify it to the corresponding name of the WIFI network interface (you can get it through the '''nmcli con show''' command)</p></li><li><p>'''ipv4.addresses''' is followed by the capacitystatic IP address to be set, click which can be modified to the value you want to set</p></li><li><p>'''ipv4.gateway''' represents the address of the gateway</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo nmcli con mod "Wired connection 1" \</p><p>ipv4.addresses "192.168.1.110" \'''</p><p>'''ipv4.gateway "192.168.1.1" \'''</p><p>'''ipv4.dns "8.8.8.8" \'''Resize</Movep><p>'''ipv4.method "manual"''' in </p>|}</li></ol></li><li><p>Then restart the lower right cornerlinux system</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo reboot'''</p>|}</li><li><p>Then re-enter the linux system and use the '''ip addr show eth0''' command to see that the IP address has been set to the desired value</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''ip addr show eth0'''</p><p>3: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000</p>:<p>link/ether 5e:ae:14:a5:91:b3 brd ff:ff:ff:ff:ff:ff</p>:<p>inet '''<span style="color:#FF0000">192.168.1.110</span>'''/32 brd 192.168.1.110 scope global noprefixroute eth0</p>::<p>valid_lft forever preferred_lft forever</p>:<p>inet6 240e:3b7:3240:c3a0:97de:1d01:b290:fe3a/64 scope global dynamic noprefixroute</p>::<p>valid_lft 259183sec preferred_lft 172783sec</p>:<p>inet6 fe80::3312:861a:a589:d3c/64 scope link noprefixroute</p>::<p>valid_lft forever preferred_lft forever</p>|}</li></ol>
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''/dev/mmcblk0p1 7After the Linux system of the development board is started for the first time, orangepi_first_run.txt will be deleted or renamed to orangepi_first_run.txt.old. At this time, the orangepi_first_run.7G 3txt configuration file will be reset, and then the Linux system of the development board will be restarted, orangepi_first_run.2G 4The configuration in txt will not take effect again, because this configuration will only be effective when the Linux system is started for the first time after burning, please pay special attention to this point.4G 42% /'''</big>|}</li></ol><span id="ssh-remote-login-development-board"></span>
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''After configuring Linux systems enable ssh remote login by default and allow the application program or other development environment root user to log in to the Linux system of the TF card. Before logging in with ssh, if you want first need to back up ensure that the Linux system in the TF cardEthernet or wifi network is connected, you can and then use the method in this section ip addr command or check the router to reduce obtain the size IP address of the rootfs partition first, and then start the backupdevelopment board.'''</big>|}
<ol start="53" style="list-style-type: decimal;"><li>Then select <p>After successfully logging in to the system, the display is as shown in the rootfs partition (figure below</devp><p>[[File:zero3-img141.png]]</sdc1)p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| </libig><p>'''If ssh fails to log in to the linux system normally, first check whether the IP address of the development board can be pinged. If the ping is ok, you can log in to the linux system through the serial port or HDMI display and then enter the following command on the development board and try again. Is it possible to connect:'''</olp>
</div></li><li><p>The display after successfully logging in to the system is shown in the figure below</p><p>[[File:media/image97zero3-img144.png|318x190px]]</p></li></ol>
<ol startspan id="10" style="listhdmi-style-type: decimal;test"><li>After setting the capacity, click'''Resize/Move''' in the lower right corner</li></olspan>
<ol startspan id="11" style="listhdmi-styledisplay-type: decimal;test"><li>After confirming that it is correct, click the green button shown in the figure below'''√'''</li></olspan>=== HDMI display test ===
<ol style="list-style-type: decimal;"><li><p>Use a Micro HDMI to HDMI cable to connect the Orange Pi development board and HDMI display</p><p>[[File:media/image99zero3-img13.png|392x270px]]</p></li><li><p>After starting the linux system, if the HDMI monitor has image output, it means that the HDMI interface is working normally</p>
<ol startstyle="14list-style-type: decimal;" ><li><p>First you need to prepare the following accessories</p><ol style="list-style-type: decimallower-alpha;"><li>Then you can pull out the TF card<p>HDMI to VGA converter</p><p>[[File:zero3-img145.png]]</p></li><li><p>A VGA cable and a Micro HDMI male to HDMI female conversion cable</p><p>[[File:zero3-img146-1.png|300px]] [[File:zero3-img147.png|300px]]</p></li><li><p>A monitor or TV that supports VGA interface</p></li></ol></li><li><p>HDMI to VGA display test as shown below</p><p>[[File:zero3-img148.png]]</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''When using HDMI to VGA display, insert it into the development board and start it up. After entering the Linux system of the development boarddo not need to make any settings, if you can use only the '''df -h''' command to see that the size Micro HDMI interface of the rootfs partition development board can display normally. So if there is a problem with the same as test, please check whether there is a problem with the size set beforeHDMI to VGA converter, it means that the size has been reducedVGA cable and monitor. capacity success'''</p></big>|}</li></ol>
<ol style="list-style-type: decimal;">
<li><p>First, insert one end There is a disp_mode variable in '''/boot/orangepiEnv.txt''' of the network cable into linux system, which can be used to set the Ethernet interface resolution of the development board, and connect the other end HDMI output. The default resolution of the network cable to the router, and ensure that the network linux system is unblocked1080p60</p></li>{| class="wikitable" style="width:800px;" |-| <lip>orangepi@orangepi:~$ '''sudo vim /boot/orangepiEnv.txt'''</p>After the system starts, it will automatically assign an IP address to the Ethernet card through DHCP, without any other configuration</p>verbosity=1</lip><li><p>The command to view the IP address in the Linux system of the development board is as follows:console=both</p><p>disp_mode='''Please do not copy the following commands. For example, the network node name in debian12 is end0, and the following commands need to be changed to ip a s end0.<span style="color:#FF0000">1080p60</span>'''</p><p>fb0_width=1920</p><p>fb0_height=1080</p>|}</li><li><p>The values supported by the disp_mode variable are shown in the table below</olp>
'''In addition, it should be noted that the development board DHCP automatically assigns an IP address without any settings.<span style="color:#FF0000">fb0_width=1920</span>'''
'''<ol start="4" span style="list-style-typecolor: decimal;#FF0000">fb0_height=1080<li/span><p>The command to test the network connectivity is as follows, the ping command can be interrupted through the shortcut key of '''Ctrl+C'''</p><p>'''Please do not copy the following commands. For example, the network node name in debian12 is end0, and the following command needs to be changed to ping www.baidu.com -I end0.'''</p></li></ol>|}
<span id="wifihow-connectionto-use-test"></span>=== WIFI connection test === '''Please do not connect to WIFI by modifying the /etc/network/interfaces configuration file. There will be problems connecting to the WIFI network in this way.''' <span id="the-server-image-connects-to-wifi-through-commands"></span>==== The How to use the server image connects to WIFI through commands ==== '''When the development board is not connected to Ethernet, not connected to HDMI display, but only connected to the serial port, it is recommended to use the commands demonstrated in this section to connect to the WIFI network. Because nmtui can only display characters in some serial port software (such as minicom), and cannot display the graphical interface normally. Of course, if the development board is connected to an Ethernet or HDMI display, you can also use the commands demonstrated in this section to connect to the WIFI network.'''
<ol style="list-style-type: decimal;">
<li><p>First log in to After entering the linux system, you can first check whether there are is a Bluetooth device node through the following three ways'''hciconfig''' command. If it exists, it means that the Bluetooth initialization is normal.</p><ol {| class="wikitable" style="listwidth:800px;" |-style-type| <p>orangepi@orangepi: lower~$ '''sudo apt update && sudo apt install -alpha;"y bluez'''</p><lip>If the development board is connected with a network cable, orangepi@orangepi:~$ '''you can remotely log in to the Linux system through sshhciconfig -a'''</lip><p>hci0: Type: Primary Bus: UART</p>:<p>BD Address: 3E:61:3D:19:0E:52 ACL MTU: 1021:8 SCO MTU: 240:3</p>:<p>UP RUNNING</p>:<p>RX bytes:925 acl:0 sco:0 events:72 errors:0</olp>:<p>TX bytes:5498 acl:0 sco:0 commands:72 errors:0</p>:<!-- --p>Features: 0xbf 0xff 0x8d 0xfe 0xdb 0x3d 0x7b 0xc7</p>:<ol style="list-style-p>Packet type: lower-alpha;"DM1 DM3 DM5 DH1 DH3 DH5 HV1 HV2 HV3</p>:<p>Link policy: RSWITCH SNIFF<li/p>:<p>If the development board is connected to the debugging serial port, you can use the serial port terminal to log in to the Linux systemLink mode: SLAVE ACCEPT</p>:<p>Name: 'orangepi'</lip>:<lip>Class: 0x3c0000</p>:<p>If the development board is connected to the HDMI displayService Classes: Rendering, Capturing, Object Transfer, you can log in to the linux system through the terminal displayed on the HDMIAudio</p>:<p>Device Class: Miscellaneous,</lip>:<p>HCI Version: 5.0 (0x9) Revision: 0x400</olp>:<p>LMP Version: 5.0 (0x9) Subversion: 0x400</lip>:<p>Manufacturer: Spreadtrum Communications Shanghai Ltd (492)</olp>|}<!-- --/li># First use the <li><p>Use '''nmcli dev wifibluetoothctl'''command to scan the surrounding WIFI hotspotsbluetooth devices</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''nmcli dev wifisudo bluetoothctl'''</p><div class="figure"p> [NEW] Controller 10:11:12:13:14:15 orangepizero3 [File:media/image107.png|575x250px|选区_011default]] </divp><ol start="2" style="list-style-type: decimal;"p>Agent registered<li/p><p>Then use the [bluetooth]# '''nmclipower on #enable controller''' command to connect to the scanned WIFI hotspot, where:</p><ol style="list-style-type: lower-alpha;"p>Changing power on succeeded<li/p><p>[bluetooth]# '''wifi_namediscoverable on #Make the controller discoverable''' Need to replace it with the name of the WIFI hotspot you want to connect to</p><p>Changing discoverable on succeeded</lip><lip>[CHG] Controller 10:11:12:13:14:15 Discoverable: yes</p><p>[bluetooth]# '''wifi_passwdpairable on #Set the controller as pairable'''Need to change to the password of the WIFI hotspot you want to connect to</p><p>Changing pairable on succeeded</lip><p>[bluetooth]# '''scan on #Start scanning for nearby Bluetooth devices'''</olp><p>Discovery started</lip><p>[CHG] Controller 10:11:12:13:14:15 Discovering: yes</olp><p>[NEW] Device 76:60:79:29:B9:31 76-60-79-29-B9-31</p>orangepi@orangepi<p>[NEW] Device 9C:2E:A1:42:71:~$ 11 MiPhone</p><p>'''sudo nmcli dev wifi connect wifi_name password wifi_passwd[NEW] Device DC:72:9B:4C:F4:CF orangepi'''</p> Device <p>[bluetooth]# ''wlan0' successfully activated with scan off #After scanning to the Bluetooth device you want to connect, you can close the scan, and then write down the MAC address of the Bluetooth device. The Bluetooth device tested here is an Android phone, the name of the Bluetooth is orangepi, and the corresponding MAC address is DC:72:9B:4C :F4:CF''cf937f88-ca1e-4411-bb50-61f402eef293'.</p><p>Discovery stopped</p><p>[CHG] Controller 10:11:12:13:14:15 Discovering: no</p><p>[CHG] Device DC:72:9B:4C:F4:CF RSSI is nil</p>|}<ol start/li><li><p>After scanning to the device you want to pair, you can pair it. You need to use the MAC address of the device for pairing</p>{| class="3wikitable" style="list-style-typewidth: decimal800px;">|-| <lip>You can view [bluetooth]# '''pair DC:72:9B:4C:F4:CF''' '''#Use the IP MAC address of wifi through the scanned Bluetooth device for pairing'''ip addr show wlan0''' command</lip><p>Attempting to pair with DC:72:9B:4C:F4:CF</p><p>[CHG] Device DC:72:9B:4C:F4:CF Connected: yes</olp><p>Request confirmation</p>orangepi@orangepi<p>[leeb1m[agent] Confirm passkey 764475 (yes/no):~$ '''ip a s wlan0yes''' '''#Enter yes here, and you need to confirm on the mobile phone'''</p><p>[CHG] Device DC:72:9B:4C:F4:CF Modalias: bluetooth:v010Fp107Ed1436</p>11<p>[CHG] Device DC:72:9B:4C:F4: wlan0CF UUIDs: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 0000046a-0000-1000-8000-00805f9b34fb</p> link/ether 23<p>[CHG] Device DC:72:9B:8c4C:d6F4:aeCF ServicesResolved:76yes</p><p>[CHG] Device DC:bb brd ff72:ff9B:ff4C:ffF4:ffCF Paired:ffyes</p> inet <p>'''192.168.1.11Pairing successful #Prompt that the pairing is successful'''</24 brd 192.168.1.255 scope global dynamic noprefixroute wlan0p> valid_lft 259192sec preferred_lft 259192sec inet6 240e<p>[CHG] Device DC:3b772:32409B:c3a04C:c401F4:a445CF ServicesResolved:5002:ccddno</64 scope global dynamic noprefixroutep> valid_lft 259192sec preferred_lft 172792sec inet6 fe80<p>[CHG] Device DC:72:9B:42f14C:6019F4:a80eCF Connected:4c31no</64 scope link noprefixroutep>|}valid_lft forever preferred_lft forever</li><li><p>After the pairing is successful, the Bluetooth interface of the mobile phone will be displayed as follows</p><ol p>[[File:zero3-img160.png]]</p></li><li><p>To connect a Bluetooth device, you need to install the '''pulseaudio-module-bluetooth''' package, and then startthe '''pulseaudio''' service</p>{| class="4wikitable" style="list-style-typewidth: decimal800px;"|-| <p>orangepi@orangepi:~$ '''sudo apt update'''</p><lip>Use the orangepi@orangepi:~$ '''pingsudo''' command to test the connectivity of the wifi network, and the '''pingapt -y install pulseaudio-module-bluetooth''' command can be interrupted through the shortcut key </p><p>orangepi@orangepi:~$ '''Ctrl+pulseaudio --start'''</p>|}</li><li><p>How to connect to a Bluetooth device</olp>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''ping www.sudo bluetoothctl'''</p><p>Agent registered</p><p>[bluetooth]# '''paired-devices #View the MAC address of the paired Bluetooth device'''</p><p>Device DC:72:9B:4C:F4:CF orangepi</p><p>[bluetooth]# '''connect DC:72:9B:4C:F4:CF #Connect to bluetooth device using MAC address'''</p><p>Attempting to connect to DC:72:9B:4C:F4:CF</p><p>[CHG] Device DC:72:9B:4C:F4:CF Connected: yes</p><p>Connection successful</p><p>[CHG] Device DC:72:9B:4C:F4:CF ServicesResolved: yes</p><p>[CHG] Controller 10:11:12:13:14:15 Discoverable: no</p><p>'''[orangepi.org -I wlan0]# #This prompt appears to indicate that the connection is successful'''</p>|}</li><li><p>After connecting the bluetooth device, the bluetooth configuration interface of the Android mobile phone can see '''the prompt that the audio has been connected for calls and media'''</p><div class="figure">
<span id="connect-usb-storage- www.orangepi.org ping statistics --device-test"></span>=== Connect USB storage device test ===
<span idol start="the3" style="list-serverstyle-image-connects-to-wifi-in-a-graphical-waytype: decimal;"></spanli>==== The server image connects Use the mount command to mount the U disk to WIFI '''/mnt''', and then you can view the files in a graphical way ====the U disk</li>
orangepi@orangepi:~$ '''sudo nmtuils /mnt/''' <ol start="3" style="list-style-type: decimal;"><li>Enter the nmtui command to open the interface as shown below</li></ol> [[File:media/image108.png|345x215px]]
test.txt
|}
</ol>
<ol start="4" style="list-style-type: decimal;">
<li>Select After mounting, you can view the capacity usage and mount point of the U disk through the '''Activate a connectdf -h''' and press Entercommand</li></ol>
/dev/sda1 29G 208K 29G 1% /mnt|}</ol start><span id="5" style="listusb-ethernet-stylecard-type: decimal;test"><li>Then you can see all the searched WIFI hotspots</li></olspan>
<div ol start="2" style="list-style-type: decimal;"><li><p>First insert the USB network card into the USB interface of the development board, and then insert the network cable into the USB network card to ensure that the network cable can access the Internet normally. If you can see the following log information through the '''dmesg''' command, it means that the USB network card is recognized normally.</p>{| class="figurewikitable"style="width:800px;" |-| <p>orangepi@orangepi:~$ '''dmesg | tail'''</p><p>[ 121.985016] usb 3-1: USB disconnect, device number 2</p><p>[ 126.873772] sunxi-ehci 5311000.ehci3-controller: ehci_irq: highspeed device connect</p><p>[ 127.094054] usb 3-1: new high-speed USB device number 3 using sunxi-ehci</p><p>[ 127.357472] usb 3-1: reset high-speed USB device number 3 using sunxi-ehci</p><p>[ 127.557960] r8152 3-1:1.0 eth1: v1.08.9</p><p>[ 127.602642] r8152 3-1:1.0 enx00e04c362017: renamed from eth1</p><p>[ 127.731874] IPv6: ADDRCONF(NETDEV_UP): enx00e04c362017: link is not ready</p><p>[127.763031] IPv6: ADDRCONF(NETDEV_UP): enx00e04c362017: link is not ready</p><p>[File129.892465] r8152 3-1:media1.0 enx00e04c362017: carrier on</image111p><p>[ 129.jpeg892583] IPv6: ADDRCONF(NETDEV_CHANGE): enx00e04c362017: link becomes ready</p>|}</li><li><p>Then you can see the device node of the USB network card and the automatically assigned IP address through the ifconfig command</p>{| class="wikitable" style="width:800px;" |474x298px-|<p>orangepi@orangepi:~$ '''sudo ifconfig'''</p><p>'''enx00e04c362017''': flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500</p>::<p>inet '''192.168.1.177''' netmask 255.255.255.0 broadcast 192.168.1.255</p>::<p>inet6 fe80::681f:d293:4bc5:e9fd prefixlen 64 scopeid 0x20<link></p>::<p>ether 00:e0:4c:36:20:17]]txqueuelen 1000 (Ethernet)</p>::<p>RX packets 1849 bytes 134590 (134.5 KB)</p>::<p>RX errors 0 dropped 125 overruns 0 frame 0</p>::<p>TX packets 33 bytes 2834 (2.8 KB)</p>::<p>TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0</p>|}</li><li><p>The command to test network connectivity is as follows</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''ping www.baidu.com -I enx00e04c362017'''</p><p>PING www.a.shifen.com (14.215.177.38) from 192.168.1.12 eth0: 56(84) bytes of data.</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=1 ttl=56 time=6.74 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=2 ttl=56 time=6.80 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=3 ttl=56 time=6.26 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=4 ttl=56 time=7.27 ms</p><p>^C</p><p>--- www.a.shifen.com ping statistics ---</p><p>4 packets transmitted, 4 received, 0% packet loss, time 3002ms</p><p>rtt min/avg/max/mdev = 6.260/6.770/7.275/0.373 ms</p>|}</li></ol>
</div><ol startspan id="7" style="listusb-stylecamera-type: decimal;test"><li>Then a dialog box for entering a password will pop up, enter the corresponding password in '''Password''' and press Enter to start connecting to WIFI</li></olspan>
<span id="headphone-jack-playback- www.orangepi.org ping statistics --audio-test"></span>==== Headphone jack playback audio test ====
<span id/div></li><li><p>Through the '''aplay -l''' command, you can view the sound card devices supported by the Linux system</p><ol style="testlist-method-ofstyle-desktoptype: lower-imagealpha;"><li><p>The output of the linux5.4 system is as follows, where '''card 0: audiocodec''' is the sound card device required for earphone playback</spanp>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~# '''aplay -l'''</p><p>**** List of PLAYBACK Hardware Devices ****</p><p>'''card 0: audiocodec [audiocodec], device 0: SUNXI-CODEC sun50iw9-codec-0 []'''</p>:<p>'''Subdevices: 1/1'''</p>:<p>'''Subdevice #0: subdevice #0'''</p>|}</li><li><p>The output of the linux6.1 system is as follows, where '''audiocodec''' is the sound card device required for earphone playback</p>{| class="wikitable" style= Test method "width:800px;" |-| <p>root@orangepi:~# '''aplay -l'''</p><p>**** List of desktop image PLAYBACK Hardware Devices ****</p><p>'''card 0: audiocodec [audiocodec], device 0: CDC PCM Codec-0 [CDC PCM Codec-0]'''</p>:<p>'''Subdevices: 1/1'''</p>:<p>'''Subdevice #0: subdevice #0'''</p>|}</li></ol></li><li><p>Then use the '''aplay''' command to play the audio, and the headset can hear the sound</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~# '''aplay -D hw:0,0 /usr/share/sounds/alsa/audio.wav'''</p><p>Playing WAVE 'audio.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo</p>|}{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''If there is noise in the earphone test, please pull out some earphones, do not insert all the earphones.'''</big>|}</li></ol>
<ol start="2" style="list-style-type: decimal;"><li>Click '''More networks''' in <p>First use the pop-up drop-down box Micro HDMI to HDMI cable to see all scanned WIFI hotspots, and then select connect the WIFI hotspot you want Orange Pi development board to connect the TV (other HDMI monitors need toensure that they can play audio)</p></li><li><p>HDMI audio playback does not require other settings, just use the '''aplay''' command to play directly</olp>{| class="wikitable" style="width:800px;" |-[[File| <p>root@orangepi:~# '''aplay -D hw:media2,0 /image115usr/share/sounds/alsa/audio.pngwav'''</p>|576x353px]]}</li></ol>
<ol startspan id="3" style="listtesting-audio-methods-on-styledesktop-type: decimal;systems"><li>Then enter the password of the WIFI hotspot, and then click '''Connect'''to start connecting to WIFI</li></olspan>
<ol start="4" style="list-style-type: decimal;"><li>After connecting to WIFI, you can <p>First open the browser to check whether you can access the Internetfile manager</p><p>[[File:zero3-img164. The entrance of png]]</p></li><li><p>Then find the browser following file (if there is shown no audio file in the figure belowsystem, you can upload an audio file to the system yourself)</lip></oldiv class="figure">
[[File:media/image117zero3-img165.png|465x249px]]
</div></li><li><p>Then select the audio.wav file, right click and select open with vlc to start playing</p><p>[[File:zero3-img166.png]]</p></li><li><p>How to switch between different audio devices such as HDMI playback and headphone playback</p><ol start="5" style="list-style-type: decimallower-alpha;"><li>If you can <p>First open other web pages after opening the browservolume control interface</p><p>[[File:zero3-img167.png]]</p></li><li><p>When playing audio, it means the audio device options that the WIFI connection is normalplayback software can use will be displayed in '''Playback''', as shown in the figure below, where you can set which audio device to play to</lip></oldiv class="figure">
[[File:media/image118zero3-img168.png|576x222px]]
<span id="the-method-of-creating-wifi-hotspot-through-create_ap"/div></spanli></ol>=== The method of creating WIFI hotspot through create_ap ===</li></ol>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''sudo''' '''* wifi-interface:The name of the wireless network cardapt update'''
orangepi@orangepi:~$ '''* interface-with-internet:sudo''' '''The name of the network card that can be connected to the Internet, generally eth0apt-get install -y ir-keytable'''|}</ol><ol start="3" style="list-style-type: decimal;"><li><p>Then execute ir-keytable to view the information of the infrared device</p><ol style="list-style-type: lower-alpha;"><li>linux5.4 system output is as follows</li>
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''* access-pointir-name: hotspot namekeytable'''
orangepi@orangepi:~$ '''sudo ifconfig eth0cat /sys/class/thermal/thermal_zone0/temp'''
temp1: +'''<ol start="6" span style="list-style-typecolor: decimal;#FF0000"><li>If you want to specify a different network segment for the connected device, you can specify it through the -g parameter, such as specifying the network segment of the access point AP through the -g parameter as 192.168.247.18°C</li></olspan>''' (crit = +110.0°C)
<ol style="list-style-type: decimal;">
<li><p>Enter Please refer to the figure below for the order of the interface pins of the 13 pin expansion board on the following command to create a WIFI hotspot named '''orangepi''' and password '''orangepi''' in bridge modedevelopment board</p><p>'''Note that in the following commands, Debian12 needs to change eth0 to end0.'''</p></li></oldiv class="figure">
</div></li><li><p>The schematic diagram of the 13pin interface of the development board is as follows</p><p>[[File:zero3-img19.png]]</p></li><li><p>The function description of the 13 pin expansion board interface pins of the development board is as follows</p><ol startstyle="2list-style-type: lower-alpha;" ><li><p>When the 13pin pin is connected to the expansion board, it can be provided additionally</p><ol style="list-style-type: decimalnone;"><li>If <p>a) 2个USB 2.0 Host</p></li><li><p>b) Audio output of the left and right audio channels of the earphones</p></li><li><p>c) TV-OUT video output</p></li><li><p>d) Infrared receiving function</p></li><li><p>e) After the following information expansion board is outputconnected, pins 10, 11 and 12 of the 13pin interface cannot be used</p></li><li><p>f) '''In addition, it means should be noted that the WIFI hotspot is created successfullyMIC on the 13pin expansion board cannot be used on the Orange Pi Zero 3'''</p></li></ol></li><li><p>When pin 13 is not connected to the expansion board, pins 10, 11, 12 and 13 can be used as ordinary GPIO ports</p></li>
<div style="display: flex;">
{| class="wikitable" style="width:380px;margin-right: 20px;"
|-
| style="text-align: center;"| '''GPIO S/N'''
| style="text-align: center;"| '''GPIO'''
| style="text-align: center;"| '''Function'''
| style="text-align: center;"| '''Pin'''
|-
| style="text-align: center;"|
| style="text-align: center;"|
| style="text-align: center;"| '''3.3V'''
| style="text-align: center;"| '''1'''
|-
| style="text-align: center;"| '''229'''
| style="text-align: center;"| '''PH5'''
| style="text-align: center;"| '''TWI3-SDA'''
| style="text-align: center;"| '''3'''
|-
| style="text-align: center;"| '''228'''
| style="text-align: center;"| '''PH4'''
| style="text-align: center;"| '''TWI3-SCK'''
| style="text-align: center;"| '''5'''
|-
| style="text-align: center;"| '''73'''
| style="text-align: center;"| '''PC9'''
| style="text-align: center;"| '''PC9'''
| style="text-align: center;"| '''7'''
|-
| style="text-align: center;"|
| style="text-align: center;"|
| style="text-align: center;"| '''GND'''
| style="text-align: center;"| '''9'''
|-
| style="text-align: center;"| '''70'''
| style="text-align: center;"| '''PC6'''
| style="text-align: center;"| '''PC6'''
| style="text-align: center;"| '''11'''
|-
| style="text-align: center;"| '''69'''
| style="text-align: center;"| '''PC5'''
| style="text-align: center;"| '''PC5'''
| style="text-align: center;"| '''13'''
|-
| style="text-align: center;"| '''72'''
| style="text-align: center;"| '''PC8'''
| style="text-align: center;"| '''PC8'''
| style="text-align: center;"| '''15'''
|-
| style="text-align: center;"|
| style="text-align: center;"|
| style="text-align: center;"| '''3.3V'''
| style="text-align: center;"| '''17'''
|-
| style="text-align: center;"| '''231'''
| style="text-align: center;"| '''PH7'''
| style="text-align: center;"| '''SPI1_MOSI'''
| style="text-align: center;"| '''19'''
|-
| style="text-align: center;"| '''232'''
| style="text-align: center;"| '''PH8'''
| style="text-align: center;"| '''SPI1_MISO'''
| style="text-align: center;"| '''21'''
|-
| style="text-align: center;"| '''230'''
| style="text-align: center;"| '''PH6'''
| style="text-align: center;"| '''SPI1_CLK'''
| style="text-align: center;"| '''23'''
|-
| style="text-align: center;"|
| style="text-align: center;"|
| style="text-align: center;"| '''GND'''
| style="text-align: center;"| '''25'''
|}
{| class="wikitable" style="width:380px;"
|-
| style="text-align: center;"| '''Pin'''
| style="text-align: center;"| '''Function'''
| style="text-align: center;"| '''GPIO'''
| style="text-align: center;"| '''GPIO S/N'''
|-
| style="text-align: center;"| '''2'''
| style="text-align: center;"| '''5V'''
| style="text-align: center;"|
| style="text-align: center;"|
|-
| style="text-align: center;"| '''4'''
| style="text-align: center;"| '''5V'''
| style="text-align: center;"|
| style="text-align: center;"|
|-
| style="text-align: center;"| '''6'''
| style="text-align: center;"| '''GND'''
| style="text-align: center;"|
| style="text-align: center;"|
|-
| style="text-align: center;"| '''8'''
| style="text-align: center;"| '''UART5_TX'''
| style="text-align: center;"| '''PH2'''
| style="text-align: center;"| '''226'''
|-
| style="text-align: center;"| '''10'''
| style="text-align: center;"| '''UART5_RX'''
| style="text-align: center;"| '''PH3'''
| style="text-align: center;"| '''227'''
|-
| style="text-align: center;"| '''12'''
| style="text-align: center;"| '''PC11'''
| style="text-align: center;"| '''PC11'''
| style="text-align: center;"| '''75'''
|-
| style="text-align: center;"| '''14'''
| style="text-align: center;"| '''GND'''
| style="text-align: center;"|
| style="text-align: center;"|
|-
| style="text-align: center;"| '''16'''
| style="text-align: center;"| '''PC15'''
| style="text-align: center;"| '''PC15'''
| style="text-align: center;"| '''79'''
|-
| style="text-align: center;"| '''18'''
| style="text-align: center;"| '''PC14'''
| style="text-align: center;"| '''PC14'''
| style="text-align: center;"| '''78'''
|-
| style="text-align: center;"| '''20'''
| style="text-align: center;"| '''GND'''
| style="text-align: center;"|
| style="text-align: center;"|
|-
| style="text-align: center;"| '''22'''
| style="text-align: center;"| '''PC7'''
| style="text-align: center;"| '''PC7'''
| style="text-align: center;"| '''71'''
|-
| style="text-align: center;"| '''24'''
| style="text-align: center;"| '''SPI1_CS'''
| style="text-align: center;"| '''PH9'''
| style="text-align: center;"| '''233'''
|-
| style="text-align: center;"| '''26'''
| style="text-align: center;"| '''PC10'''
| style="text-align: center;"| '''PC10'''
| style="text-align: center;"| '''74'''
|}
</div>
</li></ol>
<ol start="3" style="list-style-type: decimal;">
<li>Take out the mobile phone at this time, and you can find the WIFI hotspot named orangepi created by the development board There are a total of 17 GPIO ports in the searched WIFI list26pin interface, and then you can click '''orangepi''' to connect to the hotspot, and the password voltage of all GPIO ports is the '''orangepi<span style="color:#FF0000">3.3v</span>''' set above</li></ol>
<ol start="6" style="list-style-type: decimal;"><li><p>If The following takes pin 7—corresponding to GPIO as PC9—corresponding to wPi number 2—as an example to demonstrate how to set the high and low levels of the GPIO port</p><p>[[File:zero3-img173.png]]</p></li><li><p>First set the GPIO port to output mode, where the third parameter requires the serial number of the wPi corresponding to the input pin</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~/wiringOP# '''--freq-bandgpio mode <span style="color:#FF0000">2</span> out''' y band</p>|}</li><li><p>Then set the GPIO port to output a low level. If After setting, you want can use a multimeter to create a hotspot in measure the voltage value of the 5G frequency bandpin. If it is 0v, you can specify it means that the low level is set successfully</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~/wiringOP# '''--freq-band 5gpio write 2 <span style="color:#FF0000">0</span>''' parameter</p>|}<p>Use gpio readall to see that the value (V) of pin 7 has changed to 0</p><p>[[File:zero3-img174.png]]</p></li><li><p>Then set the GPIO port to output a high level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is 3. The specific command 3v, it means that the high level is as followsset successfully.</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~/wiringOP# '''gpio write 2 <span style="color:#FF0000">1</span>'''Note </p>|}<p>Use gpio readall to see that in the following commandsvalue (V) of pin 7 has changed to 1</p><p>[[File:zero3-img175.png]]</p></li><li><p>The setting method of other pins is similar, Debian12 needs just modify the serial number of wPi to change eth0 to end0.'''the corresponding serial number of the pin</p></li></ol>
<ol style="list-style-type: decimal;"><li><p>The following takes pin 7—the corresponding GPIO is PC9—the corresponding wPi number is 2—as an example to demonstrate how to set the pull-up and pull-down resistors of the GPIO port</p><p>[[File:zero3-img173.png]]</p></li><li><p>First, you need to set the GPIO port to the input mode, and the third parameter needs to be the serial number of the wPi corresponding to the input pin</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~/wiringOP# '''gpio mode <span style="color:#FF0000">2</span> in'''</p>|}</li><li><p>After setting to input mode, execute the following command to set the GPIO port to pull-up mode</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~$ /wiringOP# '''sudo create_ap gpio mode <span style="color:#FF0000">2</span> up'''</p>|}</li><li><p>Then enter the following command to read the level of the GPIO port, if the level is 1, it means that the pull-up mode is set successfully</p>{| class="wikitable" style="width:800px;" |-m bridge wlan0 eth0 orangepi | <p>root@orangepi :~/wiringOP# '''gpio read <span style="color:#FF0000">2</span>'''</p><p>'''1'''</p>|}</li><li><p>Then execute the following command to set the GPIO port to pull-down mode</p>{| class="wikitable" style="width:800px;" |-hidden | <p>root@orangepi:~/wiringOP# '''gpio mode <span style="color:#FF0000">2</span> down'''</p>|}</li><li><p>Then enter the following command to read the level of the GPIO port, if the level is 0, the pull-down mode is set successfully</p>{| class="wikitable" style="width:800px;" |-no-virt| <p>root@orangepi:~/wiringOP# '''gpio read <span style="color:#FF0000">2</span>'''</p><p>'''0'''</p>|}</li></ol>
<ol style="list-style-type: decimal;">
<li><p>First run According to the schematic diagram of the 26pin interface, the '''nmtui''' command</p><p>orangepi@orangepi:~$ '''sudo nmtui'''</p></li><li><p>Then select '''Edit a connection''' and press Enteravailable spi is spi1</p><p>[[File:media/image125zero3-img176.png|227x247px]]</p></li><li><p>Then select The spi1 is disabled by default in the network interface that Linux system and needs to set a static IP address, for example, be manually enabled before it can be used. The steps to set the static IP address of the '''Ethernet''' interface, select '''Wired connection 1'''.open are as follows:</p><p>[[Fileol style="list-style-type:media/image126.png|310x149px]]</p></lilower-alpha;"><li><p>Then select First run '''Editorangepi-config''' with the , normal users remember to add '''Tabsudo''' key and press the Enter keypermission</p><p>[[File{| class="wikitable" style="width:media/image127.png800px;" |-|316x144px]]</p></li><li><p>Then use the Tab key to move the cursor to the orangepi@orangepi:~$ '''<Automatic>sudo orangepi-config''' position shown in the figure below to configure IPv4</p><p>[[File:media/image128.png|575x240px]]</p>}</li><li><p>Then press Enter, select '''ManualSystem''' through the up and down arrow keys, and press Enter to confirm</p><p>[[File:media/image129.png|576x237px]]</p></li><li><p>The display after selection is shown in the figure below</p><p>[[File:media/image130zero3-img85.png|575x240px]]</p></li><li><p>8) Then move the cursor to select '''<Show>Hardware''' via the Tab key</p><p>[[File:media/image131zero3-img86.png|576x241px]]</p></li><li><p>Then press Enter, use the following setting interface will pop up after entering</p><p>[[File:media/image132.png|575x450px]]</p></li><li><p>Then you can set arrow keys on the IP address (Addresses), gateway (Gateway) and DNS server address in keyboard to navigate to the position shown in the figure below (there are many other setting options in it, please explore by yourself), and then use the '''please set according to your specific needs, The values set in the image below are just an examplespace'''</p><p>[[File:media/image133.png|576x233px]]</p></li><li><p>After setting, move the cursor to select '''<OK>spi1-cs1-spidev''' in the lower right corner, and press Enter to confirm</p><p>[[File:media/image134zero3-img177.png|576x116px]]</p></li><li><p>Then click select '''<BackSave>''' to return to the previous selection interfacesave</p><p>[[File:media/image135zero3-img88.png|330x325px]]</p></li><li><p>Then select '''Activate a connection''', then move the cursor to '''<OKBack>''', and finally click Enter</p><p>[[File:media/image136zero3-img89.png|331x248px]]</p></li><li><p>Then select the network interface that needs to be set, such as '''Wired connection 1''', then move the cursor to <DeactivateReboot>, and press the Enter key to disable '''Wired connection 1'''</p><p>[[File:media/image137.png|576x224px]]</p></li><li><p>Then please do not move to restart the cursor, and then press the Enter key system to re-enable '''Wired connection 1''', so that make the static IP address set earlier will configuration take effect</p><p>[[File:media/image138.png|576x224px]]</p></li><li><p>Then you can exit nmtui through the '''<Back>''' and '''Quit''' buttons</p><p>[[File:media/image139.png|300x253px]] [[File:media/image140zero3-img90.png|227x252px]]</p></li><li><p>Then through '''ip a s eth0''', you can see that the IP address of the network port has changed to the static IP address set earlier</p><p>'''Note that in the following commands, Debian12 needs to change eth0 to end0.'''</p><p>orangepi@orangepi:~$ '''ip a s eth0'''</p><p>3: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000</p><p>link/ether 5e:ac:14:a5:92:b3 brd ff:ff:ff:ff:ff:ff</p><p>inet '''192.168.1.177'''/24 brd 192.168.1.255 scope global noprefixroute eth0</p><p>valid_lft forever preferred_lft forever</p><p>inet6 241e:3b8:3240:c3a0:e269:8305:dc08:135e/64 scope global dynamic noprefixroute</p><p>valid_lft 259149sec preferred_lft 172749sec</p><p>inet6 fe80::957d:bbbe:4928:3604/64 scope link noprefixroute</p><p>valid_lft forever preferred_lft forever</p></li><li><p>Then you can test the connectivity of the network to check whether the IP address is configured OK, and the '''ping''' command can be interrupted through the shortcut key '''Ctrl+C'''</p><p>'''Note that in the following commands, Debian12 needs to change eth0 to end0.'''</p><p>orangepi@orangepi:~$ '''ping 192.168.1.177 -I eth0'''</p><p>PING 192.168.1.47 (192.168.1.47) from 192.168.1.188 eth0: 56(84) bytes of data.</p><p>64 bytes from 192.168.1.47: icmp_seq=1 ttl=64 time=0.233 ms</p><p>64 bytes from 192.168.1.47: icmp_seq=2 ttl=64 time=0.263 ms</p><p>64 bytes from 192.168.1.47: icmp_seq=3 ttl=64 time=0.273 ms</p><p>64 bytes from 192.168.1.47: icmp_seq=4 ttl=64 time=0.269 ms</p><p>64 bytes from 192.168.1.47: icmp_seq=5 ttl=64 time=0.275 ms</p><p>^C</p><p>--- 192.168.1.47 ping statistics ---</p><p>5 packets transmitted, 5 received, 0% packet loss, time 4042ms</p><p>rtt min/avg/max/mdev = 0.233/0.262/0.275/0.015 ms</p></li></ol> <span id="use-the-nmcli-command-to-set-a-static-ip-address"></span>==== Use the nmcli command to set a static IP address ==== <ol style="list-style-type: decimal;"><li><p>If you want to set the static IP address of the network port, please insert the network cable into the development board first. '''If you need to set the static IP address of WIFI''', please connect the WIFI first, and then start to set the static IP address</p></li><li><p>Then you can view the name of the network device through the '''nmcli con show''' command, as shown below</p><ol style="list-style-type: lower-alpha;"><li><p>'''orangepi''' is the name of the WIFI network interface (the name > is not necessarily the same)</p></li><li><p>'''Wired connection 1''' is the name of the Ethernet interface</p><p>orangepi@orangepi:~$ '''nmcli con show'''</p><p>NAME UUID TYPE DEVICE</p><p>'''orangepi''' cfc4f922-ae48-46f1-84e1-2f19e9ec5e2a wifi wlan0</p><p>'''Wired connection 1''' 9db058b7-7701-37b8-9411-efc2ae8bfa30 ethernet eth0</p></li></ol>
</li>
<li><p>Then enter the following command, where</p><ol style="list-style-type: lower-alpha;"><li><p>check whether there is a '''"Wired connection spidev1.1"''' means to set the static IP address of > device node in the Ethernet portLinux system. If you need to set the static IP address of > the WIFIit exists, please modify it to means that the corresponding name configuration of the > WIFI network interface (you can get it through the '''nmcli con > show''' command)SPI1 has taken effect</p></li><li><p>'''ipv4.addresses''' is followed by the static IP address to be >{| class="wikitable" style="width:800px; set, which can be modified to the value you want to set</p></li>" |-<li><p>'''ipv4.gateway''' represents the address of the gateway</p>| <p>orangepi@orangepi:~$ '''sudo nmcli con mod "Wired connection 1" \<br ls /dev/>ipv4.addresses "192.168.1.110" \spidev1*'''</p><p>'''ipv4.gateway "192.168/dev/spidev1.1.1" \'''</p><p>'''ipv4.dns "8.8.8.8" \'''</p><p>'''ipv4.method "manual"'''</p></li></ol>|}
</li>
<li><p>Then restart Do not short-circuit the mosi and miso pins of SPI1 first, the output result of running spidev_test is as follows, you can see that the linux systemdata of TX and RX are inconsistent</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo rebootspidev_test -v -D /dev/spidev1.1'''</p><p>spi mode: 0x0</p><p>bits per word: 8</lip><lip>max speed: 500000 Hz (500 KHz)</p><p>Then re-enter the linux system and use the TX | FF FF FF FF FF FF '''ip addr show eth0<span style="color:#FF0000">40 00 00 00 00 95</span>''' command to see that the IP address has been set to the desired valueFF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D | ......@.…▒..................▒.</p><p>orangepi@orangepi:~$ RX | FF FF FF FF FF FF '''ip addr show eth0<span style="color:#FF0000">FF FF FF FF FF FF</span>'''FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF | ............................….</p>|}</li><li><p>3: eth0: <BROADCASTThen short the two pins of mosi (the 19th pin in the 26pin interface) and miso (the 21st pin in the 26pin interface) of SPI1,MULTICASTand then run the output of spidev_test as follows,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000you can see the sending and receiving same data</p><p>link/ether 5e{| class="wikitable" style="width:ae:14:a5:91:b3 brd ff:ff:ff:ff:ff:ff</p>800px;" |-| <p>inet orangepi@orangepi:~$ '''192.168sudo spidev_test -v -D /dev/spidev1.1.110'''/32 brd 192.168.1.110 scope global noprefixroute eth0</p><p>valid_lft forever preferred_lft foreverspi mode: 0x0</p><p>inet6 240e:3b7bits per word:3240:c3a0:97de:1d01:b290:fe3a/64 scope global dynamic noprefixroute8</p><p>valid_lft 259183sec preferred_lft 172783secmax speed: 500000 Hz (500 KHz)</p><p>inet6 fe80TX | FF FF FF FF FF FF '''<span style="color::3312:861a:a589:d3c#FF0000">40 00 00 00 00 95</64 scope link noprefixroutespan>''' FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D | ......@.…▒..................▒.</p><p>valid_lft forever preferred_lft foreverRX | FF FF FF FF FF FF '''<span style="color:#FF0000">40 00 00 00 00 95</span>''' FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D | ......@.…▒..................▒.</p>|}</li></ol>
<span id="thepin-methodi2c-of-setting-the-linux-system-to-automatically-connect-to-the-network-for-the-first-timetest"></span>=== The method of setting the Linux system to automatically connect to the network for the first time ===
<ol style="list-style-type: decimal;">
<li><p>First burn the Linux image of the development board you want to use into the TF card, and then use a card reader According to insert the TF card that has burned the Linux image schematic diagram of the development board into a machine with a Linux system (such as a machine with an Ubuntu system installed) computer, the following uses Ubuntu computer as an example to demonstrate)</p></li><li><p>When the TF card is inserted into the Ubuntu computer26pin, the Ubuntu computer will generally automatically mount the partition of the Linux root file system in the TF card. You can know from the following command that '''/media/test/opi_root''' available i2c is the Linux root file in the TF card The path where the system is mountedi2c3</p><p>test@test[[File:~$ '''df zero3-h | grep "media"'''</p><p>/dev/sdd1 1img178.4G 1.2G 167M 88% '''/media/test/opi_root'''</p><p>test@test:~$ '''ls /media/test/opi_root'''</p><p>bin boot dev etc home lib lost+found media mnt opt proc root run sbin selinux srv sys tmp usr varpng]]</p></li><li><p>Then enter the '''/boot''' directory of i2c3 is disabled by default in the Linux system burned in the TF card</p><p>test@test:~$ '''cd /media/test/opi_root/boot/'''</p></li><li><p>Then copy the '''orangepi_first_run.txt.template''' to '''orangepi_first_run.txt'''. Through the orangepi_first_run.txt configuration file, you can set the Linux system on the development board and it needs to automatically connect to a WIFI hotspot when be manually enabled before it starts for the first time, and you can also set the WIFI or Ethernet portbe used. static IP address</p><p>test@test:/media/test/opi_root/boot$ '''sudo cp orangepi_first_run.txt.template orangepi_first_run.txt'''</p></li><li><p>You can The steps to open the orangepi_first_run.txt file with the following command, and then you can view and modify the contents</p><p>test@testare as follows:/media/test/opi_root/boot$ '''sudo vim orangepi_first_run.txt'''</p></li><li><p>Instructions for using variables in the orangepi_first_run.txt file</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First run '''FR_general_delete_this_file_after_completionorangepi-config''' variable is > used to set whether to delete the orangepi_first_run.txt file > after the first startup. The default is 1, that is, delete. If > it is set normal users remember to 0, orangepi_first_run.txt will be renamed to > orangepi_first_run.txt after the first startup .old, generally > keep the default value</p></li><li><p>add '''FR_net_change_defaultssudo''' variable is used to set whether to > change the default network settings, this must be set to 1, > otherwise all network settings will not take effectpermission</p></li><li><p>'''FR_net_ethernet_enabled''' variable is used to control whether > to enable the configuration of the Ethernet port. If you need >{| class="wikitable" style="width:800px; to set the static IP address of the Ethernet port, please set > it to 1</p></li>" <li><p>'''FR_net_wifi_enabled''' variable is used to control whether to > enable WIFI configuration. If you need to set the development > board to automatically connect to WIFI hotspots, you must set > it to 1. In addition, please note that if this variable is set > to 1, the setting of the Ethernet port will be will fail. That > is to say, the WIFI and Ethernet ports cannot be set at the > same time (why, because it is not necessary...)</p></li>|-<li><p>'''FR_net_wifi_ssid''' variable is used to set the name of the > WIFI hotspot you want to connect to</p></li><li><p>'''FR_net_wifi_key''' variable is used to set the password of the > WIFI hotspot you want to connect to</p></li><li><p>'''FR_net_use_static''' variable is used to set whether to set the > static IP address of WIFI or Ethernet port</p></li>| <li><p>orangepi@orangepi:~$ '''FR_net_static_ipsudo orangepi-config''' variable is used to set static IP address, > please set according to your actual situation</p></li><li><p>'''FR_net_static_gateway''' variable is used to set the gateway, > please set it according to your actual situation</p></li></ol>|}
</li>
<li><p>The following demonstrates several specific setting examples:Then select '''System'''</p><ol style="list-style-typep>[[File: lowerzero3-alpha;"img85.png]]</p></li><li><p>For example, if you want the Linux system of the development > board to automatically connect to the WIFI hotspot after the > first startup, you can set it like this:Then select '''Hardware'''</p><ol style="list-style-typep>[[File: lowerzero3-alpha;"img86.png]]</p></li><li><p>Set Then use the arrow keys on the keyboard to navigate to the position shown in the figure below, and then use the '''FR_net_change_defaultsspace''' to select '''1ph-i2c3'''</p><p>[[File:zero3-img179.png]]</p></li><li><p>Set Then select '''FR_net_wifi_enabled<Save>''' to '''1'''save</p><p>[[File:zero3-img88.png]]</p></li><li><p>Set Then select '''FR_net_wifi_ssid<Back>''' to the name of the WIFI hotspot you > want to connect to</p><p>[[File:zero3-img89.png]]</p></li><li><p>Set Then select '''FR_net_wifi_key<Reboot>''' to restart the password of system to make the WIFI hotspot > you want to connect toconfiguration take effect</p><p>[[File:zero3-img90.png]]</p></li></ol>
</li>
<li><p>For example, if you want After starting the Linux linux system of the development > board to automatically connect to the WIFI hotspot after the > , first startup, and set the IP address of the WIFI to a > specific static IP address (so confirm that when the Linux system there is > started, you can directly use the set static IP address to ssh > remotely Log in to the development board without checking the > IP address of the development board through the background of > the router), you can set it like this:an i2c3 device node under /dev</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>Set '''FR_net_change_defaults''' to '''1'''</p></li>|-<li><p>Set '''FR_net_wifi_enabled''' to '''1'''</p></li>| <li><p>Set orangepi@orangepi:~$ '''FR_net_wifi_ssid''' to the name of the WIFI hotspot you > want to connect to<ls /p><dev/li><li><p>Set '''FR_net_wifi_keyi2c-3''' to the password of the WIFI hotspot > you want to connect to</p></li><li><p>Set '''FR_net_use_static''' to '''1'''</p><dev/li><li><p>Set i2c-3'''FR_net_static_ip''' to the desired IP address</p></li><li><p>Set '''FR_net_static_gateway''' to the corresponding gateway > address</p></li></ol>|}
</li>
<li><p>For exampleThen start testing i2c, if you want to automatically set the IP address of > the Ethernet port to the desired static IP address after the > Linux system of the development board starts for the first > time, you can set it like this:install i2c-tools</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>Set '''FR_net_change_defaults''' to '''1'''</p></li>|-<li><p>Set '''FR_net_ethernet_enabled''' to '''1'''</p></li>| <li><p>Set orangepi@orangepi:~$ '''FR_net_use_static''' to '''1sudo apt-get update'''</p></li><li><p>Set orangepi@orangepi:~$ '''FR_net_static_ipsudo apt-get install -y i2c-tools''' to the desired IP address</p></li><li><p>Set '''FR_net_static_gateway''' to the corresponding gateway > address</p></li></ol></li></ol>|}
</li>
<li><p>After modifying the orangepi_first_run.txt file, you can exit Then connect an i2c device to the /boot directory i2c3 pin of the development board Linux system in the TF card, uninstall the TF card, and then insert the TF card into the development board to start26pin connector</p></li>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <libig><p>If you have not set a static IP address, you still need to check '''Please select the IP address through the background of the router5V and 3. If you have set a static IP address, you can ping 3V pins according to the set static IP address on the computer. If you can ping, it means that the system has started normally, and The network has also been set correctlyspecific i2c device, and then you can use the set IP address ssh to remotely log in to the Linux system of the development boardvoltage value required by different i2c devices may be different.'''</p></li></olbig>|}
{| class="wikitable" style="width:800px;" |-| style="text-align: center;"| '''After the Linux system of the development board is started for the first time, orangepi_first_runsda pin'''| style="text-align: center;"| '''Corresponding to pin 3 in 26pin'''|-| style="text-align: center;"| '''sck pin'''| style="text-align: center;"| '''Corresponding to pin 5 in 26pin'''|-| style="text-align: center;"| '''5v pin'''| style="text-align: center;"| '''Corresponding to pin 2 in 26pin'''|-| style="text-align: center;"| '''3.txt will be deleted or renamed 3v pin'''| style="text-align: center;"| '''Corresponding to pin 1 in 26pin'''|-| style="text-align: center;"| '''gnd pin'''| style="text-align: center;"| '''Corresponding to orangepi_first_run.txt.old. At this time, pin 6 in 26pin'''|}</li></ol><ol start="6" style="list-style-type: decimal;"><li><p>Then use the orangepi_first_run.txt configuration file will be reset'''i2cdetect -y 3''' command, and then if the Linux system address of the development board will connected i2c device can be detected, it means that i2c can be restartedused normally</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Different i2c device addresses are different, orangepi_first_run. The configuration the address 0x50 in txt will not take effect again, because this configuration will only be effective when the Linux system figure below is started for the first time after burning, please pay special attention just an example. Please refer to this pointwhat you actually see.'''</p></big>|}<div class="figure">
<span id="sshpin-remoteuart-login-development-board-under-ubuntutest"></span>=== SSH remote login development board under Ubuntu ===
<span id="sshpwm-remotetest-login-development-board-under-windowsmethod"></span>=== SSH remote login development board under Windows ===
[[File:zero3-img183-1.png|center]]|} <ol style="list-style-type: decimal;"><li><p>In the Linux system, the pwm is closed by default, and it needs to be opened manually to use it. The steps to open are as follows:</p><ol style="list-style-type: lower-alpha;"><li><p>First run '''orangepi-config''', normal users remember to add '''sudo''' permission</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo orangepi-config'''</divp>|}</li><li><p>Then select '''System'''</p><p>[[File:zero3-img85.png]]</p></li><li><p>Then select '''Hardware'''</p><p>[[File:zero3-img86.png]]</p></li><li><p>Then use the arrow keys on the keyboard to navigate to the position shown in the figure below, and then use the space to select the configuration corresponding to pwm</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Since the RX and TX pins of UART5 in the PWM1, PWM2 and 26pin interfaces are multiplexed, please make sure that the UART5 configuration is not selected (do not check ph-uart5) when turning on PWM1 and PWM2 (you need to select ph-pwm12).'''</p><p>'''PWM3, PWM4 and the TX and RX pins in the debug serial port are multiplexed, so when using PWM3 and PWM4 (need to select ph-pwm34), please turn off the configuration of UART0 (need to select disable-uart0), after turning off UART0 The debug serial port cannot be used.'''</p></big>|}<p>[[File:zero3-img184.png]]</p></li><li><p>Then select '''<Save>''' to save</p><p>[[File:zero3-img88.png]]</p></li><li><p>Then select '''<Back>'''</p><p>[[File:zero3-img89.png]]</p></li><li><p>Then select '''<Reboot>''' to restart the system to make the configuration take effect</p><p>[[File:zero3-img90.png]]</p></li></ol></li><li><p>After restarting, the PWM test can be started</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Please execute the following commands under the root user.'''</p></big>|}<olstyle="list-style-type: lower-alpha;"><li><p>Enter the following command on the command line to make pwm1 output a 50Hz square wave</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~# '''echo 1 > /sys/class/pwm/pwmchip0/export'''</p><p>root@orangepi:~# '''echo 20000000 > /sys/class/pwm/pwmchip0/pwm1/period'''</p><p>root@orangepi:~# '''echo 1000000 > /sys/class/pwm/pwmchip0/pwm1/duty_cycle'''</p><p>root@orangepi:~# '''echo 1 > /sys/class/pwm/pwmchip0/pwm1/enable'''</p>|}
</li>
<li><p>Then you will be prompted Enter the following command on the command line to enter make pwm2 output a password. The default passwords for root and orangepi users are orangepi50Hz square wave</p><p/li>{| class="wikitable" style="width:800px;" |-| root@orangepi:~# '''Note that when entering the password, the specific content of the entered password will not be displayed on the screen, please do not think that there is any fault, just press Enter after inputting.echo 2 > /sys/class/pwm/pwmchip0/export'''</p><div class="figure">
root@orangepi:~# '''echo 1 > /sys/class/pwm/pwmchip0/pwm2/enable'''|}</ol><span idol start="hdmi3" style="list-style-type: lower-testalpha;"><li>Enter the following command on the command line to make pwm3 output a 50Hz square wave</spanli>{| class="wikitable" style= HDMI test =="width:800px;" |-| root@orangepi:~# '''echo 3 > /sys/class/pwm/pwmchip0/export'''
root@orangepi:~# '''Note that although many laptops have an HDMI interface, echo 1 > /sys/class/pwm/pwmchip0/pwm3/enable'''|}</ol><ol start="4" style="list-style-type: lower-alpha;"><li>Enter the HDMI interface of following command on the notebook generally only has the output function, and does not have the function of HDMI in, that is command line to say, the HDMI make pwm4 output of other devices cannot be displayed on the notebook screen.a 50Hz square wave</li>{| class="wikitable" style="width:800px;" |-| root@orangepi:~# '''echo 4 > /sys/class/pwm/pwmchip0/export'''
root@orangepi:~# '''When you want to connect the HDMI of the development board to the HDMI port of the laptop, please make sure that your laptop supports the HDMI in function.echo 20000000 > /sys/class/pwm/pwmchip0/pwm4/period'''
root@orangepi:~# '''When the HDMI is not displayed, please check whether the HDMI cable is plugged in tightly. After confirming that there is no problem with the connection, you can change a different screen and try to see if it is displayed.echo 1000000 > /sys/class/pwm/pwmchip0/pwm4/duty_cycle'''
<ol stylediv class="list-style-type: decimal;figure"><li><p>First you need to prepare the following accessories</p><ol style="list-style-type: lower-alpha;"><li><p>HDMI to VGA converter</p><p>[[File:media/image145.png|155x104px]]</p></li><li><p>A VGA cable and a Micro HDMI male to HDMI female conversion > cable</p><p>[[File:media/image146.png|148x133px]] [[File:media/image147.jpeg|157x139px|IMG_6140(20220104-134930)]]</p></li><li><p>A monitor or TV that supports VGA interface</p></li></ol></li><li><p>HDMI to VGA display test as shown below</p><p>[[File:media/image148.png|574x336px]]</p><p>'''When using HDMI to VGA display, the development board and the Linux system of the development board do not need to make any settings, only the Micro HDMI interface of the development board can display normally. So if there is a problem with the test, please check whether there is a problem with the HDMI to VGA converter, VGA cable and monitor.'''</p></li></ol>
{| class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
| style="text-align: left;"| '''Supported values for disp_mode'''| style="text-align: left;"| '''HDMI resolution'''| style="text-align: left;"| '''HDMI refresh rate'''|-| style="text-align: left;"| '''480i'''| style="text-align: left;"| '''720x480'''| style="text-align: left;"| '''60'''|-| style="text-align: left;"| '''576i'''| style="text-align: left;"| '''720x480'''| style="text-align: left;"| '''50'''|-| style="text-align: left;"| '''480p'''| style="text-align: left;"| '''720x480'''| style="text-align: left;"| '''60'''|-| style="text-align: left;"| '''576p'''| style="text-align: left;"| '''720x576'''| style="text-align: left;"| '''60'''|-| style="text-align: left;"| '''720p50'''| style="text-align: left;"| '''1280x720'''| style="text-align: left;"| '''50'''|-| style="text-align: left;"| '''720p60'''| style="text-align: left;"| '''1280x720'''| style="text-align: left;"| '''60'''|-| style="text-align: left;"| '''1080i50'''| style="text-align: left;"| '''1920x1080'''| style="text-align: left;"| '''50'''|-| style="text-align: left;"| '''1080i60'''| style="text-align: left;"| '''1920x1080'''| style="text-align: left;"| <big>'''60'''|-| style="textwiringOP-align: left;"| '''1080p24Python is the Python language version of wiringOP, which is used to operate the hardware resources of the development board, such as GPIO, I2C, SPI and UART, in the Python program.'''| style="text-align: left;"| '''1920x1080'''| style="text-align: left;"| '''24'''|-| In addition, please note that all the following commands are operated under the <span style="text-aligncolor: left;"| '''1080p50'''| style=#FF0000"text-align: left;"| '''1920x1080'''| style="text-align: left;"| '''50'''|-| style="text-align: left;"| '''1080p60'''| style="text-align: left;"| '''1920x1080'''| style="text-align: left;"| '''60>root</span> user.'''</big>
|}
<ol start="3" style="list-style-type: decimal;"><li><p>Change the value of the disp_mode variable to the desired output resolution, and then restart First install the system, HDMI will output the set resolutiondependency package</p></li><li>{| class="wikitable" style="width:800px;" |-| <p>The method of viewing the HDMI output resolution is as follows. If the displayed resolution is the same as the set resolution, it means that the setting of the development board is correct.root@orangepi:~# '''sudo apt-get update'''</p><p>orangepiroot@orangepi:~$ # '''sudo cat /sys/class/disp/disp/attr/sysapt-get -y install git swig python3-dev python3-setuptools'''</p>|}</li><li><p>[[FileThen use the following command to download the source code of wiringOP-Python</p>{| class="wikitable" style="background-color:#ffffdc;width:media/image149.png800px;" |-|575x84px]]</pbig></lip>'''Note that the following git clone --recursive command will automatically download the source code of wiringOP, because wiringOP-Python depends on wiringOP. Please make sure that the download process does not report errors due to network problems.'''</olp>
<p>'''NoteIf you have problems downloading the code from GitHub, you can directly use the wiringOP-Python source code that comes with the Linux image, and the storage location is: /usr/src/wiringOP-Python'''</p></big>|}{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~# '''git clone --recursive https://github.com/orangepi-xunlong/wiringOP-Python -b next'''</p><p>root@orangepi:~# '''cd wiringOP-Python'''</p><p>root@orangepi: This method is only applicable ~/wiringOP-Python# '''git submodule update --init --remote'''</p>|}</li><li><p>Then use the following command to systems with linux5compile wiringOP-Python and install it into the Linux system of the development board</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~# '''cd wiringOP-Python'''</p><p>root@orangepi:~/wiringOP-Python# '''python3 generate-bindings.py > bindings.4 kerneli'''</p><p>root@orangepi:~/wiringOP-Python# '''sudo python3 setup.py install'''</p>|}</li><li><p>Then enter the following command, if there is help information output, it means that wiringOP-Python is installed successfully, press the '''q''' key to exit the help information interface</p></li>
: # the SWIG interface file instead.|}</ol ><ol start="5" style="list-style-type: decimal;"><li><p>The softcursor used by Framebuffer, the method of setting the cursor steps to blink or not test whether wiringOP-Python is successfully installed under the python command line are as follows</p><p>root@orangepi:~# '''echo 1 > /sys/class/graphics/fbcon/cursor_blink #cursor blinking'''</p><p>root@orangepiol style="list-style-type:~# '''echo 0 >lower-alpha; /sys/class/graphics/fbcon/cursor_blink #cursor not blinking'''</p></li"><li><p>If you need First use the python3 command to hide enter the cursor, you can add '''vt.global_cursor_default=0''' in the '''extraargs''' variable command line mode of '''/boot/orangepiEnv.txt''' (the value of extraargs will be assigned to the '''bootargs''' environment variable and finally passed to the kernel) (if '''vt.global_cursor_default=1''', the cursor will be displayed) , and then restart the system to see that the cursor has disappearedpython3</pli><p>orangepi@orangepi:~$ '''sudo vim /boot/orangepiEnv.txt'''</p><p>verbosity{| class=1</p><p>console"wikitable" style=both</p>"width:800px;" <p>disp_mode=1080p60</p>|-<p>fb0_width=1920</p>| <p>fb0_height=1080</p><p>root@orangepi:~# '''extraargs=vt.global_cursor_default=0python3'''</p></li></ol>|}
<span idol start="how2" style="list-tostyle-usetype: lower-bluetoothalpha;"><li>Then import the python module of wiringpi</li></spanol>== How to use Bluetooth ==
{| class="wikitable" style="width:800px;" |-| >>> '''import wiringpi;'''|}<span id/ol><ol start="test3" style="list-methodstyle-oftype: lower-desktop-image-1alpha;"><li>Finally, enter the following command to view the help information of wiringOP-Python, and press the q key to exit the help information interface</spanli>=== Test method of desktop image ===
>>>|}</divol></li></ol><span id="pin-gpio-port-test-1"></span>
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''The USB interface wiringOP-Python is the same as wiringOP, you can be connected also determine which GPIO pin to a USB hub operate by specifying the wPi number, because there is no command to expand check the wPi number of USB interfacesin wiringOP-Python, so you can only check the board wPi number and physical Correspondence between pins.'''</big>[[File:zero3-img172.png]]|}
|-
| <p>root@orangepi:~/wiringOP-Python# '''python3 -c "import wiringpi; \'''</p><p>'''from wiringpi import GPIO; wiringpi.wiringPiSetup() ; \'''</p><p>'''wiringpi.pinMode(<span style="text-aligncolor: left#FF0000">2, GPIO.OUTPUT</span>) ;""'''</p>| serial number}</li><li><p>Then set the GPIO port to output low level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is 0v, it means that the low level is set successfully.</p>{| class="wikitable" style="text-alignwidth: left800px;"| model
|-
| <p>root@orangepi:~/wiringOP-Python# '''python3 -c "import wiringpi; \'''</p><p>'''from wiringpi import GPIO; wiringpi.wiringPiSetup() ;\'''</p><p>'''wiringpi.digitalWrite(2, <span style="text-aligncolor: left#FF0000">GPIO.LOW</span>)""'''</p>| 1}</li><li><p>Then set the GPIO port to output a high level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is 3.3v, it means that the high level is set successfully.</p>{| class="wikitable" style="text-alignwidth: left800px;"| RTL8152B USB 100M network card
|-
| style="text<p>root@orangepi:~/wiringOP-Python# '''python3 -align: leftc "import wiringpi; \'''</p><p>'''from wiringpi import GPIO; wiringpi.wiringPiSetup() ;"| \'''</p><p>'''wiringpi.digitalWrite(2| , <span style="text-aligncolor: left#FF0000">GPIO.HIGH</span>)""| RTL8153 USB Gigabit LAN'''</p>
|}
</li></ol>
</li>
<li><p>The steps to test in the command line of python3 are as follows:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First use the python3 command to enter the command line mode of python3</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>root@orangepi:~# '''python3'''</p>
|}
</li>
<li><p>Then import the python module of wiringpi</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>>>> '''import wiringpi'''</p>
<p>>>> '''from wiringpi import GPIO'''</p>
|}
</li>
<li><p>Then set the GPIO port to output mode, where the first parameter of the '''pinMode''' function is the serial number of the wPi corresponding to the pin, and the second parameter is the GPIO mode</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>>>> '''wiringpi.wiringPiSetup()'''</p>
<p>0</p>
<p>>>> '''wiringpi.pinMode(<span style="color:#FF0000">2, GPIO.OUTPUT</span>)'''</p>
|}
</li>
<li><p>Then set the GPIO port to output low level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is 0v, it means that the low level is set successfully.</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>>>> '''wiringpi.digitalWrite(2, <span style="color:#FF0000">GPIO.LOW</span>)'''</p>
|}
</li>
<li><p>Then set the GPIO port to output a high level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is 3.3v, it means that the high level is set successfully.</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>>>> '''wiringpi.digitalWrite(2, <span style="color:#FF0000">GPIO.HIGH</span>)'''</p>
|}
</li></ol>
</li>
<li><p>The method of wiringOP-Python to set GPIO high and low levels in python code can refer to the '''blink.py''' test program in the examples below. The '''blink.py''' test program will set the voltage of all GPIO ports in the 26 pins of the development board to change continuously.</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>root@orangepi:~/wiringOP-Python# '''cd examples'''</p>
<p>root@orangepi:~/wiringOP-Python/examples# '''ls blink.py'''</p>
<p>'''blink.py'''</p>
<p>root@orangepi:~/wiringOP-Python/examples'''# python3 blink.py'''</p>
|}
</li></ol>
<span id="pin-spi-test-1"></span>
=== 26pin SPI test ===
<ol start="2" style="list-style-type: decimal;"><li><p>First insert According to the USB network card into schematic diagram of the USB 26pin interface of the development board, and then insert the network cable into the USB network card to ensure that the network cable can access the Internet normally. If you can see the following log information through the '''dmesg''' command, it means that the USB network card available spi is recognized normally.</p><p>orangepi@orangepi:~$ '''dmesg | tail'''spi1</p><p>[ 121.985016] usb 3-1: USB disconnect, device number 2</p><p>[ 126.873772] sunxi-ehci 5311000.ehci3-controller: ehci_irq: highspeed device connect</p><p>[ 127.094054] usb 3-1File: new highzero3-speed USB device number 3 using sunxi-ehci</p><p>[ 127img176.357472png] usb 3-1: reset high-speed USB device number 3 using sunxi-ehci</p><p>[ 127.557960] r8152 3-1:1.0 eth1: v1.08.9</p><p>[ 127.602642] r8152 3-1:1.0 enx00e04c362017: renamed from eth1</p><p>[ 127.731874] IPv6: ADDRCONF(NETDEV_UP): enx00e04c362017: link is not ready</p><p>[ 127.763031] IPv6: ADDRCONF(NETDEV_UP): enx00e04c362017: link is not ready</p><p>[ 129.892465] r8152 3-1:1.0 enx00e04c362017: carrier on</p><p>[ 129.892583] IPv6: ADDRCONF(NETDEV_CHANGE): enx00e04c362017: link becomes ready</p></li><li><p>Then you can see The spi1 is disabled by default in the device node of the USB network card Linux system and the automatically assigned IP address through the ifconfig command</p><p>orangepi@orangepi:~$ '''sudo ifconfig'''</p><p>'''enx00e04c362017''': flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500</p><p>inet '''192.168.1.177''' netmask 255.255.255.0 broadcast 192.168.1.255</p><p>inet6 fe80::681f:d293:4bc5:e9fd prefixlen 64 scopeid 0x20<link></p><p>ether 00:e0:4c:36:20:17 txqueuelen 1000 (Ethernet)</p><p>RX packets 1849 bytes 134590 (134.5 KB)</p><p>RX errors 0 dropped 125 overruns 0 frame 0</p><p>TX packets 33 bytes 2834 (2needs to be manually enabled before it can be used.8 KB)</p><p>TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0</p></li><li><p>The command steps to test network connectivity is open are as follows</p><p>orangepi@orangepi:~$ '''ping www.baidu.com -I enx00e04c362017'''</p><p>PING www.a.shifen.com (14.215.177.38) from 192.168.1.12 eth0: 56(84) bytes of data.</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=1 ttl=56 time=6.74 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=2 ttl=56 time=6.80 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=3 ttl=56 time=6.26 ms</p><p>64 bytes from 14.215.177.38 (14.215.177.38): icmp_seq=4 ttl=56 time=7.27 ms</p><p>^C</p><p>--- www.a.shifen.com ping statistics ---</p><p>4 packets transmitted, 4 received, 0% packet loss, time 3002ms</p><p>rtt min/avg/max/mdev = 6.260/6.770/7.275/0.373 ms</p></li></ol> <span id="usb-camera-test"></span>=== USB camera test === <ol style="list-style-type: decimal;"><li><p>First insert the USB camera into the USB port of the Orange Pi development board</p></li><li><p>Then through the lsmod command, you can see that the kernel has automatically loaded the following modules</p><p>orangepi@orangepi:~$ '''lsmod'''</p><p>Module Size Used by</p><p>'''uvcvideo 106496 0'''</p></li><li><p>3) Through the v4l2-ctl command, you can see that the device node information of the USB camera is /dev/video0</p><p>orangepi@orangepi:~$ '''sudo apt update'''</p><p>orangepi@orangepi:~$ '''sudo''' '''apt install -y v4l-utils'''</p><p>orangepi@orangepi:~$ '''v4l2-ctl --list-devices'''</p><p>USB 2.0 Camera (usb-sunxi-ehci-1):</p><p>/dev/video0</p><p>'''Note that the l in v4l2 is a lowercase letter l, not the number 1.'''</p><p>'''In addition, the serial number of the video is not necessarily video0, please refer to what you actually see.'''</p></li><li><p>Use fswebcam to test the USB camera</p>
<ol style="list-style-type: lower-alpha;">
<li><p>Install fswebcam</p><p>orangepi@orangepi:~$ First run '''sudoorangepi-config''' '''apt update'''</p><p>orangepi@orangepi:~$ , normal users remember to add '''sudo apt-get install -y fswebcam'''</p></li><li><p>After installing fswebcam, you can use the following command to > take picturespermission</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>|-d option is used to specify the device node of the USB > camera</p></li><li><p>--no-banner is used to remove the watermark of the photo</p></li><li><p>-r option is used to specify the resolution of the photo</p></li><li><p>-S option is used to set the number of previous frames to > skip</p></li><li><p>./image.jpg is used to set the name and path of the > generated photo</p>| <p>orangepi@orangepi:~$ '''sudo''' '''fswebcam orangepi-d /dev/video0 \config'''</p><p>'''--no-banner -r 1280x720 -S 5 ./image.jpg'''</p></li></ol>|}
</li>
<li><p>In Then select '''System'''</p><p>[[File:zero3-img85.png]]</p></li><li><p>Then select '''Hardware'''</p><p>[[File:zero3-img86.png]]</p></li><li><p>Then use the server version of arrow keys on the linux systemkeyboard to navigate to the position shown in the figure below, you can and then use the scp '''space''' to select '''spi1-cs1-spidev'''</p><p>[[File:zero3-img177.png]]</p></li><li><p>Then select '''>lt; command to transfer the taken pictures to the Ubuntu PC for Save> mirror viewing after taking pictures''' to save</p><p>orangepi@orangepi[[File:~$ zero3-img88.png]]</p></li><li><p>Then select '''<Back>'''然后选择'''<Back>''scp image.jpg '</p><p>[[mailtoFile:test@192zero3-img89.168.1.55:/home/test test@192.168.1.55:/home/testpng]] (Modify the IP address and path according to the actual situation)'''</p></li><li><p>In the desktop version of the linux system, you can directly Then select '''<Reboot> view ''' to restart the captured pictures through system to make the HDMI displayconfiguration take effect</p><p>[[File:zero3-img90.png]]</p></li></ol>
</li>
<li><p>Use mjpgThen check whether there is a '''spidev1.1''' device node in the Linux system. If it exists, it means that the configuration of SPI1 has taken effect</p>{| class="wikitable" style="width:800px;" |-streamer | <p>orangepi@orangepi:~$ '''ls /dev/spidev1*'''</p><p>/dev/spidev1.1</p>|}</li><li><p>Then you can use the '''spidev_test.py''' program in the examples to test USB camerathe loopback function of the SPI. The '''spidev_test.py''' program needs to specify the following two parameters:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>Download mjpg-streamer</p><ol style="list-style-type: lower-alpha;"><li><p>Github download address:</p><p>orangepi@orangepi:~$ '''git clone https://github.com/jacksonliam/mjpg-streamer-channel''': Specify the channel number of SPI</p></li><li><p>The image download address of Gitee is:</p><p>orangepi@orangepi:~$ '''git clone https://gitee.com/leeboby/mjpg-streamer-port''': Specify the port number of SPI</p></li></ol>
</li>
<li><p>Install dependent packages</p><ol style="list-style-type: lower-alpha;"><li><p>Ubuntu system</p><p>orangepi@orangepi:~$ '''sudo apt-get install -y cmake libjpeg8-dev'''</p></li><li><p>Debian system</p><p>orangepi@orangepi:~$ '''sudo aptDo not short-get install -y cmake libjpeg62-turbo-dev'''circuit the mosi and miso pins of SPI1, the output result of running spidev_test.py is as follows, you can see that the data of TX and RX are inconsistent</p></li></ol>
</li>
TX | FF FF FF FF FF FF '''<ol span style="list-style-typecolor: decimal;#FF0000"><li><p>First, you need to insert the 13pin expansion board into the 13pin interface of the Orange Pi development board, and then insert the earphone into the audio interface40 00 00 00 00 95</p><div class="figure"span>''' FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D |......@.......…|
root@orangepi:~/wiringOP-Python/examples# '''If there is noise in the earphone test, please pull out some earphones, do not insert all the earphonespython3 spidev_test.py \'''
RX | FF FF FF FF FF FF '''</divspan style="color:#FF0000">40 00 00 00 00 95</lispan><li><p>Then select the audio''' FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF F0 0D |......@.......wav file, right click and select open with vlc to start playing</p>…|<p>[[File:media/image166.png|241x195px]]</p></li>}<li><p>How to switch between different audio devices such as HDMI playback and headphone playback</pol><ol stylespan id="listpin-stylei2c-type: lowertest-alpha;1"><li><p>First open the volume control interface</p><p>[[File:media/image167.png|294x161px]]</p></li><li><p>When playing audio, the audio device options that the playback > software can use will be displayed in '''Playback''', as shown > in the figure below, where you can set which audio device to > play to</p><div class="figure"span>
<ol style="list-style-type: decimal;">
<li><p>According to the schematic diagram of 26pin, the available i2c is i2c3</p><p>[[File:zero3-img178.png]]</p></li><li><p>i2c3 is disabled by default in the Linux system, and it needs to be manually enabled before it can be used. The steps to open are as follows:</p><ol style="list-style-type: lower-alpha;"><li><p>Firstrun '''orangepi-config''', you need normal users remember to add '''sudo''' permission</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo orangepi-config'''</p>|}</li><li><p>Then select '''System'''</p><p>[[File:zero3-img85.png]]</p></li><li><p>Then select '''Hardware'''</p><p>[[File:zero3-img86.png]]</p></li><li><p>Then use the arrow keys on the keyboard to navigate to insert the 13pin expansion board into position shown in the figure below, and then use the '''space''' to select '''ph-i2c3'''</p><p>[[File:zero3-img179.png]]</p></li><li><p>Then select '''<Save>''' to save</p><p>[[File:zero3-img88.png]]</p></li><li><p>Then select '''<Back>'''</p><p>[[File:zero3-img89.png]]</p></li><li><p>Then select '''<Reboot>''' to restart the 13pin interface of system to make the Orange Pi development boardconfiguration take effect</p><p>[[File:zero3-img90. png]]</p></li></ol></li><li><p>After inserting starting the expansion boardlinux system, the development board can use the infrared receiving functionfirst confirm that there is an i2c3 device node under /dev</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''ls /dev/i2c-3'''</p><p>'''/dev/i2c-3'''</p>|}</li><li><div p>Then start testing i2c, first install i2c-tools</p>{| class="figurewikitable" style="width:800px;"|-| <p>orangepi@orangepi:~$ '''sudo apt-get update'''</p><p>orangepi@orangepi:~$ '''sudo''' '''apt-get install -y i2c-tools'''</p>|}</li><li><p>Then connect an i2c device to the i2c3 pin of the 26pin connector, here we take the DS1307 RTC module as an example</p><p>[[File:zero3-img186.png]]</p>
[[File:zero3-img187.png]]</ol><ol start="7" style="list-style-type: decimal;"><li><p>Then you can run the '''ds1307.py''' test program in the '''examples''' to read the RTC time</p>{| class="wikitable" style="width:800px;" |-| <p>root@orangepi:~/wiringOP-Python# '''cd examples'''</p><p>root@orangepi:~/wiringOP-Python/examples# '''python3 ds1307.py --device \'''</p><p>'''"/dev/i2c-3"'''</divp><p>Thu 2022-06-16 04:35:46</lip><lip>Thu 2022-06-16 04:35:47</p><p>Install irThu 2022-keytable infrared testing software06-16 04:35:48</p><p>^C</p><p>exit</p>|}</li></ol>
<ol start="3" style="list-style-type: decimal;"><li><p>Then execute ir-keytable According to view the information schematic diagram of the infrared device26pin interface, the available uart is uart5</p><p>[[File:zero3-img181.png]]</p></li><li><p>uart5 is disabled by default in the Linux system, and it needs to be opened manually to use it. The steps to open are as follows:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First run '''orangepi-config''', normal users remember to add '''sudo''' permission</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo orangepi-config'''</p>|}</li><li><p>Then select '''System'''</p><p>[[File:zero3-img85.png]]</p></li><li><p>Then select '''Hardware'''</p><p>[[File:zero3-img86.png]]</p></li><li><p>Then use the arrow keys on the keyboard to navigate to the position shown in the figure below, and then use the '''space''' to select '''ph-uart5'''</p><p>[[File:zero3-img182.png]]</p></li><li><p>Then select '''<Save>''' to save</p><p>[[File:zero3-img88.png]]</p></li><li><p>Then select '''<Back>'''</p><p>[[File:zero3-img89.png]]</p></li><li><p>Then select '''<Reboot>''' to restart the system to make the configuration take effect</p><p>[[File:zero3-img90.png]]</p></li></ol></li><li><p>After entering the linux system, first confirm whether there is a uart5 device node under '''/dev'''</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Note that the linux5.4 system output is as follows/dev/ttyAS5.'''</p></big>|}{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''ls /dev/ttyS5'''</p><p>/dev/ttyS5</p>|}</li><li><p>Then start to test the uart5 interface, first use the DuPont line to short the rx and tx of the uart5 interface to be tested</p> {| class="wikitable" style="width:800px;text-align: center;"|-|| style="text-align: center;"| '''uart5'''|-| '''tx pin'''| style="text-align: center;"| '''Corresponding to pin 8 in 26pin'''|-| '''rx pin'''| style="text-align: center;"| '''Corresponding to pin 10 in 26pin'''|}</li></ol><ol start="5" style="list-style-type: decimal;"><li><p>Finally, you can run the '''serialTest.py''' program in the examples to test the loopback function of the serial port. If you can see the following print, it means that the loopback test of the serial port is normal</p>{| class="wikitable" style="width:800px;text-align: center;" |-| <p>root@orangepi:~/wiringOP-Python# '''cd examples'''</p><p>root@orangepi:~/wiringOP-Python/examples# '''python3 serialTest.py --device "/dev/ttyS5" # linux6.1使用'''</p><p>root@orangepi:~/wiringOP-Python/examples# '''python3 serialTest.py --device "/dev/ttyAS5" # linux5.4使用'''</p><p>Out: 0: -> 0</p><p>Out: 1: -> 1</p><p>Out: 2: -> 2</p><p>Out: 3: -> 3</p><p>Out: 4:^C</p><p>exit</p>|}
</li></ol>
<!-- --><ol start="4" stylespan id="listpython-stylerelated-type: decimal;instructions"><li><p>Before testing the infrared receiving function, you need to prepare an infrared remote controller dedicated to Orange Pi, '''other remote controllers do not support it'''</p><div class="figure"span>
</div></li><li><p>Then enter the '''irspan id="python-keytable source-t''' command in the terminal, and then use the infrared remote control to press the button against the infrared receiver of the Orange Pi development board to see the received key code in the terminal</p><ol style="list-stylecompilation-and-type: lowerinstallation-alpha;method"><li>linux5.4 system output is as follows</li></olspan></li></ol>=== Python source code compilation and installation method ===
<ol startstyle="list-style-type: decimal;"><li><p>First install '''python3-pip'''</p>{| class="2wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo apt-get update'''</p><p>orangepi@orangepi:~$ '''sudo apt-get install -y python3-pip'''</p>|}</li><li><p>Method of permanent replacement of pip source under Linux</p><ol style="list-style-type: lower-alpha;"><li><p>linux6Create a new'''~/.1 system output is pip''' directory first, then add the '''pip.conf''' configuration file, and set the source of the pip as followsTsinghua source</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo ir-keytable -c mkdir -p NEC -t~/.pip'''</p><p>orangepi@orangepi:~$ '''cat <<EOF > ~/.pip/pip.conf'''</p><p>Old keytable cleared'''[global]'''</p><p>Protocols changed to nec'''timeout = 6000'''</p><p>Testing events'''index-url = https://pypi. Please, press CTRLtuna.tsinghua.edu.cn/simple'''</p><p>'''trusted-C to aborthost = pypi.tuna.tsinghua.edu.cn'''</p><p>202.063219: lirc protocol(nec): scancode = 0x45c'''EOF'''</p>|}</li><li><p>Then install the Python library with pip3, it will be fast</p></li></ol></li><li><p>The method of temporarily replacing the pip source under Linux, the '''<packagename>''' needs to be replaced with a specific package name</p>202.063249{| class="wikitable" style="width: event type EV_MSC(0x04)800px;" |-| <p>orangepi@orangepi: scancode = 0x45c~$ '''pip3 install <packagename> -i \'''</p><p>202'''https://pypi.tuna.tsinghua.edu.cn/simple --trusted-host pypi.063249: event type EV_SYN(0x00)tuna.tsinghua.edu.cn'''</p>|}</li></ol>
<span id="temperaturethe-sensormethod-of-installing-the-docker"></span>== Temperature sensor ==
Orange Pi's Linux image has been pre-installed with Docker, but the Docker service has not been opened by default. Use '''enable_docker.sh'The displayed temperature value needs '' script to enable the docker service, and then you can start using the docker command, and the docker service will be divided by 1000, automatically activated at the next start of the unit is Celsiussystem.'''
{| class="wikitable" style="width:800px;" |-| orangepi@orangepi:~$ '''cpudocker run hello-world'''_thermal_zone
<ol style="list-style-type: decimal;">
<li><p>Please First of all, please install docker and make sure that docker can run normally. The Method Of Installing The Docker, please refer to the figure below for the order of the interface pins of instructions in the 13 pin expansion board section on the development board</p><div class="figure"> [[File:media/image170.jpeg|245x133px|C:\Users\orangepi\Desktop\用户手册插图\Zero3\未标题-Orange Pi Zero 3.jpg未标题-3]] </div></li><li><p>#The Method Of Installing The schematic diagram of the 13pin interface of the development board is as follows</p><p>[[File:media/image19.pngDocker|359x193px'''how to install Docker''']].</p></li><li><p>The function description of Then you can search for the 13 pin expansion board interface pins docker image of the development board is as followsHome Assistant</p><ol style{| class="list-style-type: lower-alpha;wikitable"><li><p>When the 13pin pin is connected to the expansion board, it can > be provided additionally</p><ol style="list-style-typewidth: lower-alpha800px;"><li><p>2个USB 2.0 Host</p></li><li><p>Audio output of the left and right audio channels of the > earphones</p></li><li><p>TV|-OUT video output</p></li><li><p>Infrared receiving function</p></li>| <li><p>After the expansion board is connected, pins 10, 11 and 12 > of the 13pin interface cannot be used</p></li><li><p>orangepi@orangepi:~$ '''In addition, it should be noted that the MIC on the 13pin expansion board cannot be used on the Orange Pi Zero 3docker search homeassistant'''</p></li></ol>|}
</li>
<li><p>When pin 13 is not connected Then use the following command to download the docker image of Home Assistant to the expansion board, pins 10local. The size of the image is about 1GB, > 11, 12 and 13 can the download time will be used as ordinary GPIO portsrelatively long. Please wait patiently for the download to complete</p></li></ol></li></ol> {| class="wikitable" style="width:800px;"
|-
| style="text-align<p>orangepi@orangepi: left;"| ~$ '''GPIO serial numberdocker pull homeassistant/home-assistant'''</p><p>Using default tag: latest</p>| style="text<p>latest: Pulling from homeassistant/home-alignassistant</p><p>be307f383ecc: left;"| Downloading</p><p>5fbc4c07ac88: Download complete</p><p>'''Function...... (omit some output)'''</p><p>3cc6a1510c9f: Pull complete</p><p>7a4e4d5b979f: Pull complete</p><p>Digest: sha256:81d381f5008c082a37da97d8b08dd8b358dae7ecf49e62ce3ef1eeaefc4381bb</p><p>Status: Downloaded newer image for homeassistant/home-assistant:latest</p><p>docker.io/homeassistant/home-assistant:latest</p>|}</li><li><p>Then you can use the following command to view the docker image of Home Assistant just downloaded</p>{| class="wikitable" style="text-alignwidth: left800px;"| '''Pin'''
|-
| style="text<p>orangepi@orangepi:~$ '''docker images homeassistant/home-align: leftassistant'''</p><p>REPOSITORY TAG IMAGE ID CREATED "|SIZE</p>| <p>homeassistant/home-assistant latest bfa0ab9e1cf5 2 months ago '''<span style="text-aligncolor: left;#FF0000"| '''5V>1.17GB</span>'''</p>|}</li><li><p>Now you can run the docker container of Home Assistant</p>{| class="wikitable" style="text-alignwidth: left800px;"| '''1'''
|-
| style<p>orangepi@orangepi:~$ '''docker run -d \'''</p>:<p>'''--name homeassistant \'''</p>:<p>'''--privileged \'''</p>:<p>'''--restart=unless-stopped \'''</p>:<p>'''-e TZ="textAsia/Shanghai \'''</p>:<p>'''-v /home/orangepi/home-alignassistant: left;"|/config \'''</p>| style:<p>'''--network="text-alignhost \'''</p>: left;"| <p>'''GNDhomeassistant/home-assistant:latest'''</p>|}</li><li><p>Then enter【IP address of the development board: 8123】in the browser to see the Home Assistant interface</p>{| class="wikitable" style="textbackground-aligncolor:#ffffdc;width: left800px;"| '''2'''
|-
| <big><p>'''It takes a while for the Home Assistant container to start. If the following interface is not displayed normally, please wait for a few seconds and then refresh. If the following interface is not displayed normally after waiting for more than one minute, it means that there is a problem with the installation of Home Assistant. At this time, you need to check whether there is a problem with the previous installation and setting process.'''</p></big>|}<p>[[File:zero3-img188-1.png]]</p></li><li><p>Then enter '''your name''', '''user name''' and '''password''' and click '''Create Account'''</p><p>[[File:zero3-img189-1.png]]</p></li><li><p>Then follow the interface prompts to set according to your preferences, and then click Next</p><p>[[File:zero3-img190-1.png]]</p></li><li><p>Then click Next</p><p>[[File:zero3-img191-1.png]]</p></li><li><p>Then click Finish</p><p>[[File:zero3-img192-1.png]]</p></li><li><p>The final main interface displayed by Home Assistant is shown in the figure below</p><p>[[File:zero3-img193-1.png]]</p></li><li><p>How to stop the Home Assistant container</p><ol style="textlist-alignstyle-type: leftlower-alpha;"|><li><p>The command to view the docker container is as follows</p>{| styleclass="text-align: left;wikitable"| '''USB2-DM'''| style="text-alignwidth: left800px;"| '''3'''
|-
|-
|-
| style="text-align: left;"|| style="text-align: left;"| '''USB3-DP'''| style="text-align: left;"| '''6'''|-| style="text-align: left;"|| style="text-align: left;"| '''LINEOUTR'''| style="text-align: left;"| '''7'''|-| style="text-align: left;"|| style="text-align: left;"| '''LINEOUTL'''| style="text-align: left;"| '''8'''|-| style="text-align: left;"|| style="text-align: left;"| '''TV-OUT'''| style="text-align: left;"| '''9'''|-| style="text-align: left;"| '''65'''| style="text-align: left;"| '''PC1'''| style="text-align: left;"| '''10'''|-| style="text-align: left;"| '''272'''| style="text-align<p>orangepi@orangepi: left;"| ~$ '''PI16docker rm homeassistant'''| style="text-align: left;"| '''11'''|-| style="text-align: left;"| '''262'''| style="text-align: left;"| '''PI6'''| style="text-align: left;"| '''12'''|-| style="text-align: left;"| '''234'''| style="text-align: left;"| '''IR-RX</PH10'''| style="text-align: left;"| '''13'''p>
|}
</li></ol>
</li></ol>
<span id="pininstall-interfacevia-pin-descriptionpython"></span>== 26 Pin Interface Pin Description ==
{| class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
| style="text-align: left;"| ''<big>'GPIO S/N'''| style="text-align: left;"Before installation, please replace the source of pip with a domestic source to speed up the installation of the Python package. For the configuration method, see the instructions in the section on [[Orange Pi Zero 3#Python to replace the pip source method| '''GPIOhow to replace the pip source with Python'''| style="text-align: left;"| '''Function]].'''</big>| style="text-align: left;"| '''Pin'''}|| <ol style="textlist-align: left;"| '''Pin'''| style="text-aligntype: leftdecimal;"| '''Function'''><li><p>First install the dependency package</p>{| styleclass="text-align: left;wikitable"| '''GPIO'''| style="text-alignwidth: left800px;"| '''GPIO S/N'''
|-
|-
| style="text-align: left;"| <big><p>'''229If it is debian12, please use the following command:'''</p></big>| style="text-align <p>orangepi@orangepi: left;"| ~$ '''PH5sudo apt-get update'''</p>| style="text-align<p>orangepi@orangepi: left;"| ~$ '''TWI3sudo apt-get install -y python3 python3-dev python3-SDAvenv \'''</p>| style="text-align: left;"| <p>'''3python3-pip libffi-dev libssl-dev libjpeg-dev zlib1g-dev autoconf build-essential \'''</p>|| style="text-align: left;"| <p>'''4libopenjp2-7 libturbojpeg0-dev tzdata'''</p>| style="text-align: left;"}</li><li><p>Then you need to compile and install Python3.9. For the method, please refer to the section on [[Orange Pi Zero 3#Python source code compilation and installation method| '''5Vhow to compile and install Python source code''']]</p>{| styleclass="text-align: left;wikitable"|| style="textbackground-aligncolor: left#ffffdc;width:800px;"|
|-
| style="text-align: left;"| <big><p>'''228The default Python version of Debian Bullseye is Python3.9, so there is no need to compile and install.'''</p>| style="text-align: left;"| <p>'''PH4The default Python version of Ubuntu Jammy is Python3.10, so there is no need to compile and install.'''</p>| style="text-align: left;"| <p>'''TWI3-SCKThe default Python version of Debian Bookworm is Python3.11, so there is no need to compile and install.'''</p></big>| style="text-align: left;"| '''5'''}|</li>| style="text-align: left;"| '''6'''<li><p>Then create a Python virtual environment</p>{| styleclass="text-align: left;wikitable"| '''GND'''| style="textbackground-aligncolor: left#ffffdc;"|| style="text-alignwidth: left800px;"|
|-
|-
| style="text-align: left;"|| style="text-align: left;"|| style="text-align: left;"| '''GND'''| style="text-align<p>orangepi@orangepi: left;"| ~$ '''9sudo mkdir /srv/homeassistant'''</p>|| style="text-align<p>orangepi@orangepi: left;"| ''~$ '10'''| style="text-alignsudo chown orangepi: left;"| '''UART5_RXorangepi /srv/homeassistant'''</p>| style="text-align<p>orangepi@orangepi: left;"| ~$ '''PH3cd /srv/homeassistant'''</p>| style="text-align<p>orangepi@orangepi: left;"| ~$ '''227'''|-| style="text-align: left;"| '''70'''| style="textpython3.9 -align: left;"| '''PC6m venv .'''</p>| style="text-align<p>orangepi@orangepi: left;"| ~$ '''PC6source bin/activate'''</p>| style="text-align<p>(homeassistant) orangepi@orangepi: left;"| '''11'''/srv/homeassistant$</p>|}| style="text-align: left;"| '''12'''</li>| style="text-align: left;"| '''PC11'''<li><p>Then install the required Python package</p>{| styleclass="text-align: left;wikitable"| '''PC11'''| style="text-alignwidth: left800px;"| '''75'''
|-
| style="text-align: left;"| '''69'''| style="text-align: left;"| '''PC5'''| style="text-align<p>(homeassistant) orangepi@orangepi: left;"| '/srv/homeassistant$ ''PC5'''| style="textpython3 -align: left;"| '''13m pip install wheel'''</p>|}| style="text-align: left;"| '''14'''</li>| style="text-align: left;"| '''GND'''<li><p>Then you can install Home Assistant Core</p>{| styleclass="text-align: left;wikitable"|| style="text-alignwidth: left800px;"|
|-
| style="text-align: left;"| '''72'''| style="text-align<p>(homeassistant) orangepi@orangepi: left;"| /srv/homeassistant$ '''PC8pip3 install homeassistant'''</p>| style="text-align: left;"| '''PC8'''}| style="text-align: left;"| '''15'''</li>|<li><p>Then enter the following command to run Home Assistant Core</p>{| styleclass="text-align: left;"| '''16'''| style="text-align: left;"| '''PC15'''| style="text-align: left;wikitable"| '''PC15'''| style="text-alignwidth: left800px;"| '''79'''
|-
|-
| style="text-align: left;"| '''231'''| style="text-align: left;"| '''PH7'''| style="text-align: left;"| '''SPI1_MOSI'''| style="text-align: left;"| '''19'''|| style="text-align: left;"| '''20'''| style="text-align: left;"| '''GND'''| style="text-align: left;"|| style="text-align: left;"||-| style="text-align: left;"| '''232'''| style="text-align: left;"| '''PH8'''| style="text-align: left;"| '''SPI1_MISO'''| style="text-align: left;"| '''21'''|| style="text-align: left;"| '''22'''| style="text-align: left;"| '''PC7'''| style="text-align: left;"| '''PC7'''| style="text-align: left;"| '''71'''|-| style="text-align: left;"| '''230'''| style="text-align: left;"| '''PH6'''| style="text-align: left;"| '''SPI1_CLK'''| style="text-align: left;"| '''23'''|| style="text-align: left;"| '''24'''| style="text-align: left;"| '''SPI1_CS'''| style="text-align: left;"| '''PH9'''| style="text-align: left;"| '''233'''|-| style="text-align: left;"|| style="text-align: left;"|| style="text-align: left;"| '''GND'''| style="text-align: left;"| '''25'''|| style="text-align: left;"| '''26'''| style="text-align: left;"| '''PC10'''| style="text-align: left;"| '''PC10'''| style="text-align: left;"| <big><p>'''74When running the hass command for the first time, you will download and install and cache some necessary libraries and dependencies to run. This process may take a few minutes. Note that at this time, the interface of Home Assistant cannot be seen in the browser. Please wait for a while before refreshing.'''</p></big>
|}
<p>[[File:zero3-img194-1.png]]</p></li></ol>
<ol startspan id="3" style="listopencv-styleinstallation-type: decimal;method"><li>3) There are a total of 17 GPIO ports in the 26pin interface, and the voltage of all GPIO ports is '''3.3v'''</li></olspan>
<ol style="list-style-type: decimal;">
<li><p>Download the code of wiringOPThe installation command is shown below</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo apt -get update'''</p><p>orangepi@orangepi:~$ '''sudo apt -get install -y git'''</p><p>orangepi@orangepi:~$ '''git clone https://github.com/orangepilibopencv-xunlong/wiringOP.git dev python3-b nextopencv'''</p><p>'''Note that the source code needs to download the code of the wiringOP next branch, please don't miss the -b next parameter.'''</p>|}<p>'''If you have problems downloading the code from GitHub, you can directly use the wiringOP source code that comes with the Linux image, and the storage location is: /usr/src/wiringOP.'''</p></li><li><p>Compile and install wiringOP</p><p>orangepi@orangepi:~$ '''cd wiringOP'''</p><p>orangepi@orangepi:~/wiringOP$ '''sudo ./build clean'''</p><p>orangepi@orangepi:~/wiringOP$ '''sudo ./build'''</p></li><li><p>Test Then use the following command to print the output of the gpio readall command as followsversion number of OpenCV, indicating that the installation of OpenCV is successful</p>
<ol style="list-style-type: lower-alpha;">
<li><p>There The version of OpenCV in ubuntu22.04 is a oneshown below:</p>{| class="wikitable" style="width:800px;" |-to| <p>orangepi@orangepi:~$ '''python3 -one correspondence between pins 1 to 26 and 26 c "import cv2; print(cv2.__version__)>quot; Pins on the development board'''</p><p>'''4.5.4'''</p>|}</li><li><p>Pin 27 corresponds to pin 10 The version of 13pin on the development boardOpenCV in Ubuntu 20.04 is shown below:</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''python3 -c "import cv2; print(cv2.__version__)"'''</lip><li><p>Pin 29 corresponds to pin 11 of 13pin on the development board'''4.2.0'''</p>|}</li><li><p>Pin 31 corresponds to pin 12 The version of 13pin on the development boardOpenCV in Debian11 is shown below:</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''python3 -c "import cv2; print(cv2.__version__)"'''</lip><li><p>Pin 33 corresponds to pin 13 of 13pin on the development board'''4.5.1'''</p>|}</li><li><p>The version of OpenCV in Debian12 is shown below:</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''Pins 28, 30, 32, and 34 are empty, please ignore thempython3 -c "import cv2; print(cv2.__version__)"'''</p><p>[[File:media/image172'''4.6.png|575x365px]]0'''</p>|}</li></ol>
</li></ol>
<span id="pinthe-interfaceinstallation-gpiomethod-i2cof-uartthe-spiaapanel-andlinux-pwm-testpanel"></span>== 26pin interface GPIO, I2C, UART, SPI and PWM test ==
<ol style="list-style-type: decimal;">
<li><p>The following takes pin 7—the corresponding GPIO is PC9—the corresponding wPi number is 2—as an example First of all, you need to demonstrate how expand the'''/tmp''' memory. After setting, you need to set <span class="mark">'''<span style="color:#FF0000">restart the linux system of the pull-up development board,</span>'''and pull-down resistors of the GPIO portcommand is shown below</span>:</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media~$ '''sudo sed -i 's/nosuid/&,size=2G/image173.png|576x128px]]' /etc/fstab'''</p><p>orangepi@orangepi:~$ '''sudo reboot'''</p>|}</li><li><p>FirstAfter restarting, you need to set the GPIO port to the input mode, and the third parameter needs to be can see that the serial number size of the wPi corresponding to the input pin'''/tmp''' space has become 2G</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~$ '''df -h | grep "/wiringOP# tmp"'''</p><p>tmpfs 2.0G 12K '''gpio mode <span style="color:#FF0000">2 in.0G</span>''' 1% /tmp</p>|}</li><li><p>After setting to input mode, execute Then enter the following command in the Linux system to set start the installation of the GPIO port to pull-up modeaapanel</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~/wiringOP# $ '''gpio mode 2 upsudo install_bt_panel.sh'''</p>|}</li><li><p>Then enter the following command aapanel installation program reminds whether to read install the level of '''Bt-Panel''' to the GPIO port'''/www''' folder, if the level is 1, it means that the pulland enter Y at this time</p>{| class="wikitable" style="width:800px;" |-| <p>+----------------------------------------------------------------------</p><p>| Bt-WebPanel FOR CentOS/Ubuntu/Debian</p><p>+----------------------------------------------------------------------</p><p>| Copyright © 2015-2099 BT-SOFT(http://www.bt.cn) All rights reserved.</p><p>+----------------------------------------------------------------------up mode is set successfully</p><p>root@orangepi| The WebPanel URL will be http://SERVER_IP:~8888 when installed.</p><p>+----------------------------------------------------------------------</p><p>Do you want to install Bt-Panel to the /www directory now?(y/wiringOP# n): '''gpio read 2<span style="color:#FF0000">y</span>'''</p>|}</li><li><p>Then you have to wait patiently. When you see the printing information below the terminal output, it means that the pagoda has been installed. The entire installation process takes about 34 minutes. There may be some differences according to the difference in network speed</p><p>[[File:zero3-img195.png]]</p></li><li><p>At this time, enter the '''panel address''' displayed above in the browser to open the login interface of the aapanel Linux panel, and then enter the '''username'''and ''1'password'''displayed in the corresponding position to log in to the aapanel<br />[[File:zero3-img196.png|1200px]]</p></li><li><p>Then execute After successfully logging in to the aapanel, the following command welcome interface will pop up. First, please take the intermediate user notice to read to set the GPIO port to pull-down modebottom, and then you can choose "I have agreed and read" User Agreement ", and then click" Enter the panel " You can enter the aapanel</p><p>root@orangepi[[File:~zero3-img197.png|1200px]]</p></wiringOP# li><li><p>After entering the aapanel, you will first prompt that you need to bind the account of the aapanel official website. If you do n’t have an account, you can go to the aapanel's official website ('''gpio mode 2 downhttps://www.bt.cn''') to register one</p><p>[[File:zero3-img198.png|1200px]]</p></li><li><p>Then enter The final display interface is shown in the following command to read the level figure below. You can intuitively see some status information of the GPIO portdevelopment board Linux system, such as load state, CPU usage, if memory usage and storage space usage</p><p>[[File:zero3-img199.png|1200px]]</p></li><li><p>For more functions of the level is 0aapanel, please refer to the pullfollowing information to explore by yourself</p>{| class="wikitable" style="width:800px;" |-down mode is set successfully| <p>Use manual: [http://docs.bt.cn '''http://docs.bt.cn''']</p><p>root@orangepiForum website: [https:~/wiringOP# /www.bt.cn/bbs '''gpio read 2https://www.bt.cn/bbs''']</p><p>GitHub Link: '''0https://github.com/aaPanel/BaoTa'''</p>|}</li></ol> <span id="face_recognition-the-installation-and-testing-method-of-the-face-recognition-library"></span> == "face_recognition" The installation and testing method of the face recognition library ==
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Note that the contents of this section are tested in the Linux system of the <span idstyle="pin-spi-testcolor:#FF0000">desktop version</span>=== 26pin SPI test ===, so please make sure that the system used by the development board is a desktop version system.'''
{| class="wikitable"|-| style="textbackground-aligncolor: left#ffffdc;"| '''sda pin'''| style="text-align: left;"| '''Corresponding to pin 3 in 26pin'''|-| style="text-align: left;"| '''sck pin'''| style="text-alignwidth: left800px;"| '''Corresponding to pin 5 in 26pin'''
|-
| style="text-align: left;"| '''5v pin'''| style="text-align: left;"| '''Corresponding to pin 2 in 26pin'''|-| style="text-align: left;"| '''3.3v pin'''| style="text-align: left;"| <big>'''Corresponding to pin 1 in 26pin'''|-| style="text-alignThe address of the source code warehouse of Face_recognition is: left;"| '''gnd pin'''| style="text-align: left;"| '''Corresponding to pin 6 in 26pin'''|}
<span id="pinthe-uartmethod-testof-using-script-to-automatically-install-face_recognition"></span>=== 26pin UART test The method of using script to automatically install face_recognition ===
<ol style="list-style-type: decimal;">
<li><p>According to First open a terminal on the schematic diagram of the 26pin interfacedesktop''', the available uart is uart5then download face_recognition_install.sh'''</p><p>[[File:media/image181.png{|575x203px]]</p></li><li><p>uart5 is disabled by default in the Linux system, and it needs to be opened manually to use it. The steps to open are as follows:</p><ol class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>First run '''orangepi|-config''', normal users remember to add > '''sudo''' permission</p>| <p>orangepi@orangepi:~/Desktop$ '''sudo orangepi-config'''</p></li><li><p>Then select '''Systemwget \'''</p><p>[[File:media/image85.png|398x194px]]</p></li><li><p>Then select '''Hardware'''</p><p>[[Filehttps:media/image86.png|393x202px]]</p></li><li><p>Then use the arrow keys on the keyboard to navigate to the > position shown in the figure below, and then use the '''space''' > to select '''ph-uart5'''</p><p>[[File:media/image182gitee.png|400x60px]]<com/p><leeboby/li><li><p>Then select '''<Save>''' to save<face_recognition_install/p><p>[[File:mediaraw/image88.png|397x92px]]</p></li><li><p>Then select '''<Back>'''<master/p><p>[[File:media/image89face_recognition_install.png|395x91px]]</p></li><li><p>Then select '''<Reboot>sh''' to restart the system to make the > configuration take effect</p><p>[[File:media/image90.png|374x187px]]</p></li></ol>}
</li>
<li><p>After entering Then execute the linux system, first confirm whether there is a uart5 device node under '''/dev'''</p><p>'''Note that following command to start the linux5.4 system is /dev/ttyAS5.'''</p><p>orangepi@orangepi:~$ installation '''ls /dev/ttyS5face_recognition'''</p><p>/dev/ttyS5</p></li><li><p>Then start to test the uart5 interface, first use the DuPont line to short the rx and tx of the uart5 interface to be tested</p></li></ol> {| class="wikitable" style="width:800px;"
|-
|| style="text-align<p>orangepi@orangepi: left;"| uart5|-| tx pin| style="text-align: left;"| Corresponding to pin 8 of 26pin|-| rx pin| style="text-align: left;"| Corresponding to pin 10 of 26pin~/Desktop$ '''bash face_recognition_install.sh'''</p>
|}
</li>
<li><p>After face_recognition is installed, it will automatically download the source code of face_recognition, and then automatically run some examples in face_recognition. If you can finally see the following pictures popping up on the desktop, it means that the face_recognition installation test is successful.</p>
<p>[[File:zero3-img200.png]]</p></li></ol>
<ol startspan id="5" style="listmanually-styleinstall-type: decimal;face_recognition"><li><p>Use the '''gpio''' command in wiringOP to test the loopback function of the serial port as shown below. If you can see the following print, it means that the serial port communication is normal</p><p>orangepi@orangepi:~$ '''gpio serial /dev/ttyS5 # linux-6.1 test command'''</p><p>orangepi@orangepi:~$ '''gpio serial /dev/ttyAS5 # linux-5.4 test command'''</p><p>Out: 0: -> 0</p><p>Out: 1: -> 1</p><p>Out: 2: -> 2</p><p>Out: 3: -> 3^C</p></li></olspan>
<ol style="list-style-type: decimal;">
<li><p>In the Linux systemFirst create a new '''~/.pip''' directory, then add the pwm is closed by default'''pip.conf''' configuration file, and set the mirror source of pip to Tsinghua source in it needs , the commands to be opened manually to use it. The steps to open executed are as follows:</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li>|-| <p>First run orangepi@orangepi:~$ '''orangepimkdir -config''', normal users remember to add > '''sudop ~/.pip''' permission</p><p>orangepi@orangepi:~$ '''sudo orangepi-configcat <<EOF > ~/.pip/pip.conf'''</p><p>'''[global]'''</lip><li><p>Then select '''Systemtimeout = 6000'''</p><p>[[File'''index-url = https:media/image85/pypi.tuna.tsinghua.edu.png|398x194px]]cn/simple'''</p></li><li><p>Then select '''Hardwaretrusted-host = pypi.tuna.tsinghua.edu.cn'''</p><p>[[File:media/image86.png|393x202px]]'''EOF'''</p>|}</li><li><p>Then use the arrow keys on the keyboard to navigate to the > position shown in the figure below, and then use the space to > select the configuration corresponding to pwminstall dependencies</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''Since the RX and TX pins of UART5 in the PWM1, PWM2 and 26pin interfaces are multiplexed, please make sure that the UART5 configuration is not selected (do not check ph-uart5) when turning on PWM1 and PWM2 (you need to select ph-pwm12).sudo apt update'''</p><p>orangepi@orangepi:~$ '''PWM3, PWM4 and the TX and RX pins in the debug serial port are multiplexed, so when using PWM3 and PWM4 (need to select phsudo apt install -y python3-pwm34), please turn off the configuration of UART0 (need to select disablepip libopencv-uart0), after turning off UART0 The debug serial port cannot be used.dev \'''</p><p>[[File:media/image184.png|402x156px]]'''python3-opencv imagemagick python3-scipy python3-setuptools python3-wheel \'''</p></li><li><p>Then select '''<Save>python3-dev cmake python3-testresources''' to save</p><p>[[File:media/image88.png|397x92px]]</p>}</li><li><p>Then select '''<Back>'''update pip3</p><p>[[File{| class="wikitable" style="width:media/image89.png800px;" |-|395x91px]]</p></li><li><p>Then select orangepi@orangepi:~$ '''<Reboot>python3 -m pip install -U pip setuptools wheel''' to restart the system to make the > configuration take effect</p><p>[[File:media/image90.png|374x187px]]</p></li></ol>}
</li>
<li><p>After restartingBefore installing '''face_recognition''', you first need to install the '''dlib''' library. Since the PWM test compilation and installation of the dlib library on the development board is relatively slow, I saved a compiled dlib whl file on '''gitee''', and you can be startedinstall it directly after downloading. The download address of the dlib whl file is as follows:</p>{| class="wikitable" style="width:800px;" |-| <p>'''Please execute the following commands under the root userhttps://gitee.com/leeboby/python_whl'''</p>|}
<ol style="list-style-type: lower-alpha;">
<li><p>Enter First download the following command on python_whl warehouse to the command line to make pwm1 > output a 50Hz rectangular waveLinux system of the development board</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~# $ '''echo git clone --depth=1 > https:/sys/classgitee.com/pwmleeboby/pwmchip0/exportpython_whl'''</p>|}</li><li><p>In the python_whl folder, you can see that there are multiple versions of dlib installation packages. The Linux systems corresponding to different versions of dlib are as follows:</p>root@orangepi {| class="wikitable" style="width:800px;"|-| style="text-align:~# center;"| '''Ubuntu20.04'''echo 20000000 >| style="text-align: center; /sys/class/pwm/pwmchip0/pwm1/period"| '''dlib-19.24.0-cp38-cp38-linux_aarch64.whl'''</p><p>root@orangepi|-| style="text-align:~# center;"| '''Ubuntu22.04'''echo 1000000 >| style="text-align: center; /sys/class/pwm/pwmchip0/pwm1/duty_cycle"| '''dlib-19.24.0-cp310-cp310-linux_aarch64.whl'''</p><p>root@orangepi|-| style="text-align:~# center;"| '''Debian11'''echo 1 >| style="text-align: center; /sys/class/pwm/pwmchip0/pwm1/enable"| '''dlib-19.24.0-cp39-cp39-linux_aarch64.whl'''</p></li><li><p>Enter the following command on the command line to make pwm2 > output a 50Hz square wave</p></li></ol>|}
</li></ol>
<ol start="3" style="list-style-type: lower-alpha;">
<li>Enter <p>Then you can start installing dlib, the following command on is as follows</p><ol style="list-style-type: none;"><li><p>a) Ubuntu20.04</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''cd python_whl'''</p><p>orangepi@orangepi:~/python_whl$ '''python3 -m pip install dlib-19.24.0-cp38-cp38-linux_aarch64.whl'''</p>|}</li><li><p>b) Ubuntu22.04</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''cd python_whl'''</p><p>orangepi@orangepi:~/python_whl$ '''python3 -m pip install dlib-19.24.0-cp310-cp310-linux_aarch64.whl'''</p>|}</li><li><p>c) Debian11</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''cd python_whl'''</p><p>orangepi@orangepi:~/python_whl$ '''python3 -m pip install dlib-19.24.0-cp39-cp39-linux_aarch64.whl'''</p>|}</li></ol></li><li><p>After installation, if the version number of dlib can be printed normally by using the following command line to make pwm3 output , it means that dlib is installed correctly</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~/python_whl$ '''python3 -c "import dlib; print(dlib.__version__)>quot; a 50Hz rectangular wave'''</p><p>'''19.24.0'''</p>|}</li></ol></li></ol><!-- --><ol start="5" style="list-style-type: decimal;"><li><p>Then install '''face_recognition_models-0.3.0-py2.py3-none-any.whl'''</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~/python_whl$ '''python3 -m pip install face_recognition_models-0.3.0-py2.py3-none-any.whl'''</p>|}</li><li><p>Then install '''face_recognition'''</p>root{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''python3 -m pip install face_recognition'''</p>|}</li><li><p>Then you need to '''<span style="color:# FF0000">reopen a terminal</span>''' to find and run the two commands '''face_detection''' and '''face_recognition'echo 3 >''</p><ol style="list-style-type: none; "><li><p>a. The face_recognition command is used to recognize whose face is in a single image or a folder of images.</p></sysli><li><p>b. The face_detection command is used to locate the face in a single picture or a picture folder</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''which face_detection'''</pwmp><p>/pwmchip0usr/exportlocal/bin/face_detection</p><p>orangepi@orangepi:~$ '''which face_recognition'''</p><p>/usr/local/bin/face_recognition</p>|}
<ol style="list-style-type: decimal;">
<li><p>First install There are some sample codes in the source code of '''face_recognition''', which we can use directly for testing. The download address of the dependency packagesource code of face_recognition is as follows:</p><ol style="list-style-type: lower-alpha;"><li><p>GitHub official download address</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~# $ '''sudo apt-get updategit clone https://github.com/ageitgey/face_recognition.git'''</p>|}</li><li><p>Gitee image download address</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~# $ '''sudo apt-get -y install git swig python3-dev python3-setuptoolsclone [https://github.com/ageitgey/face_recognition https://gitee.com/leeboby/face_recognition.git]'''</p>|}</li></ol></li><li><p>Then use the following command The path to download the source face_recognition sample code of wiringOP-Pythonis as follows</p>{| class="wikitable" style="width:800px;" |-| <p>'''Note that the following git clone --recursive command will automatically download the source code face_recognition/examples'''</p>|}</li><li><p>The Chinese description document link of wiringOPface_recognition is as follows, because wiringOPplease read it carefully before using face_recognition</p>{| class="wikitable" style="width:800px;" |-Python depends on wiringOP| <p>[https://github.com/ageitgey/face_recognition/blob/master/README_Simplified_Chinese.md '''https://github. Please make sure that the download process does not report errors due to network problemscom/ageitgey/face_recognition/blob/master/README_Simplified_Chinese.md''']</p>|}</li><li><p>'''If you have problems downloading find_faces_in_picture.py''' is used to locate the position of the face in the code from GitHubpicture, you can directly use the wiringOPtest steps are as follows</p><ol style="list-Python source code that comes with style-type: lower-alpha;"><li><p>Open a terminal on the desktop, then enter the Linux image'''face_recognition/examples''' directory, and then execute the storage location isfollowing command</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi: ~$ '''cd face_recognition/usr/src/wiringOP-Pythonexamples'''</p><p>rootorangepi@orangepi:~# /face_recognition/examples$ '''python3 find_faces_in_picture.py'''</p><p>'''I found 1 face(s) in this photograph.'''</p><p>'''A face is located at pixel location Top: 241, Left: 419, Bottom: 562, Right: 740'''git clone </p>|}</li><li><p>Wait for a while and the following picture will pop up, which is the face located in the test picture</p><p>[[File:zero3--recursive https:img201.png]]</p></li></ol></githubli><li><p>'''find_facial_features_in_picture.compy''' is used to identify the key points of the face in a single picture, and the test steps are as follows</orangepip><ol style="list-xunlong/wiringOPstyle-Python type: lower-b nextalpha;"><li><p>Open a terminal on the desktop, then enter the '''face_recognition/examples'''directory, and then execute the following command</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~# $ '''cd wiringOP-Pythonface_recognition/examples'''</p><p>rootorangepi@orangepi:~/wiringOP-Python# face_recognition/examples$ '''git submodule update --init --remotepython3 find_facial_features_in_picture.py'''</p>|}</li><li><p>Then use After waiting for a while, the following command to compile wiringOP-Python picture will pop up, and install it into you can see that the Linux system outline of the development boardface is marked</p><p>root@orangepi[[File:~# zero3-img202.png]]</p></li></ol></li><li><p>'''identify_and_draw_boxes_on_faces.py'''cd wiringOPis used to identify faces and mark them with boxes. The test steps are as follows</p><ol style="list-style-type: lower-Pythonalpha;"><li><p>Open a terminal on the desktop, then enter the '''face_recognition/examples''' directory, and then execute the following command</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~/wiringOP-Python# $ '''python3 generate-bindings.py > bindings.icd face_recognition/examples'''</p><p>rootorangepi@orangepi:~/wiringOP-Python# face_recognition/examples$ '''sudo python3 setupidentify_and_draw_boxes_on_faces.py install'''</p>|}</li><li><p>Then enter After waiting for a while, the following commandpicture will pop up. You can see that the faces in the picture are marked with boxes, if there is help information output, it means that wiringOPand the names of the characters are displayed correctly</p><p>[[File:zero3-Python img203.png]]</p></li></ol></li><li><p>'''face_distance.py''' is installed successfullyused to compare whether two faces belong to the same person at different precisions. First open a terminal, press then enter the '''qface_recognition/examples''' key directory, and then execute the following command to exit see the help information interfaceoutput of the test</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''cd face_recognition/li>examples'''</olp> root<p>orangepi@orangepi:~/wiringOP-Pythonface_recognition/examples$ '''python3 face_distance.py'''</p><p>'''The test image has a distance of 0.35 from known image # 0'''</p><p>'''python3 -c "import wiringpi; help(wiringpi)"With a normal cutoff of 0.6, would the test image match the known image? True'''</p> Help on module wiringpi:<p>'''- With a very strict cutoff of 0.5, would the test image match the known image? True'''</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First , please insert the USB camera into the USB interface of the development board, and then use the python3 '''v4l2-ctl''' ('''<span style="color:#FF0000">note that l in v4l2 is a lowercase letter l, not the number 1</span>''') command to enter check the command line mode serial number of the device node of >the USB camera</p>{| class="wikitable" style="width:800px; python3" |-| <p>orangepi@orangepi:~$ '''sudo apt update'''</p><p>orangepi@orangepi:~$ '''sudo apt install -y v4l-utils'''</lip><p>orangepi@orangepi:~$ '''v4l2-ctl --list-devices'''</olp><p>cedrus (platform:cedrus):</lip>::<p>/dev/video0</olp>
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''wiringOP-Python is Note, please make sure that the same as wiringOP, you can also determine which GPIO pin to operate Linux system used by specifying the wPi number, because there development board is no command to check the wPi number in wiringOP-Python, so you can only check a desktop system before installing the board wPi number and physical Correspondence between pinsChinese input method.'''</big>|}
<ol style="list-style-type: decimal;">
<li><p>The following takes pin 7—the corresponding GPIO is PC9—the corresponding wPi number is 2—as an example to demonstrate how to First set the high and low levels of the GPIO port</p><p>[[File:media/image173.png|576x128px]]</p></li><li><p>The steps default '''locale''' to test directly with the command are as follows:Chinese</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First set Enter the GPIO port following command to output mode, where the first > parameter of start configuring the '''pinModelocale''' function is the serial number of > the wPi corresponding to the pin, and the second parameter is > the GPIO mode</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~/wiringOP-Python# $ '''python3 sudo dpkg-c "import wiringpi; \reconfigure locales'''</p>|}</li><li><p>Then select '''from wiringpi import GPIO; wiringpizh_CN.wiringPiSetupUTF-8 UTF-8''' in the pop-up interface () move up and down through the up and down direction keys on the keyboard, select through the space bar, and finally move the cursor to '''<OK> \'''through the Tab key, and then press Enter.)</p><p>'''wiringpi[[File:zero3-img210.pinMode(2, GPIO.OUTPUT) ; "'''png|1200px]]</p></li><li><p>Then set the GPIO port to output low level. After setting, you > can use a multimeter to measure the voltage value of the pin. > If it is 0v, it means that the low level is set successfully.</p><p>root@orangepi:~/wiringOP-Python# default '''python3 -c "import wiringpi; \locale'''</p><p>to '''from wiringpi import GPIO; wiringpizh_CN.wiringPiSetup() ;\UTF-8'''</p><p>'''wiringpi.digitalWrite(2, GPIO[[File:zero3-img211.LOW)"'''png|1200px]]</p></li><li><p>Then set After exiting the interface, the GPIO port to output a high level. After '''locale''' settingwill start, > you can use a multimeter to measure and the voltage value of the > pin. If it is 3.3v, it means that output displayed on the high level command line is set > successfully.as follows</p>{| class="wikitable" style="width:800px;" |-| <p>rootorangepi@orangepi:~/wiringOP-Python# $ '''python3 sudo dpkg-c "import wiringpi; \reconfigure locales'''</p><p>'''from wiringpi import GPIO; wiringpi.wiringPiSetupGenerating locales (this might take a while) ;\'''...</p>:<p>en_US.UTF-8... done</p>:<p>'''wiringpizh_CN.UTF-8...digitalWrite(2, GPIOdone</p><p>Generation complete.HIGH)"'''</p>|}</li></ol>
</li>
<li><p>The steps to test in Then open the command line of python3 are as follows:'''Input Method'''</p><ol style="list-style-typep>[[File: lowerzero3-alpha;"img212.png]]</p></li><li><p>First use the python3 command to enter the command line mode of > python3Then choose '''OK'''</p><p>root@orangepi[[File:~# zero3-img213.png]]</p></li><li><p>Then choose '''python3Yes'''</p><p>[[File:zero3-img214.png]]</p></li><li><p>Then import the python module of wiringpichoose '''fcitx'''</p><p>[[File:zero3-img215.png]]</p></li><li><p>>>> Then choose '''import wiringpiOK'''</p><p>>>> [[File:zero3-img216.png]]</p></li><li><p>'''from wiringpi import GPIO<span style="color:#FF0000">Then restart the Linux system to make the configuration take effect</span>'''</p></li><li><p>Then set the GPIO port to output mode, where the first parameter > of the open '''pinModeFcitx configuration''' function is </p><p>[[File:zero3-img217.png]]</p></li><li><p>Then click the serial number of + sign in the wPi > corresponding to position shown in the pin, and the second parameter is the GPIO > modefigure below</p><p>[[File:zero3-img218.png]]</p></li><li><p>>>> Then search '''Google Pinyin''' and click '''wiringpi.wiringPiSetup()OK'''</p><p>0[[File:zero3-img219-1.png]]</p></li><li><p>>>> Then bring '''wiringpi.pinMode(2, GPIO.OUTPUT)Google Pinyin'''to the front</p><p>[[File:zero3-img220.png]]</p><p>[[File:zero3-img221.png]]</p></li><li><p>Then set open the GPIO port '''Geany''' editor to output low level. After setting, you > can use a multimeter to measure test the voltage value of the pinChinese input method</p><p>[[File:zero3-img222. > If it png]]</p></li><li><p>The Chinese input method test is 0v, it means that the low level is set successfullyas follows</p><p>[[File:zero3-img223.png]]</p></li><li><p>>>> The Chinese and English input methods can be switched through the '''wiringpi.digitalWrite(2, GPIO.LOW)Ctrl+Space'''shortcut key</p></li><li><p>Then set If the GPIO port entire system needs to output a high level. After settingbe displayed in Chinese, > you can use a multimeter set the variables in '''/etc/default/locale''' to measure the voltage value of the > pin'''zh_CN. If it is 3.3v, it means that the high level is set >UTF-8'''</p>{| class="wikitable" style="width:800px; successfully" |-| <p>orangepi@orangepi:~$ '''sudo vim /etc/default/locale'''</p><p># File generated by update-locale</p><p>LC_MESSAGES='''<span style="color:#FF0000">zh_CN.UTF-8</span>'''</p><p>>>> LANG='''wiringpi<span style="color:#FF0000">zh_CN.digitalWrite(2, GPIO.HIGH)UTF-8</span>'''</p><p>LANGUAGE='''<span style="color:#FF0000">zh_CN.UTF-8</lispan>'''</olp>|}
</li>
<li><p>The method of wiringOP-Python to set GPIO high and low levels in python code can refer to the Then '''blink.py''' test program in <span style="color:#FF0000">restart the examples below. The '''blink.py''' test program will set the voltage of all GPIO ports in the 26 pins of the development board to change continuously.system</p><pspan>root@orangepi:~/wiringOP-Python# '''cd examples'''and you can see that the system is displayed in Chinese</p><p>root@orangepi[[File:~/wiringOPzero3-Python/examples# '''ls blinkimg224.py'''png]]</p><p/li>'''blink.py'''</pol> <p>root@orangepi:~/wiringOPspan id="how-to-install-ubuntu-Python/examples'''# python3 blink20.py'''</p04-system"></li></olspan>
<ol style="list-style-type: decimal;">
<li><p>According to the schematic diagram of the 26pin interface, the available spi is spi1</p><p>[[File:media/image176.png|565x209px]]</p></li><li><p>The spi1 is disabled by default in the Linux system and needs to be manually enabled before it can be used. The steps to First open are as follows:</p><ol style="list-style-type: lower-alpha;"><li><p>First run '''orangepi-config''', normal users remember to add > '''sudo''' permission</p><p>orangepi@orangepi:~$ '''sudo orangepi-config'''</p></li><li><p>Then select '''SystemLanguage Support'''</p><p>[[File:media/image85.png|398x194px]]</p></li><li><p>Then select '''Hardware'''</p><p>[[File:media/image86zero3-img225.png|393x202px]]</p></li><li><p>Then use the arrow keys on the keyboard to navigate to the > position shown in the figure below, and then use find the '''space''' > to select '''spi1-cs1-spidev'''</p><p>[[File:media/image177.png|392x57px]]</p></li><li><pspan class="mark">Then select '''<Save>Chinese (China''' to save)</p><pspan>[[File:media/image88.png|397x92px]]</p></li><li><p>Then select '''<Back>'''然后选择'''<Back>'''option</p><p>[[File:media/image89.png|395x91px]]</p></li><li><p>Then select '''<Reboot>''' to restart the system to make the > configuration take effect</p><p>[[File:media/image90zero3-img226.png|374x187px]]</p></li></ol></li><li><p>Then check whether there is a '''spidev1.1''' device node in the Linux system. If it exists, it means that the configuration of SPI1 has taken effect</p><p>orangepi@orangepi:~$ '''ls /dev/spidev1*'''</p><p>/dev/spidev1.1</p></li><li><p>Then you can please use the '''spidev_test.py''' program in the examples left mouse button to test the loopback function of the SPI. The '''spidev_test.pyselect ''' program needs to specify the following two parameters:</p><ol stylespan class="list-style-type: lower-alpha;mark"><li><p>'''--channel''': Specify the channel number of SPI</p>Chinese (China)</li><li><pspan>'''--port''': specify and hold it down, then drag it up to the port number of SPI</p></li></ol></li><li><p>Do not short-circuit the mosi and miso pins of SPI1initial position, the output result of running spidev_test.py display after dragging is as follows, you can see that shown in the data of TX and RX are inconsistentfigure below:</p><p>root@orangepi[[File:~/wiringOPzero3-Python# '''cd examples'''img227.png]]</p></li></ol>
</div></li><li><p>The interface after selection is as shown below, and then click OK</p><p>[[File:zero3-img239.png]]</p></li><li><p>Then we can open '''Geany''' to test the Chinese input method, the opening method is shown in the figure below</p><p>[[File:zero3--channel 1 --port 1img232.png]]</p></li><li><p>After opening '''Geany''', the default is English input method, we can switch to Chinese input method through '''Ctrl+Space'''shortcut key, and then we can input Chinese</p><p>[[File:zero3-img240.png]]</p></li></ol>
<ol style="list-style-type: decimal;">
<li><p>According to First download the schematic diagram installation package of 26pin, the available i2c is i2c3</p>NoMachine software Linux '''<p>[[Filespan style="color:media/image178.png|575x204px]]</p#FF0000">arm64</lispan><li><p>i2c3 is disabled by default in ''' deb version, and then install it into the Linux system, and it needs to be manually enabled before it can be used. The steps to open are as follows:of the development board</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First run '''orangepi-config'''Since H618 is a SOC of the ARMV8 architecture, the system we use is Ubuntu or Debian, normal users remember so you need to add > download the '''sudoNoMachine for ARM ARMv8 DEB''' permission</p><p>orangepi@orangepiinstallation package. The download link is shown below:~$ '''sudo orangepi-config'''</p></li><li><p>Then select '''System'''</p><p>[[File:media/image85.png{|398x194px]]</p></li><li><p>Then select '''Hardware'''</p><p>[[Fileclass="wikitable" style="background-color:media/image86.png|393x202px]]</p></li><li><p>d. Then use the arrow keys on the keyboard to navigate to the > position shown in the figure below, and then use the '''space''' >#ffffdc; to select '''ph-i2c3'''</p><p>[[Filewidth:media/image179.png|401x59px]]</p></li><li><p>Then select '''<800px;Save>''' to save</p>" <p>[[File:media/image88.png|397x92px]]</p></li>-<li><p>Then select '''<Back>'''</p><p>[[File:media/image89.png|395x91px]]</p></li><li><pbig>Then select '''<Reboot>''' to restart Note that this download link may change, please look for the system to make deb package of the > configuration take effect<Armv8/p><p>[[File:media/image90Arm64 version.png|374x187px]]</p></li></ol></li><li><p>After starting the linux system, first confirm that there is an i2c3 device node under /dev</p><p>orangepi@orangepi:~$ '''ls /dev/i2c-3'''</p><p>'''/dev/i2c-3'''</p></li><li><p>Then start testing i2c, first install i2c-tools</p><p>orangepi@orangepi:~$ '''sudo apt-get update'''</p><p>orangepi@orangepi:~$ '''sudo''' '''apt-get install -y i2c-tools'''</p></li><li><p>Then connect an i2c device to the i2c3 pin of the 26pin connector, here we take the DS1307 RTC module as an example</pbig><p>[[File:media/image186.png|180x153px]]</p></li></ol>}
{| class="wikitable" style="width:800px;"
|-
| '''https://downloads.nomachine.com/download/?id=118&distro=ARM'''|} [[File:zero3-img241.png]]</ol><ol start="2" style="textlist-style-aligntype: leftlower-alpha;"| ><li><p>In addition, the installation package of '''NoMachine'''Pins of can also be downloaded in the RTC module'''official tool'''</p>| style<p>[[File:zero3-img242.png]]</p><p>First enter the '''<span class="textmark">remote login software-alignNoMachine</span>''' folder</p><p>[[File: left;"| zero3-img243.png]]</p><p>Then download the arm64 version of the deb installation package</p><p>[[File:zero3-img244.png]]</p></li><li><p>Then upload the downloaded '''nomachine_x.x.x_x_arm64.deb'''The pin corresponding to the 26pin Linux system of the development board'''</p></li>|-| style="text-align: left;"| <li><p>Then use the following command to install '''5VNoMachine'''in the Linux system of the development board</p>{| class="wikitable" style="text-alignwidth: left800px;"| '''Pin 2'''
|-
| style="text-align<p>orangepi@orangepi: left;"| ~$ '''GNDsudo dpkg -i nomachine_x.x.x_x_arm64_arm64.deb'''</p>| }</li></ol></li></ol><!-- --><ol start="2" style="textlist-alignstyle-type: leftdecimal;"><li>Then download the installation package of the Windows version of the NoMachine software, the download address is as follows</li> {| '''Pin 6'''class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
| style="text-align: left;"| <big>'''SDANote that this download link may change.'''</big>| } {| class="wikitable" style="text-alignwidth: left800px;"| '''Pin 3'''
|-
| style="text-align: left;"| '''SCL'''| stylehttps://downloads.nomachine.com/download/?id="text-align: left;"| '''Pin 59'''
|}
[[File:zero3-img245.png]]</ol><ol start="63" style="list-style-type: decimal;"><li><p>Then use install NoMachine in Windows, '''please restart the computer after installation'''i2cdetect -y 3</p></li><li><p>Then open '''NoMachine''' commandin Window</p><p>[[File:zero3-img246.png]]</p></li><li><p>After Nomachine starts, if it will automatically scan other devices installed in the address local area network. After entering the main interface of Nomachine, you can see that the development board is already in the connected i2c device list, and then click the location shown in the red box below. Start log in to the linux system desktop of the development board</p><p>[[File:zero3-img247.png]]</p></li><li><p>Then click '''OK'''</p><p>[[File:zero3-img248.png]]</p></li><li><p>Then enter the username and password of the linux system in the corresponding position in the figure below, and then click '''<span class="mark">OK</span>''' to start logging in</p><div class="figure"> [[File:zero3-img249.png]] </div></li><li><p>Then click OK in the next interface</p></li><li><p>Finally, you can be detected, it means that see the desktop of the i2c device is connected correctlydevelopment board Linux system</p><p>[[File:zero3-img250.png]]</p></li></ol> <span id="log-in-remotely-using-vnc"></span> === Log in remotely using VNC ===
'''<span idstyle="pin-uart-test-1color:#FF0000">Ubuntu20.04 has many problems testing VNC, please do not use this method</span>'''</big>=== 26pin UART test ===|}
<ol style="list-style-type: decimal;">
<p>Starting applications specified in /root/.vnc/xstartup</p>
<p>Log file is /root/.vnc/orangepi:1.log</p>
|}
</li>
<li><p>The steps to use the MobaXterm software to connect to the desktop of the Linux system of the development board are as follows:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The second parameter 10 indicates the counting of the door dog. If the dog is not fed in this timeFirst click on Session, the system will restart</p></li><li><p>We can feed the dog by pressing any key (except ESC) on the keyboard. After the dog is fedthen select VNC, then fill in the program will print a line IP address and port of Keep Alive to indicate that the dog is successful.</p><p>orangepi@orangepi:~$ '''sudo watchdog_test 10'''</p><p>open success</p><p>options is 33152development board,identity is sunxi-wdt</p><p>put_usr return,if 0,success:0</p><p>The old reset time is: 16</p><p>return ENOTTY,if -1,success:0</p><p>return ENOTTY,if -1,success:0</p><p>put_user return,if 0,success:0</p><p>put_usr return,if 0,success:0</p><p>keep alive</p><p>keep alive</p><p>keep alive</p>and finally click OK to confirm</li></ol>
<span iddiv class="check-the-chipid-of-the-h618-chipfigure"></span>== Check the chipid of the H618 chip ==
<ol style="list-style-type: decimal;">
<li><p>First install Use the dependency package required script below to compile Pythoninstall QT5 and QT Creator</p><p>orangepi@orangepi{| class="wikitable" style="width:~$ '''sudo apt800px;" |-get update'''</p>| <p>orangepi@orangepi:~$ '''sudo apt-get install -y build-essential zlib1g-dev \install_qt.sh'''</p><p>'''libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libsqlite3-dev \'''</p>|}<p>'''libreadline-dev libffi-dev curl libbz2-dev'''</p></li><li><p>Then download After installation, the latest version number of the Python3.9 source code and decompress itQT will be automatically printed</p><pol style="list-style-type: lower-alpha;">orangepi@orangepi:~$ '''wget \'''</pli><p>[https://wwwThe qt version that comes with Ubuntu 20.python.org/ftp/python/3.9.10/Python-3.9.10.tgz 04 is '''https://www5.python12.org/ftp/python/3.9.10/Python-3.9.10.tgz8''']</p><p>orangepi@orangepi{| class="wikitable" style="width:~$ '''tar xvf Python800px;" |-3.9.10.tgz'''</p></li><li><p>Then run the configuration command</p>| <p>orangepi@orangepi:~$ '''cd Python-3install_qt.9.10sh'''</p><p>orangepi@orangepi:~$ '''./configure --enable-optimizations'''.....</p></li><li><p>Then compile and install python3QMake version 3.9, the compilation time takes about half an hour1</p><p>orangepi@orangepi:~$ '''make -j4Using Qt version '''</pspan style="color:#FF0000">5.12.8<p/span>orangepi@orangepi:~$ '''sudo make altinstall'''<in /p><usr/li><li><p>After installation, you can use the following command to view the Python version number just installed<lib/p><p>orangepi@orangepi:~$ '''python3.9 aarch64-linux-version'''gnu</p><p>'''Python 3.9.10'''</p>|}</li><li><p>Then update pip</p><p>orangepi@orangepi:~$ The QT version that comes with Ubuntu 22.04 is '''/usr/local/bin/python35.15.9 -m pip install --upgrade pip3'''</p></li></ol> <span id{| class="python-to-replace-the-pip-source-methodwikitable"></span>=== Python to replace the pip source method === '''The Linux system PIP's default source is the official source of Python, but the source of the official Python official visits is very slow, and the Python software packaging failure is often caused by network reasons. So when installing the Python library with PIP, remember to replace the pip source''' <ol style="list-style-typewidth: decimal800px;"><li><p>First install '''python3|-pip'''</p><p>orangepi@orangepi:~$ '''sudo apt-get update'''</p>| <p>orangepi@orangepi:~$ '''sudo apt-get install -y python3-pipinstall_qt.sh'''</p></li><li><p>Method of permanent replacement of pip source under Linux</p><ol style="list-style-type: lower-alpha;"><li><p>Create a new'''~/.pip''' directory first, then add the > '''pip.conf''' configuration file, and set the source of the pip > as Tsinghua source</p><p>orangepi@orangepi:~$ '''mkdir -p ~/.pip'''</p><p>orangepi@orangepi:~$ '''cat <<EOF > ~/.pip/pip.conf'''.</p><p>'''[global]'''QMake version 3.1</p><p>'''timeout = 6000Using Qt version '''</p><p>'''index-url span style= https"color://pypi#FF0000">5.tuna15.tsinghua.edu.cn/simple'''3</p><pspan>'''trusted-host = pypi.tuna.tsinghua.edu.cn'''<in /p><p>'''EOF'''<usr/p><lib/li><li><p>Then install the Python library with pip3, it will be fastaarch64-linux-gnu</p></li></ol>|}
</li>
<li><p>The method of temporarily replacing the pip source under Linux, the QT version that comes with Debian11 is '''<packagename>5.15.2''' needs to be replaced with a specific package name</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''pip3 install <packagename> -i \install_qt.sh'''</p><p>......</p><p>QMake version 3.1</p><p>Using Qt version '''https<span style="color:#FF0000">5.15.2</span>''' in /usr/lib/aarch64-linux-gnu</pypip>|}</li><li><p>The QT version that comes with Debian12 is '''5.tuna15.8'''</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''install_qt.sh'''</p><p>.tsinghua.edu.cn...</simple --trusted-host pypip><p>QMake version 3.tuna1</p><p>Using Qt version '''<span style="color:#FF0000">5.tsinghua15.edu.cn8</span>'''in /usr/lib/aarch64-linux-gnu</p>|}</li></ol></li><span idli><p>Then you can see the QT Creator startup icon in '''Applications'''</p><p>[[File:zero3-img254.png]]</p><p>You can also use the following command to open QT Creator</p>{| class="wikitable" style="thewidth:800px;" |-method| <p>orangepi@orangepi:~$ '''qtcreator'''</p>|}</li><li><p>The interface after QT Creator is opened is as follows</p><p>[[File:zero3-img255.png]]</p></li><li><p>The version ofQT Creator is as follows</p><ol style="list-installingstyle-thetype: lower-dockeralpha;"><li><p>The default version of QT Creator in '''Ubuntu20.04''' is as follows</p><p>[[File:zero3-img256.png]]</p></li><li><p>The default version of QT Creator in '''Ubuntu22.04''' is as follows</p><p>[[File:zero3-img257.png]]</spanp></li>== <li><p>The Method Of Installing default version of QT Creator in '''Debian11''' is as follows</p><p>[[File:zero3-img258.png]]</p></li><li><p>The Docker =default version of QT Creator in '''Debian12''' is as follows</p><p>[[File:zero3-img259.png]]</p></li></ol></li><li><p>Then set up QT</p><ol style="list-style-type: lower-alpha;"><li><p>First open '''Help'''->'''About Plugins.…'''</p><p>[[File:zero3-img260.png]]</p></li>Orange Pi<li><p>Then remove the tick of '''ClangCodeModel'''s Linux image has been pre</p><p>[[File:zero3-installed with Dockerimg261.png]]</p></li><li><p>'''<span style="color:#FF0000">After setting, but you need to restart QT Creator</span>'''</p></li><li><p>Then make sure the Docker service has not been opened GCC compiler used by QT Creator, if the default. Use Eis Clang, please modify it to GCC</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''enable_dockerDebian12 please skip this step.sh''' script to enable the docker service, and then </p></big>|}<p>[[File:zero3-img262.png]]</p><p>[[File:zero3-img263.png]]</p></li></ol></li><li><p>Then you can start using open a sample code</p><p>[[File:zero3-img264.png]]</p></li><li><p>After clicking the docker commandsample code, and the docker service corresponding instruction document will be opened automatically activated at , you can read the next start instructions carefully</p><p>[[File:zero3-img265.png]]</p></li><li><p>Then click '''Configure Project'''</p><p>[[File:zero3-img266.png]]</p></li><li><p>Then click the green triangle in the lower left corner to compile and run the sample code</p><p>[[File:zero3-img267.png]]</p></li><li><p>After waiting for a period of time, the systeminterface shown in the figure below will pop up, which means that QT can compile and run normally</p><p>[[File:zero3-img268.png]]</p></li><li><p>References</p>{| class="wikitable" style="width:800px;" |-| <p>[https://wiki.qt.io/Install_Qt_5_on_Ubuntu '''https://wiki.qt.io/Install_Qt_5_on_Ubuntu''']</p><p>[https://download.qt.io/archive/qtcreator '''https://download.qt.io/archive/qtcreator''']</p>orangepi@orangepi<p>[https:~$ //download.qt.io/archive/qt '''enable_dockerhttps://download.shqt.io/archive/qt''']</p>|}</li></ol>
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Hello from Docker!<span style="color:#FF0000">Note that running the following command needs to ensure that the development board can access github normally, otherwise an error will be reported due to network problems</span>'''
'''The install_ros.…sh script will try to modify /etc/hosts and run the following commands automatically. However, this method cannot guarantee that github can be accessed normally every time. If install_ros.sh prompts the following error after installing ros1, please find other ways to allow the linux system of the development board to access github normally, and then manually run the following command.'''
'''NoteHit https: You need to log out of the system and log in again to take effect, and restarting the system is also OK//raw.githubusercontent.com/ros/rosdistro/master/rosdep/base.yaml'''
'''<span idstyle="how-to-install-home-assistantcolor:#FF0000">ERROR: error loading sources list:</span>== How to install Home Assistant =='''
::'''Note that only the method of installing Home Assistant in Ubuntu or Debian system will be provided here. For detailed usage of Home Assistant, please refer to official documents or corresponding books。<span style="color:#FF0000">The read operation timed out</span>'''</big>|}
|-
| style="text-align: left;"| '''Ubuntu20.04'''| style="text-align: left;"| '''dlib-19.24.0-cp38-cp38-linux_aarch64.whl'''|-| style="text-align<p>orangepi@orangepi: left;"| ~$ '''Ubuntu22.04'''| style="text-align: left;"| '''dlib-19.24.0-cp310-cp310-linux_aarch64.whl'''|-| style="text-align: left;"| '''Debian11'''| style="text-align: left;"| '''dlib-19.24.0-cp39-cp39-linux_aarch64test_ros.whlsh'''</p>
|}
</li>
<li><p>After installationrunning the '''test_ros.sh''' script, if the version number of dlib can be printed > normally by using a little turtle as shown in the following command, it means that dlib is > installed correctlyfigure below will pop up</p><p>orangepi@orangepi[[File:~/python_whl$ '''python3 zero3-c "import dlib; print(dlibimg272.__version__)"'''png]]</p></li><li><p>'''19.24.0'''Then please keep the terminal window you just opened on top</p></li></ol>
<!-- --><ol startdiv class="5figure" style="list-style-type: decimal;"><li><p>Then install '''face_recognition_models-0.3.0-py2.py3-none-any.whl'''</p><p>orangepi@orangepi:~/python_whl$ '''python3 -m pip install face_recognition_models-0.3.0-py2.py3-none-any.whl'''</p></li><li><p>Then install '''face_recognition'''</p><p>orangepi@orangepi:~$ '''python3 -m pip install face_recognition'''</p></li><li><p>Then you need to '''reopen a terminal''' to find and run the two commands '''face_detection''' and '''face_recognition'''</p><ol style="list-style-type: lower-alpha;"><li><p>The face_recognition command is used to recognize whose face is > in a single image or a folder of images.</p></li><li><p>The face_detection command is used to locate the face in a > single picture or a picture folder</p><p>orangepi@orangepi:~$ '''which face_detection'''</p><p>/usr/local/bin/face_detection</p><p>orangepi@orangepi:~$ '''which face_recognition'''</p><p>/usr/local/bin/face_recognition</p></li></ol></li></ol>
<span id="thehow-testto-methodinstall-ofros-face_recognition2-galactic-on-ubuntu-20.04"></span>=== The test method of face_recognition ===
<ol style="list-style-type: decimal;">
<li><p>There are some sample codes in The currently active version of ROS 2 is shown below, and the source code of recommended version is '''face_recognitionGalactic Geochelone''', which we can use directly for testing. The download address of the source code of face_recognition is as follows:</p><ol style="list-style-typep>[[File: lowerzero3-alpha;"img275.png]]</p><li><p>GitHub official download address[[File:zero3-img276.png]]</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi[http:~$ //docs.ros.org/ '''git clone httpshttp://githubdocs.com/ageitgey/face_recognitionros.gitorg''']</p></li><li><p>Gitee image download address</p><p>orangepi@orangepi:~$ '''git clone [httpshttp://githubdocs.com/ageitgey/face_recognition https:ros.org/en/gitee.com/leebobygalactic/face_recognitionReleases.git]html'''</p></li></ol>|}
</li>
<li><p>The path link to the face_recognition sample code is as follows</p><p>official ROS 2 '''face_recognition/examplesGalactic Geochelone'''</p></li><li><p>The Chinese description document link of face_recognition installation documentation is as follows, please read it carefully before using face_recognition</p><p>[https://github.com/ageitgey/face_recognition/blob/master/README_Simplified_Chinese.md '''https://github.com/ageitgey/face_recognition/blob/master/README_Simplified_Chinese.md''']</p></li><li><p>'''find_faces_in_picture.py''' is used to locate the position of the face in the picture, the test steps are as follows</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li>|-| <p>Open a terminal on the desktop, then enter the > '''face_recognitiondocs.ros.org/en/galactic/examplesInstallation.html''' directory, and then execute the > following command</p><p>orangepi@orangepi:~$ '''cd face_recognitionhttp://examples'''<docs.ros.org/p><p>orangepi@orangepi:~en/face_recognitiongalactic/examples$ '''python3 find_faces_in_picture.py'''<Installation/p><p>'''I found 1 face(s) in this photographUbuntu-Install-Debians.html'''</p><p>'''A face is located at pixel location Top: 241, Left: 419, Bottom: 562, Right: 740'''</p></li><li><p>Wait for a while and the following picture will pop up, which is > the face located in the test picture</p><p>[[File:media/image201.png|575x311px]]</p></li></ol>}
</li>
<li><p>In the official ROS 2 '''find_facial_features_in_picture.pyGalactic Geochelone''' is installation document, Ubuntu Linux recommends using Ubuntu 20.04, so please make sure that the system used to identify by the key points of development board is the face in a single picture, and the test steps are as follows'''</p><ol span style="list-style-typecolor: lower-alpha;#FF0000">Ubuntu 20.04 desktop system<li><p/span>Open a terminal on the desktop, then enter the > '''face_recognition/examples. There are several ways to install ROS 2. The following demonstrates how to install ROS 2 ''' directory, and then execute the > following command</pspan class="mark">Galactic Geochelone<p/span>orangepi@orangepi:~$ '''cd face_recognition/examplesthrough '''</pspan class="mark">Debian packages<p/span>orangepi@orangepi:~/face_recognition/examples$ '''python3 find_facial_features_in_picture.py'''</p></li><li><p>After waiting for a while, the following picture will pop up, > and you Ros2 can see that be installed using the outline of the face is marked'''install_ros.sh''' script</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media/image202~$ '''install_ros.png|575x302px]]sh ros2'''</p></li></ol>|}
</li>
<li><p>The '''identify_and_draw_boxes_on_facesinstall_ros.pysh''' script will automatically run the ''' ros2 -h''' command after installing ros2. If you can see the following print, it means that the ros2 installation is used to identify faces and mark them with boxes. The test steps are as followscomplete</p><ol {| class="wikitable" style="listwidth:800px;" |-style-type| <p>usage: lowerros2 [-alphah] Call `ros2 <"command> -h` for more detailed usage. ...</p> <p>ros2 is an extensible command-line tool for ROS 2.<li/p> <p>Open a terminal on the desktop, then enter the > '''face_recognitionoptional arguments:</examples''' directoryp>:<p>-h, --help show this help message and then execute the > following commandexit</p> <p>Commands:</p>:<p>action Various action related sub-commands</p>:<p>bag Various rosbag related sub-commands</p>:<p>component Various component related sub-commands</p>orangepi@orangepi:~$ '''cd face_recognition<p>daemon Various daemon related sub-commands</p>:<p>doctor Check ROS setup and other potential issues</examples'''p>:<p>interface Show information about ROS interfaces</p>:<p>orangepi@orangepilaunch Run a launch file</p>:~<p>lifecycle Various lifecycle related sub-commands</face_recognitionp>:<p>multicast Various multicast related sub-commands</examples$ '''python3 identify_and_draw_boxes_on_faces.py'''p>:<p>node Various node related sub-commands</p>:<p>param Various param related sub-commands</lip>:<lip>pkg Various package related sub-commands</p>:<p>After waiting for run Run a while, the following picture will pop up. > You can see that the faces in the picture are marked with > boxes, and the names of the characters are displayed correctlypackage specific executable</p>:<p>[[Filesecurity Various security related sub-commands</p>:media<p>service Various service related sub-commands</image203.png|461x250px]]p>:<p>topic Various topic related sub-commands</p>:<p>wtf Use `wtf` as alias to `doctor`</lip> :<p>Call `ros2 <command> -h` for more detailed usage.</olp>|}
</li>
<li><p>Then you can use the '''face_distancetest_ros.pysh''' is used script to compare test whether two faces belong to the same person at different precisions. First open a terminal, then enter the '''face_recognition/examples''' directory, and then execute the following command to see the output of the test</p><p>orangepi@orangepi:~$ '''cd face_recognition/examples'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''python3 face_distance.py'''</p><p>'''The test image has a distance of 0.35 from known image #0'''</p><p>'''- With a normal cutoff of 0.6, would the test image match the known image? True'''</p><p>'''- With a very strict cutoff of 0.5, would the test image match the known image? True'''</p><p>'''The test image has a distance of 0.82 from known image #1'''</p><p>'''- With a normal cutoff of 0.6, would the test image match the known image? False'''</p><p>'''- With a very strict cutoff of 0.5, would the test image match the known image? False'''</p></li><li><p>'''recognize_faces_in_pictures.py''' is used to identify who the face in the unknown picture ROS 2 isinstalled successfully. First open a terminal, then enter the '''face_recognition/examples''' directory, and then execute the following command, and If you can see the test results after waiting for a while</p><p>orangepi@orangepi:~$ '''cd face_recognition/examples'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''python3 recognize_faces_in_pictures.py'''</p><p>'''Is the unknown face a picture of Biden? False'''</p><p>'''Is the unknown face a picture of Obama? True'''</p><p>'''Is the unknown face a new person following print, it means that we've never seen before? False'''ROS 2 can run normally</p></li><li><p>'''facerec_from_webcam_faster.py''' is used to recognize the face in the USB camera, the test steps are as follows:</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>First, please insert the USB camera into the USB interface of > the development board, and then use the '''v4l2|-ctl''' ('''note > that l in v4l2 is a lowercase letter l, not the number 1''') > command to check the serial number of the device node of the > USB camera</p>| <p>orangepi@orangepi:~$ '''sudo apt updatetest_ros.sh'''</p><p>orangepi@orangepi[INFO] [1671174101.200091527] [talker]: Publishing:~$ '''sudo apt install -y v4l-utils''Hello World: 1'</p><p>orangepi@orangepi[INFO] [1671174101.235661048] [listener]:~$ '''v4l2-ctl --list-devices'''</p><p>cedrus (platformI heard:cedrus)[Hello World:1]</p><p>/dev/video0</p><p>USB2[INFO] [1671174102.0 UVC PC Camera199572327] [talker]: USB2.0 UV (usb-5311000.usb-1)Publishing:</p><p>'''/dev/video1''Hello World: 2'</p><p>/dev/video2</p></li><li><p>Then open a terminal on the desktop, enter the > '''face_recognition/examples''' directory, and first modify the > device serial number of the camera used in > '''facerec_from_webcam_faster[INFO] [1671174102.py.''' For example, through the > '''v4l2-ctl --list-devices''' command above, you can see that > the USB camera is '''/dev/video1''', then modify the '''0''' in > '''cv2.VideoCapture(0)''' to '''1'''</p><p>orangepi@orangepi204196299] [listener]:~$ '''cd face_recognition/examples'''</p><p>orangepi@orangepiI heard:~/face_recognition/examples$ '''vim facerec_from_webcam_faster.py'''</p><p>'''video_capture = cv2.VideoCapture(1)'''</p></li><li><p>Then execute the following command to run > '''facerec_from_webcam_faster.py'''</p><p>orangepi@orangepi[Hello World:~/face_recognition/examples$ '''python3 facerec_from_webcam_faster.py'''</p></li><li><p>Wait for a while and the camera display screen will pop up2]</p><p>[INFO] [File:media/image2041671174103.png|314x245px199580322][talker]</p></li><li><p>At this point, you can point the camera at yourself. When the > camera detects a face, it will frame the detected face with a > square. '''Note that when detecting a face, the image displayed > by the camera will be relatively slow, please do not move too > fast': Publishing: 'Hello World: 3'</p></li><li><p>You can also open a picture of Obama, and then use the camera to > point at the opened picture[INFO] [1671174103. You can see that not only the > face can be marked, but also the name of the detected face can > be displayed correctly. '''Note that when detecting a face, the > image displayed by the camera will be relatively slow, please > do not move too fast'''</p><p>204019965] [listener]: I heard: [FileHello World:media/image205.png|358x284px]3]</p></li></ol>|}
</li>
<li><p>'''web_service_example.py''' is a very simple case of using a web service Run the following command to upload a picture to run face recognition. The backend server will identify whether the picture is Obama, and output the recognition result as a json key-value pair. The test steps are as follows:open rviz2</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li><p>Open a terminal on the desktop, then enter the > '''face_recognition/examples''' directory, and then execute the > following command ('''if face_recognition is automatically > installed using a script, then there is no need to install > flask''')</p>|-| <p>orangepi@orangepi:~$ '''python3 -m pip install flasksource /opt/ros/galactic/setup.bash'''</p><p>orangepi@orangepi:~$ '''cd face_recognition/examplesros2 run rviz2 rviz2'''</p>|}<p>root@orangepi[[File:~/face_recognition/examples$ '''python3 web_service_examplezero3-img277.py'''png]]</p><p>* Serving Flask app 'web_service_example' (lazy loading)</pli><p>* Environment: production</pli><p>WARNING: This is a development server. Do not For how to use it in a production deployment.ROS, please refer to the documentation of ROS 2</p><p>Use a production WSGI server instead.</p><p>* Debug mode{| class="wikitable" style="width: on</p>800px;" <p>* Running on all addresses (0.0.0.0)</p>|-<p>WARNING: This is a development server. Do not use it in a production deployment.</p>| <p>* Running on [http://127.0docs.0ros.1:5001<org/p><p>* Running on http:en/galactic/192Tutorials.168.1.79:5001 (Press CTRL+C to quit)</p><p>* Restarting with stat</p><p>* Debugger is active!</p><p>* Debugger PIN: 500-161-390</p></li><li><p>Then open another terminal and run the following command to > return the result of image recognition (note that the > execution path of the following command is > '''face_recognition/examples''')</p><p>orangepi@orangepi:~/face_recognition/examples$ '''curl -XPOST -F \'''</p><p>html '''"file=@obama2.jpg" http://127docs.0ros.0.1:5001'''<org/p><p>'''{'''<en/p><p>'''"face_found_in_image": true,'''<galactic/p><p>'''"is_picture_of_obama": trueTutorials.html''']</p><p>'''|}'''</pli></liol> <li><p>We can also copy the picture > '''face_recognition/examples/obama2.jpg''' span id="how-to other Linux > computers. Of course, we can also prepare a picture named > '''obama2.jpg''' by ourselves, and then use the following > command -install-ros-2-humble-on the Linux computer to remotely Use the service > running on the development board to recognize faces ('''note > that the IP address in the command needs to be replaced with > the IP address of the development board, and the file name > after file needs to be replaced with the name of the picture > you want to test''').</p><p>test@test:~$ '''curl -XPOST ubuntu-F "file=@obama222.jpg" http://192.168.1.79:5001'''</p><p>'''{'''</p04"><p>'''"face_found_in_image": true,'''</pspan><p>'''"is_picture_of_obama": true'''</p><p>'''}'''</p></li>=== How to install ROS 2 Humble on Ubuntu 22.04 ===<li><p>The method to test using the browser is as follows:</p><ol style="list-style-type: lower-alphadecimal;"><li><p>First open the browser, then enter Ros2 can be installed using the '''<span class="mark">IP address of the > development board: 5001</span>install_ros.sh''' in the address bar of > the browser, and then you can see the following pagescript</p><p>[[File{| class="wikitable" style="width:media/image206.png800px;" |575x150px]]</p></li>-<li><p>Then copy obama2.jpg to the desktop</p>| <p>orangepi@orangepi:~/face_recognition/examples$ '''cp obama2install_ros.jpg /home/orangepi/Desktop/sh ros2'''</p></li><li><p>Then select the picture you just copied in your browser</p><p>[[File:media/image207.png|575x217px]]</p></li><li><p>Then click '''Upload''' to upload the picture you just > selected for face recognition</p><p>[[File:media/image208.png|575x145px]]</p></li><li><p>After waiting for a while, the detection result will be > displayed</p><p>[[File:media/image209.png|314x149px]]</p></li></ol></li></ol>}
</li>
<li><p>The '''install_ros.sh''' script will automatically run the '''face_detectionros2 -h''' command test exampleafter installing ros2. If you can see the following print, it means that the ros2 installation is complete</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li>|-| <p>The face_detection commandusage: ros2 [-line tool can locate the face h] Call `ros2 >lt; position (output pixel coordinates) in a single picture or a command> picture folder-h` for more detailed usage. ... Use '''face_detection </p> <p>ros2 is an extensible command--help''' to view the > help information of the face_detection commandline tool for ROS 2.</p> <p>optional arguments:</p>orangepi@orangepi:~$ '''face_detection <p>-h, --help'''show this help message and exit</p> <p>UsageCommands: face_detection [OPTIONS] IMAGE_TO_CHECK</p>:<p>Options:action Various action related sub-commands</p>:<p>bag Various rosbag related sub--cpus INTEGER number of CPU cores to use in parallel. -1 means "use all incommands</p>:<p>system"component Various component related sub-commands</p>:<p>daemon Various daemon related sub--model TEXT Which face detection model to use. Options are "hog" orcommands</p>:<p>"cnn".doctor Check ROS setup and other potential issues</p>:<p>--help interface Show this message and exit.information about ROS interfaces</p>:<p>launch Run a launch file</lip><li>:<p>An example of detecting a single image is shown below:lifecycle Various lifecycle related sub-commands</p>:<p>orangepi@orangepi:~$ '''cd face_recognition/examples'''multicast Various multicast related sub-commands</p>:<p>orangepi@orangepi:~/face_recognition/examples$ '''face_detection obama2.jpg'''node Various node related sub-commands</p>:<p>obama2.jpg,302,474,611,164param Various param related sub-commands</p>:<p>pkg Various package related sub-commands</lip><li>:<p>An example of using multiple cores to detect multiple images in > parallel is shown below:run Run a package specific executable</p><ol style="list-style-type: lower-alpha;"><lip>security Various security related sub-commands</p>First enter the '''face_recognition/examples''' folder:</p>service Various service related sub-commands</lip>:<lip>topic Various topic related sub-commands</p>Then create a new test folder:</p>wtf Use `wtf` as alias to `doctor`</lip><li> :<p>Then copy the jpg images to the test folderCall `ros2 <command> -h` for more detailed usage.</p>|}</li><li><p>Then you can use all cpus to run the '''face_detectiontest_ros.sh''' in parallel script to > check the pictures in test whether ROS 2 is installed successfully. If you can see the test folderfollowing print, where '''--cpus > -1''' it means to use all cpusthat ROS 2 can run normally</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''cd face_recognition/examplestest_ros.sh'''</p><p>orangepi@orangepi[INFO] [1671174101.200091527] [talker]: Publishing:~/face_recognition/examples$ '''mkdir test''Hello World: 1'</p><p>orangepi@orangepi[INFO] [1671174101.235661048] [listener]: I heard: [Hello World:~/face_recognition/examples$ '''cp *.jpg test'''1]</p><p>orangepi@orangepi[INFO] [1671174102.199572327] [talker]: Publishing:~/face_recognition/examples$ '''face_detection --cpus -1 test''Hello World: 2'</p><p>test/obama-240p[INFO] [1671174102.jpg,29,261,101,189204196299] [listener]: I heard: [Hello World: 2]</p><p>test/obama_small[INFO] [1671174103.jpg,65,215,169,112199580322] [talker]: Publishing: 'Hello World: 3'</p><p>test/obama2[INFO] [1671174103.jpg,302,474,611,164204019965] [listener]: I heard: [Hello World: 3]</p>|}</li><li><p>test/two_people.jpg,62,394,211,244Run the following command to open rviz2</p>{| class="wikitable" style="width:800px;" |-| <p>testorangepi@orangepi:~$ '''source /opt/ros/humble/two_peoplesetup.jpg,95,941,244,792bash'''</p><p>test/obama.jpg,136,624,394,366orangepi@orangepi:~$ '''ros2 run rviz2 rviz2'''</p>|}<p>test/obama[[File:zero3-480pimg278.jpg,65,507,189,383png]]</p></li><li><p>test/obama-720p.jpg,94,751,273,572Reference documents</p>{| class="wikitable" style="width:800px;" |-| <p>test'''http://docs.ros.org/en/humble/obama-1080pindex.jpg,136,1140,394,882html'''</p><p>test'''http://bidendocs.jpg,233,749,542,439<ros.org/en/humble/p><Installation/li>Ubuntu-Install-Debians.html'''</olp>|}
</li></ol>
<span id="how-to-install-the-kernel-header-file"></span>
== How to install the kernel header file ==
{| class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
|
<big>'''The Debian 11 system with the <span style="color:#FF0000">Linux6.1</span> kernel will report a GCC error when compiling the kernel module. So if you want to compile the kernel module, please use Debian12 or Ubuntu22.04'''</big>
|}
<ol style="list-style-type: decimal;">
<li><p>The Linux image released by OPi comes with the deb package of the kernel header file by default, and the storage location is '''/opt/'''</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>orangepi@orangepi:~$ '''ls /opt/linux-headers*'''</p>
<p>/opt/linux-headers-xxx-sun50iw9_x.x.x_arm64.deb</p>
|}
</li>
<li><p>'''face_recognition''' command test example</p><ol style="list-style-type: lower-alpha;"><li><p>'''face_recognition''' command-line tool can recognize whose face > is in a single picture or a picture folder. Use > '''face_recognition --help''' to view the help information of > the face_recognition command</p><p>orangepi@orangepi:~$ '''face_recognition --help'''</p><p>Usage: face_recognition [OPTIONS] KNOWN_PEOPLE_FOLDER IMAGE_TO_CHECK</p><p>Options:</p><p>--cpus INTEGER number of CPU cores to use in parallel (can speed</p><p>up processing lots of images). -1 means "use all in</p><p>system"</p><p>--tolerance FLOAT Tolerance for face comparisons. Default is 0.6.</p><p>Lower this if you get multiple matches for the same</p><p>person.</p><p>--show-distance BOOLEAN Output face distance. Useful for tweaking tolerance</p><p>setting.</p><p>--help Show this message and exit.</p></li><li><p>First create a new face picture folder '''known_people''' with a > known name, then copy two pictures to '''known_people''', and > then copy '''obama2.jpg''' to '''unknown.jpg''', which is the > picture we want to identify</p><p>orangepi@orangepi:~$ '''cd face_recognition/examples'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''mkdir known_people'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''cp biden.jpg obama.jpg known_people'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''cp obama2.jpg unkown.jpg'''</p></li><li><p>Then you can use the following command to identify install the name deb package of > the person in the '''unknown.jpg''' picture, and you can see > that the unknown.jpg picture is recognized as obamakernel header file</p><p>orangepi@orangepi:~/face_recognition/examples$ '''face_recognition known_people \'''</p><p>'''unkown.jpg'''</p><p>unkown.jpg,obama</p></li><li><p>If we identify an irrelevant image, unknown_person will be > displayed</p><p>root@orangepi:~/face_recognition/examples$ '''face_recognition known_people \'''</p><p>'''alex-lacamoire.png'''</p><p>alex-lacamoire.png,unknown_person</p></li><li><p>We can also create a new test folder and put multiple pictures > in it, and then we can use all the CPUs to recognize all the > pictures in parallel</p><p>orangepi@orangepi:~/face_recognition/examples$ '''mkdir test'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''cp *.jpg *.png test'''</p><p>orangepi@orangepi:~/face_recognition/examples$ '''face_recognition --cpus -1 \'''</p><p>'''known_people test'''</p><p>test/obama-240p.jpg,obama</p><p>test/alex-lacamoire.png,unknown_person</p><p>test/obama_small.jpg,obama</p><p>test/unkown.jpg,obama</p><p>test/obama2.jpg,obama</p><p>test/lin-manuel-miranda.png,unknown_person</p><p>test/two_people.jpg,biden</p><p>test/two_people.jpg,obama</p><p>test/obama-720p.jpg,obama</p><p>test/obama.jpg,obama</p><p>test/obama-480p.jpg,obama</p><p>test/biden.jpg,biden</p><p>test/obama-1080p.jpg,obama</p></li></ol></li></ol> <span id{| class="setting-chinese-environment-and-installing-chinese-input-methodwikitable"></span>== Setting Chinese environment and installing Chinese input method == '''Note, please make sure that the Linux system used by the development board is a desktop system before installing the Chinese input method。''' <span id="how-to-install-debian-system"></span>=== How to install Debian system === <ol style="list-style-typewidth: decimal800px;"><li><p>First set the default '''locale''' to Chinese</p><ol style="list-style-type: lower|-alpha;"><li><p>Enter the following command to start configuring the '''locale'''</p>| <p>orangepi@orangepi:~$ '''sudo dpkg-reconfigure locales'''<i /p><opt/li><li><p>Then select '''zh_CN.UTFlinux-8 UTF-8''' in the pop-up interface (move > up and down through the up and down direction keys on the > keyboard, select through the space bar, and finally move the > cursor to '''<OK>'''through the Tab key, and then press > Enter.)</p><p>[[File:media/image210headers*.png|575x296px]]</p></li><li><p>Then set the default '''locale''' to '''zh_CN.UTF-8deb'''</p><p>[[File:media/image211.png|575x160px]]</p></li><li><p>After exiting the interface, the '''locale''' setting will start, > and the output displayed on the command line is as follows</p><p>orangepi@orangepi:~$ '''sudo dpkg-reconfigure locales'''</p><p>Generating locales (this might take a while)...</p><p>en_US.UTF-8... done</p><p>zh_CN.UTF-8... done</p><p>Generation complete.</p></li></ol>}
</li>
<li><p>Then open After installation, you can see the folder where the kernel header files are located under '''Input Method/usr/src'''</p><p>[[File{| class="wikitable" style="width:media/image212.png800px;" |-|575x361px]]</p></li><li><p>Then choose orangepi@orangepi:~$ '''OKls /usr/src'''</p><p>[[File:media/image213linux-headers-x.x.png|295x212px]]x</p>|}</li><li><p>Then chooseyou can compile the source code of the hello kernel module that comes with the Linux image. The source code of the hello module is in '''Yes/usr/src/hello'''. After entering this directory, use the make command to compile.</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media~$ '''cd /usr/image214.png|303x192px]]src/hello/'''</p></li><li><p>Then chooseorangepi@orangepi:/usr/src/hello$ '''fcitxsudo make'''</p><p>[[File:mediamake -C /lib/modules/image2155.png|307x220px]]4.125/build M=/usr/src/hello modules</p></li><li><p>Then choose'''OK'make[1]: Entering directory '/usr/src/linux-headers-5.4.125'</p>:<p>CC [[File:mediaM] /usr/src/hello/image216hello.png|305x216px]]o</p></li><li>:<p>'''Then restart the Linux system to make the configuration take effect'''Building modules, stage 2.</p></li><li>:<p>Then open '''Fcitx configuration'''MODPOST 1 modules</p>:<p>CC [[File:mediaM] /usr/src/hello/image217hello.mod.png|575x376px]]o</p></li><li>:<p>Then click the + sign in the position shown in the figure belowLD [M] /usr/src/hello/hello.ko</p><p>make[[File1]:mediaLeaving directory '/image218usr/src/linux-headers-5.png|280x187px]]4.125'</p>|}</li><li><p>Then search After compiling, the '''Google Pinyinhello.ko''' and click kernel module will be generated</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:/usr/src/hello$ '''OKls *.ko'''</p><p>[[File:media/image219hello.png|291x196px]]ko</p>|}</li><li><p>Then bring Using the '''insmod''' command, you can insert the '''Google Pinyinhello.ko''' to kernel module into the frontkernel</p><p>[[File{| class="wikitable" style="width:media/image220.png800px;" |-|299x202px]]</p><p>[[Fileorangepi@orangepi:media/image221usr/src/hello$ '''sudo insmod hello.png|300x202px]]ko'''</p>|}</li><li><p>Then open use the '''Geanydemsg''' editor command to test view the output of the '''hello.ko''' kernel module. If you can see the Chinese input methodoutput instructions below, the '''hello.ko''' kernel module is loaded correctly</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media/image222.png|349x212px]]<usr/p><src/li><li><p>The Chinese input method test is as followshello$ '''dmesg | grep "Hello"'''</p><p>[[File:media/image2232871.png|575x325px893988]]</p></li><li><p>The Chinese and English input methods can be switched through the '''Ctrl+SpaceHello Orange Pi -- init''' shortcut key</p>|}</li><li><p>If Use the entire system needs to be displayed in Chinese, you can set the variables in '''/etc/default/localermmod''' command to uninstall the '''zh_CNhello.UTF-8ko'''kernel module</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~/usr/src/hello$ '''sudo vim /etc/default/localermmod hello'''</p><p># File generated by update-locale<orangepi@orangepi:/usr/src/p><p>LC_MESSAGES=hello$ '''zh_CN.UTF-8dmesg | grep "Hello"'''</p><p>LANG='''zh_CN[ 2871.UTF893988] Hello Orange Pi --8'''init</p><p>LANGUAGE=[ 3173.800892] '''zh_CN.UTFHello Orange Pi --8exit'''</p></li><li><p>Then '''restart the system''' and you can see that the system is displayed in Chinese</p>|}<p>[[File:media/image224.png|576x356px]]</p></li></ol>
<span id="howsome-toprogramming-installlanguage-ubuntutests-20.04supported-by-linux-system"></span>=== How to install Ubuntu 20.04 system ===
<ol style="list-style-type: decimal;">
<li><p>First open '''Language Support'''Debian Bullseye has a gcc compilation tool chain installed by default, which can directly compile C language programs in the Linux system of the development board</p><ol style="list-style-type: lower-alpha;"><li><p>[[FileThe version of gcc is as follows</p>{| class="wikitable" style="width:media/image225.png800px;" |-|575x351px]]</p>orangepi@orangepi:~$ '''gcc --version'''</lip><lip>gcc (Debian 10.2.1-6) 10.2.1 20210110</p>Then find the '''<span class="mark"p>Chinese Copyright (ChinaC)2020 Free Software Foundation, Inc.</spanp>''' option<p>This is free software; see the source for copying conditions. There is NO</p><p>[[File:media/image234warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.png|249x242px]]</p>|}</li><li><p>Then please use Write the left mouse button to select '''hello_world.c''' program in C language<span /p>{| class="markwikitable" style="width:800px;">Chinese (China)|-| </spanp>orangepi@orangepi:~$ '''vim hello_world.c''' and hold it down, then drag it up to the initial position, the display after dragging is as shown in the figure below:</p><p>[[File:media/image235#include <stdio.png|267x262px]]h></p></li></ol>
:</divp>return 0;</lip><li><p>The interface after selection is as shown below, and then click OK}</p><p>[[File:media/image239.png|366x290px]]</p>}</li><li><p>Then we can open compile and run '''Geanyhello_world.c''' to test the Chinese input method, the opening method is shown in the figure below</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media/image232~$ '''gcc -o hello_world hello_world.png|576x292px]]c'''</p></li><li><p>After opening orangepi@orangepi:~$ '''Geany''', the default is English input method, we can switch to Chinese input method through ''./hello_world'Ctrl+Space''' shortcut key, and then we can input Chinese</p><p>[[File:media/image240.png|434x308px]]Hello World!</p>|}</li></ol> <span id="how-to-remotely-log-in-to-the-desktop-of-linux-system"></spanli>== How to Remotely Log In to the Desktop of Linux System == <span id="remote-login-using-nomachine"li></spanp>=== Remote login using NoMachine === '''Make sure the Ubuntu or Debian system Bullseye comes with Python3 installed on the development board is a desktop system version. In addition, NoMachine also provides detailed documents. It is strongly recommended to read this document to be familiar with the use of NoMachine. The document link is shown below:''' '''https://knowledgebase.nomachine.com/DT10R00166''' '''NoMachine supports Windows, Mac, Linux, iOS and Android platforms, so we can remotely log in and control the Orange Pi development board through NoMachine on a variety of devices. The following demonstrates how to remotely log in to the Linux system desktop of the Orange Pi development board through NoMachine in Windows. For installation methods on other platforms, please refer to the official documentation of NoMachine''' '''Before operation, please make sure that the Windows computer and the development board are in the same LAN, and can log in to the Ubuntu or Debian system of the development board through ssh''' <ol style="list-style-type: decimal;"><li><p>First download the installation package of the NoMachine software Linux '''arm64''' deb version, and then install it into the Linux system of the development boardby default</p>
<ol style="list-style-type: lower-alpha;">
<li>Since H618 <p>The specific version of Python is a SOC of the ARMV8 architectureas follows</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''python3'''</p><p>'''Python 3.9.2''' (default, Feb 28 2021, 17:03:44)</p><p>[GCC 10.2.1 20210110] on linux</p><p>Type "help", "copyright", the system we use "credits" or "license" for more information.</p><p>>>> </p>|}{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <p>'''Use the Ctrl+D shortcut to exit python's interactive mode.'''</p>|}</li><li><p>Write '''hello_world.py''' program in Python language</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''vim hello_world.py'''</p><p>print('Hello World!')</p>|}</li><li><p>The result of running '''hello_world.py''' is Ubuntu or as follows</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''python3 hello_world.py'''</p><p>Hello World!</p>|}</li></ol></li><li><p>Debian Bullseye does not install Java compilation tools and runtime environment by default</p><ol style="list-style-type: lower-alpha;"><li><p>You can use the following command to install openjdk, the latest version in DebianBullseye is openjdk-17</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo apt install -y openjdk-17-jdk'''</p>|}</li><li><p>After installation, so you need to download can check the version of Java</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''java --version'''</p>|}</li><li><p>Edit '''hello_world.java of java version'''NoMachine </p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''vim hello_world.java'''</p><p>public class hello_world</p><p>{</p>:<p>public static void main(String[] args)</p>:<p>{</p>::<p>System.out.println("Hello World!>quot;); for ARM ARMv8 DEB</p>:<p>}</p><p>}</p>|}</li><li><p>Then compile and run''' installation packagehello_world. The download link is >java'''</p>{| class="wikitable" style="width:800px; shown below:" |-| <p>orangepi@orangepi:~$ '''javac hello_world.java'''</p><p>orangepi@orangepi:~$ '''java hello_world'''</p><p>Hello World!</p>|}</li></ol>
</li></ol>
<ol start="2" style="list-style-type: lower-alphadecimal;"><li><p>In additionDebian Bookworm is installed with a gcc compilation tool chain by default, which can directly compile C language programs in the installation package Linux system of '''NoMachine''' can also be > downloaded in the '''official tool'''development board</p><ol style="list-style-type: lower-alpha;"><li><p>[[File:media/image242.png|66x102px]]The version of gcc is as follows</p>{| class="wikitable" style="width:800px;" |-| <p>First enter the orangepi@orangepi:~$ '''<span class="mark">remote login softwaregcc --NoMachine</span>version''' folder</p><p>[[File:media/image243gcc (Debian 12.2.0-14) 12.2.png|271x43px]]0</p><p>Then download the arm64 version of the deb installation packageCopyright (C) 2022 Free Software Foundation, Inc.</p><p>[[File:media/image244This is free software; see the source for copying conditions.png|180x109px]]There is NO</p></li><li><p>Then upload the downloaded '''nomachine_x.xwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.x_x_arm64.deb''' to the > Linux system of the development board</p>|}</li><li><p>Then use Write the following command to install '''NoMachinehello_world.c''' program in the Linux > system of the development boardC language</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo dpkg -i nomachine_x.xvim hello_world.x_x_arm64_arm64.debc'''</p></lip>#include <stdio.h></olp>
</li></ol>
<ol style="list-style-type: lower-alpha;">
<li><p>The qt specific version that comes with Ubuntu 20.04 of Python is '''5.12.8'''as follows</p><p>orangepi@orangepi{| class="wikitable" style="width:~$ '''install_qt.sh'''</p>800px;" <p>......</p><p>QMake version 3.1</p><p>Using Qt version '''5.12.8''' in /usr/lib/aarch64|-linux-gnu</p></li><li><p>The QT version that comes with Ubuntu 22.04 is '''5.15.3'''</p>| <p>orangepi@orangepi:~$ '''install_qt.shpython3'''</p><p>Python 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2...0] on linux</p><p>QMake version 3Type "help", "copyright", "credits" or "license" for more information.1</p><p>Using Qt version '''5.15.3''' in /usr/lib/aarch64-linux-gnu>>></p></li><li><p>The QT version that comes with Debian11 is '''5.15.2'''</p>|}<p>orangepi@orangepi{| class="wikitable" style="background-color:#ffffdc;width:~$ '''install_qt.sh'''</p>800px;" <p>......</p>|-<p>QMake version 3.1</p><p>Using Qt version '''5.15.2''' in /usr/lib/aarch64-linux-gnu</p></li>| <libig><p>The QT version that comes with Debian12 is '''5.15.8''Use the Ctrl+D shortcut to exit python'</p><p>orangepi@orangepi:~$ '''install_qts interactive mode.sh'''</p><p>......</p><p>QMake version 3.1</pbig><p>Using Qt version '''5.15.8''' in /usr/lib/aarch64-linux-gnu</p></li></ol>|}
</li>
<li><p>Then you can see the QT Creator startup icon in Write '''Applicationshello_world.py'''program in Python language</p><p>[[File{| class="wikitable" style="width:media/image254.png800px;" |576x270px]]</p>-<p>You can also use the following command to open QT Creator</p>| <p>orangepi@orangepi:~$ '''qtcreatorvim hello_world.py'''</p><p>print('Hello World!')</p>|}</li><li><p>The interface after QT Creator is opened result of running '''hello_world.py''' is as follows</p>{| class="wikitable" style="width:800px;" |-| <p>[[Fileorangepi@orangepi:media~$ '''python3 hello_world.py'''</p><p>Hello World!</image255.pngp>|576x342px]]}</li></pol></li><li><p>The version of QT Creator is as followsDebian Bookworm does not install Java compilation tools and operating environment by default</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The default You can use the following command to install openjdk, the latest version of QT Creator in '''Ubuntu20.04''' Debian Bookworm is as > followsopenjdk-17</p><p>[[File{| class="wikitable" style="width:media/image256.png800px;" |-|419x224px]]</p></li><li><p>The default version of QT Creator in orangepi@orangepi:~$ '''Ubuntu22.04sudo apt install -y openjdk-17-jdk''' is as > follows</p><p>[[File:media/image257.png|443x237px]]</p>}</li><li><p>The default After installation, you can check the version of QT Creator in '''Debian11''' is as followsJava</p><p>[[File{| class="wikitable" style="width:media/image258.png800px;" |-|444x238px]]</p></li><li><p>The default version of QT Creator in orangepi@orangepi:~$ '''Debian12java --version''' is as follows</p><p>[[File:media/image259.png|449x277px]]</p></li></ol>}
</li>
<li><p>Then set up QTEdit the Javaverison’s '''hello_world.java'''</p><ol {| class="wikitable" style="list-style-typewidth: lower-alpha800px;"><li>|-| <p>First open '''Help'''->orangepi@orangepi:~$ '''About Pluginsvim hello_world.…java'''</p><p>[[File:media/image260.png|573x164px]]public class hello_world</p></li><li><p>Then remove the tick of '''ClangCodeModel'''{</p>:<p>public static void main(String[[File:media/image261.png|408x254px]]args)</p></li><li>:<p>'''After setting, you need to restart QT Creator'''{</p></li><li>::<p>Then make sure the GCC compiler used by QT Creator, if the System.out.println("Hello World!>quot;); default is Clang, please modify it to GCC</p>:<p>'''Debian12 please skip this step.'''}</p><p>[[File:media/image262.png|576x315px]]}</p><p>[[File:media/image263.png|575x307px]]</p></li></ol>}
</li>
<li><p>Then you can open a sample code</p><p>[[File:media/image264.png|575x312px]]</p></li><li><p>After clicking the sample code, the corresponding instruction document will be opened automatically, you can read the instructions carefully</p><p>[[File:media/image265.png|576x218px]]</p></li><li><p>Then click compile and run'''Configure Projecthello_world.java'''</p><p>[[File{| class="wikitable" style="width:media/image266.png|575x304px]]</p></li><li><p>Then click the green triangle in the lower left corner to compile and run the sample code</p>800px;" <p>[[File:media/image267.png|575x312px]]</p></li>-<li><p>After waiting for a period of time, the interface shown in the figure below will pop up, which means that QT can compile and run normally</p><p>[[File:media/image268.png|576x308px]]</p></li><li><p>References</p><p>[httpsorangepi@orangepi://wiki.qt.io/Install_Qt_5_on_Ubuntu ~$ '''https://wiki.qtjavac hello_world.io/Install_Qt_5_on_Ubuntujava''']</p><p>[httpsorangepi@orangepi://download.qt.io/archive/qtcreator ~$ '''https://download.qt.io/archive/qtcreatorjava hello_world''']</p><p>[https://download.qt.io/archive/qt '''https://download.qt.io/archive/qt''']Hello World!</p>|}</li></ol> <span id="how-to-install-ros"></span>== How to install ROS == <span id="how-to-install-ros-1-noetic-on-ubuntu-20.04"li></spanol>=== How to install ROS 1 Noetic on Ubuntu 20.04 ===
:<p>return 0;</p><p>}</p>|}</li><li><p>Then compile and run '''Note that running the following command needs to ensure that the development board can access github normally, otherwise an error will be reported due to network problemshello_world.c'''</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''The install_ros.sh script will try to modify /etc/hosts and run the following commands automaticallygcc -o hello_world hello_world. However, this method cannot guarantee that github can be accessed normally every time. If install_ros.sh prompts the following error after installing ros1, please find other ways to allow the linux system of the development board to access github normally, and then manually run the following command。c'''</p> <p>orangepi@orangepi:~$ '''https:./hello_world'''</raw.githubusercontent.comp><p>Hello World!</rosp>|}</rosdistroli></masterol></rosdepli><li><p>Ubuntu Focal has Python3 installed by default</osxp><ol style="list-homebrew.yamlstyle-type: lower-alpha;"><li><p>The specific version of Python3 is as follows</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ ''' python3'''Hit https</p><p>Python 3.8.10 (default, Nov 14 2022, 12:59:47)<//rawp><p>[GCC 9.githubusercontent4.com0] on linux</rosp><p>Type "help", "copyright", "credits" or "license" for more information.</rosdistrop><p>>>></master/rosdep/base.yaml'''p>|}{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''Use the Ctrl+D shortcut to exit python'ERROR: error loading sources list:s interactive mode.'''</p></big>|}</li><li><p>Write the '''The read operation timed outhello_world.py'''program in Python language</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''source vim hello_world.py'''</optp><p>print('Hello World!')</rosp>|}</noetic/setupli><li><p>The result of running '''hello_world.bashpy'''is as follows</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo rosdep initpython3 hello_world.py'''</p><p>Hello World!</p>|}Wrote </etcli></rosol></rosdepli><li><p>Ubuntu Focal does not install Java compilation tools and operating environment by default</sources.p><ol style="list.d/20-default.liststyle-type: lower-alpha;"><li><p>You can use the following command to install openjdk-17</p>Recommended{| class="wikitable" style="width: please run800px;" |-rosdep update| <p>orangepi@orangepi:~$ '''rosdep updatesudo apt install -y openjdk-17-jdk'''</p>|}reading in sources list data from </etcli><li><p>After installation, you can check the version of Java</ros/rosdep/sources.list.dp>{| class="wikitable" style="width:800px;" |-| Hit https<p>orangepi@orangepi:~$ '''java --version'''</p><p>openjdk 17.0.2 2022-01-18</rawp><p>OpenJDK Runtime Environment (build 17.0.githubusercontent2+8-Ubuntu-120.com04)</rosp><p>OpenJDK 64-Bit Server VM (build 17.0.2+8-Ubuntu-120.04, mixed mode, sharing)</rosdistrop>|}</masterli><li><p>Write the Java version of '''hello_world.java'''</rosdep/osxp>{| class="wikitable" style="width:800px;" |-homebrew.yaml| Hit https<p>orangepi@orangepi://raw~$ '''vim hello_world.githubusercontent.comjava'''</rosp><p>public class hello_world</rosdistrop><p>{</masterp>:<p>public static void main(String[] args)</rosdepp>:<p>{</base.yamlp> Hit https://raw:<p>System.githubusercontentout.comprintln("Hello World!");</rosp>:<p>}</rosdistrop><p>}</masterp>|}</rosdepli><li><p>Then compile and run '''hello_world.java'''</python.yamlp>{| class="wikitable" style="width:800px;" |-| Hit https<p>orangepi@orangepi:~$ '''javac hello_world.java'''</p><p>orangepi@orangepi:~$ '''java hello_world'''</raw.githubusercontent.comp><p>Hello World!</rosp>|}</rosdistroli></masterol></rosdepli></ruby.yamlol>
<ol style="list-style-type: decimal;">
<li><p>The currently active version Use the scp command to upload files from the Ubuntu PC to the Linux system of ROS 2 is shown below, and the recommended version is '''Galactic Geochelone'''</p><p>[[File:media/image275development board.png|576x271px]]The specific commands are as follows</p><p>[[Fileol style="list-style-type:media/image276.png|575x265px]]</plower-alpha;"><pli>[http://docs.ros.org/ '''http://docs.ros.org''']</p><p>'''httpfile_path://docs.ros.org/en/galactic/Releases.html'''Need to be replaced with the path of the file to be uploaded</p></li><li><p>The link to the official ROS 2 '''Galactic Geocheloneorangepi:''' installation documentation It is the user name of the Linux system of the development board, and it can also be replaced with other ones, such as follows:root</p><p/li>'''docs.ros.org/en/galactic/Installation.html'''</pli><p>'''http://docs192.ros168.org/en/galactic/Installation/Ubuntu-Install-Debiansxx.htmlxx:'''It is the IP address of the development board, please modify it according to the actual situation</p></li><li><p>In the official ROS 2 '''Galactic Geochelone/home/orangepi:''' installation document, Ubuntu The path in the Linux recommends using Ubuntu 20.04, so please make sure that the system used by of the development board is the '''Ubuntu 20.04 desktop system'''. There are several ways can also be modified to install ROS 2. The following demonstrates how to install ROS 2 '''other paths<span /p>{| class="markwikitable">Galactic Geochelone</span>''' through '''<span classstyle="markwidth:800px;">Debian packages</span>'''.</p></li><li><p>Ros2 can be installed using the '''install_ros.sh''' script</p>|-| <p>orangepitest@orangepitest:~$ '''install_rosscp file_path orangepi@192.sh ros2'''</p></li><li><p>The '''install_ros168.sh''' script will automatically run the '''ros2 -h''' command after installing ros2xx. If you can see the following print, it means that the ros2 installation is complete</p><p>usagexx: ros2 [-h] Call `ros2 <command> -h` for more detailed usage. ...</p><p>ros2 is an extensible command-line tool for ROS 2.<home/p><p>optional arguments:<orangepi/p><p>-h, --help show this help message and exit'''</p><p>Commands:</p>|}<p>action Various action related sub-commands</pli><p>bag Various rosbag related sub-commands</pol><p>component Various component related sub-commands</pli><pli>daemon Various daemon related sub-commands</p><p>doctor Check ROS setup and other potential issues</p><p>interface Show information about ROS interfaces</p><p>launch Run If you want to upload a launch file</p><p>lifecycle Various lifecycle related subfolder, you need to add the -commandsr parameter</p><p>multicast Various multicast related sub-commands</p>{| class="wikitable" style="width:800px;" <p>node Various node related sub|-commands</p><p>param Various param related sub-commands</p>| <p>pkg Various package related sub-commands</p><p>run Run a package specific executable</p><p>security Various security related sub-commands</p><p>service Various service related sub-commands</p><p>topic Various topic related sub-commands</p><p>wtf Use `wtf` as alias to `doctor`</p><p>Call `ros2 <command> -h` for more detailed usage.</p></li><li><p>Then you can use the '''test_ros.sh''' script to test whether ROS 2 is installed successfully. If you can see the following print, it means that ROS 2 can run normally</p><p>orangepi@orangepitest:~$ '''test_ros.sh'''scp </pspan style="color:#FF0000">-r<p/span>[INFO] [1671174101dir_path orangepi@192.200091527] [talker]: Publishing: 'Hello World: 1'</p><p>[INFO] [1671174101168.xx.235661048] [listener]xx: I heard: [Hello World: 1]</p><p>[INFO] [1671174102.199572327] [talker]: Publishing: 'Hello World: 2'<home/p><p>[INFO] [1671174102.204196299] [listener]: I heard: [Hello World: 2]<orangepi/p><p>[INFO] [1671174103.199580322] [talker]: Publishing: 'Hello World: 3''</p><p>[INFO] [1671174103.204019965] [listener]: I heard: [Hello World: 3]</p>|}</li><li><p>Run There are more usages of scp, please use the following command to open rviz2view the man manual</p><p/li>orangepi@orangepi {| class="wikitable" style="width:~$ '''source /opt/ros/galactic/setup.bash'''</p>800px;" |-| <p>orangepitest@orangepitest:~$ '''ros2 run rviz2 rviz2man scp'''</p><p>[[File:media/image277.png|576x324px]]}</p></liol><li><p>For span id="how -to use ROS, please refer to the documentation of ROS 2</p-upload-files-using-filezilla"><p>[http://docs.ros.org/en/galactic/Tutorials.html '''http://docs.ros.org/en/galactic/Tutorials.html''']</p></li></olspan>
<ol style="list-style-type: decimal;">
<li><p>Ros2 can be installed using the '''install_ros.sh''' scriptFirst install filezilla in Ubuntu PC</p><p>orangepi@orangepi:~$ '''install_ros.sh ros2'''</p></li><li><p>The '''install_ros.sh''' script will automatically run the '''ros2 -h''' command after installing ros2. If you can see the following print, it means that the ros2 installation is complete</p><p>usage{| class="wikitable" style="width: ros2 [-h] Call `ros2 <800px;command> -h` for more detailed usage. ...</p>" <p>ros2 is an extensible command|-line tool for ROS 2.</p><p>optional arguments:</p><p>-h, --help show this help message and exit</p><p>Commands:</p><p>action Various action related sub-commands</p><p>bag Various rosbag related sub-commands</p><p>component Various component related sub-commands</p><p>daemon Various daemon related sub-commands</p><p>doctor Check ROS setup and other potential issues</p><p>interface Show information about ROS interfaces</p><p>launch Run a launch file</p><p>lifecycle Various lifecycle related sub-commands</p><p>multicast Various multicast related sub-commands</p><p>node Various node related sub-commands</p><p>param Various param related sub-commands</p><p>pkg Various package related sub-commands</p><p>run Run a package specific executable</p><p>security Various security related sub-commands</p><p>service Various service related sub-commands</p><p>topic Various topic related sub-commands</p><p>wtf Use `wtf` as alias to `doctor`</p><p>Call `ros2 <command> -h` for more detailed usage.</p></li>| <li><p>Then you can use the '''test_ros.sh''' script to test whether ROS 2 is installed successfully. If you can see the following print, it means that ROS 2 can run normally</p><p>orangepi@orangepitest:~$ '''test_ros.shsudo apt install -y filezilla'''</p><p>[INFO] [1671174101.200091527] [talker]: Publishing: 'Hello World: 1'</p>|}<p>[INFO] [1671174101.235661048] [listener]: I heard: [Hello World: 1]</p><p>[INFO] [1671174102.199572327] [talker]: Publishing: 'Hello World: 2'</p><p>[INFO] [1671174102.204196299] [listener]: I heard: [Hello World: 2]</p><p>[INFO] [1671174103.199580322] [talker]: Publishing: 'Hello World: 3'</p><p>[INFO] [1671174103.204019965] [listener]: I heard: [Hello World: 3]</p></li><li><p>Run Then use the following command to open rviz2filezilla</p><p>orangepi@orangepi{| class="wikitable" style="width:~$ '''source /opt/ros/humble/setup.bash'''</p>800px;" |-| <p>orangepitest@orangepitest:~$ '''ros2 run rviz2 rviz2filezilla'''</p><p>[[File:media/image278.png|575x323px]]</p>}</li><li><p>Reference documentsThe interface after filezilla is opened is as follows, at this time, the display under the remote site on the right is empty</p><p>'''http://docs.ros.org/en/humble/index.html'''</pdiv class="figure"><p>[[httpFile://docs.ros.org/en/galactic/Tutorials.html '''http://docs.ros.org/en/humble/Installation/Ubuntuzero3-Install-Debiansimg279.html'''png]]</p></li></ol>
<span id="how-to-install-the-kernel-header-file"/div></spanli>== How to install <li><p>The method of connecting the kernel header file ==development board is shown in the figure below</p>
<span id/div></li></ol><ol start="5" style="somelist-programmingstyle-language-tests-supported-by-linux-systemtype: decimal;"><li><p>Then choose to '''<span class="mark">save the password</span>''', and then click '''<span class="mark">OK</span>'''</p><p>[[File:zero3-img281.png]]</p></li><li><p>Then choose to '''<span class="mark">always trust this host</span>''', and then click '''<span class= Some programming language tests supported by Linux system =="mark">OK</span>'''</p>
<span iddiv class="debian-bullseye-systemfigure"></span>=== Debian Bullseye System ===
<span id/div></li></ol><ol start="7" style="debianlist-bookwormstyle-systemtype: decimal;"></spanli>=== Debian Bookworm System ===After the connection is successful, you can see the directory structure of the development board linux file system on the right side of the filezilla software
<ol style="list-style-type: decimal;"><li><p>Debian Bookworm is installed with a gcc compilation tool chain by default, which can directly compile C language programs in the Linux system of the development board</p><ol stylediv class="list-style-type: lower-alpha;figure"><li><p>The version of gcc is as follows</p><p>orangepi@orangepi:~$ '''gcc --version'''</p><p>gcc (Debian 12.2.0-14) 12.2.0</p><p>Copyright (C) 2022 Free Software Foundation, Inc.</p><p>This is free software; see the source for copying conditions. There is NO</p><p>warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p></li><li><p>Write the '''hello_world.c''' program in C language</p><p>orangepi@orangepi:~$ '''vim hello_world.c'''</p><p>#include <stdio.h></p><p>int main(void)</p><p>{</p><p>printf("Hello World!\n");</p><p>return 0;</p><p>}</p></li><li><p>Then compile and run '''hello_world.c'''</p><p>orangepi@orangepi:~$ '''gcc -o hello_world hello_world.c'''</p><p>orangepi@orangepi:~$ '''./hello_world'''</p><p>Hello World!</p></li></ol></li><li><p>Debian Bookworm has Python3 installed by default</p><ol style="list-style-type: lower-alpha;"><li><p>The specific version of Python is as follows</p><p>orangepi@orangepi:~$ '''python3'''</p><p>Python 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0] on linux</p><p>Type "help", "copyright", "credits" or "license" for more information.</p><p>>>></p><p>'''Use the Ctrl+D shortcut to exit python's interactive mode。'''</p></li><li><p>Write '''hello_world.py''' program in Python language</p><p>orangepi@orangepi:~$ '''vim hello_world.py'''</p><p>print('Hello World!')</p></li><li><p>The result of running '''hello_world.py''' is as follows</p><p>orangepi@orangepi:~$ '''python3 hello_world.py'''</p><p>Hello World!</p></li></ol></li><li><p>Debian Bookworm does not install Java compilation tools and operating environment by default</p><ol style="list-style-type: lower-alpha;"><li><p>You can use the following command to install openjdk, the latest > version in Debian Bookworm is openjdk-17</p><p>orangepi@orangepi:~$ '''sudo apt install -y openjdk-17-jdk'''</p></li><li><p>After installation, you can check the version of Java</p><p>orangepi@orangepi:~$ '''java --version'''</p></li><li><p>Edit the Javaverison’s '''hello_world.java'''</p><p>orangepi@orangepi:~$ '''vim hello_world.java'''</p><p>public class hello_world</p><p>{</p><p>public static void main(String[] args)</p><p>{</p><p>System.out.println("Hello World!");</p><p>}</p><p>}</p></li><li><p>Then compile and run'''hello_world.java'''</p><p>orangepi@orangepi:~$ '''javac hello_world.java'''</p><p>orangepi@orangepi:~$ '''java hello_world'''</p><p>Hello World!</p></li></ol></li></ol>
</div></li></ol ><ol start="8" style="list-style-type: decimal;"><li><p>Then select the path to be uploaded to the development board on the right side of the filezilla software, and then select the file to be uploaded on the Ubuntu Focal has a gcc compilation tool chain installed by defaultPC on the left side of the filezilla software, then click the right mouse button, which can directly compile C language programs in and then click the upload option to start uploading the Linux system of file to the development board. <div class="figure"> [[File:zero3-img284.png]] </div></li></pol><ol start="9" style="list-style-type: lower-alphadecimal;"><li><p>The version After the upload is complete, you can go to the corresponding path in the Linux system of a.gcc is as followsthe development board to view the uploaded files</p><p>orangepi@orangepi:~$ '''gcc --version'''</pli><pli>gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0</p><p>Copyright (C) 2019 Free Software FoundationThe method of uploading a folder is the same as that of uploading a file, Inc.so I won't go into details here</p><p/li>This is free software; see the source for copying conditions. There is NO</pol> <pspan id="how-to-upload-files-to-the-development-board-linux-system-in-windows-pc">warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p></lispan> === How to upload files to the development board Linux system in Windows PC === <lispan id="how-to-upload-files-using-filezilla-1"><p/span>Write ==== How to upload files using filezilla ==== # First download the installation file of the Windows version of the filezilla software, the download link is as follows ::{| class="wikitable" style="width:800px;" |-| '''hello_worldhttps://filezilla-project.c''' program in C language<org/p><p>orangepi@orangepi:~$ '''vim hello_worlddownload.cphp?type=client'''</p><p>#include <stdio|} ::[[File:zero3-img285.h></p>png]]<p>int main(void)</p><p>{</p>::[[File:zero3-img286-1.png]]<p>printf("Hello World!\n");</p><p>return 0ol start="2" style="list-style-type: decimal;</p><p>}</p></li"><li><p>Then compile The downloaded installation package is as follows, and run '''hello_world.c'''then double-click to install directly</p><p>orangepi@orangepi{| class="wikitable" style="width:~$ '''gcc 800px;" |-o hello_world hello_world.c'''</p>| <p>orangepi@orangepi:~$ '''FileZilla_Server_1./hello_world5.1_win64-setup.exe'''</p><p>Hello World!</p></li></ol>|}
</li>
<li><p>Ubuntu Focal has Python3 installed by defaultDuring the installation process, please select </p><ol stylespan class="list-style-type: lower-alpha;mark"><li><p>The specific version of Python3 is as follows</p><p>orangepi@orangepi:~$ '''python3'''Decline</pspan><p>Python 3.8.10 (default, Nov 14 2022, 12:59:47)</p><p>[GCC 9.4.0] on linux</p><p>Type "help"the following installation interface, "copyright", "credits" or "license" for more information.and then select </p><pspan class="mark">Next>>></p><p>'''Use the Ctrl+D shortcut to exit python's interactive mode.'''</pspan></li><li><p>Write the '''hello_world.py''' program in Python language</p><p>orangepi@orangepi:~$ '''vim hello_world.py'''</p><p>print('Hello World!')</p></lidiv class="figure"><li><p>The result of running '''hello_world.py''' is as follows</p><p>orangepi@orangepi[[File:~$ '''python3 hello_worldzero3-img287.py'''</p>png]] <p>Hello World!</pdiv></li></ol></li><li><p>Ubuntu Focal does not install Java compilation tools and operating environment by default</p><ol start="4" style="list-style-type: lower-alphadecimal;"><li><p>You can use The interface after filezilla is opened is as follows, and the following command to install openjdk-17</p><p>orangepi@orangepi:~$ '''sudo apt install -y openjdk-17-jdk'''</p></li><li><p>After installation, you can check display under the version of Java</p><p>orangepi@orangepi:~$ '''java --version'''</p><p>openjdk 17.0.2 2022-01-18</p><p>OpenJDK Runtime Environment (build 17.0.2+8-Ubuntu-120.04)</p><p>OpenJDK 64-Bit Server VM (build 17.0.2+8-Ubuntu-120.04, mixed mode, sharing)</p></li><li><p>Write remote site on the Java version of '''hello_world.java'''</p>right is empty<p>orangepi@orangepi:~$ '''vim hello_world.java'''</p><p>public div class hello_world</p><p>{</p><p>public static void main(String[] args)</p><p>{</p><p>System.out.println("Hello World!");</p><p>}</p><p>}</p></li><li><p>Then compile and run '''hello_world.java'''</p><p>orangepi@orangepi:~$ '''javac hello_world.java'''</p><p>orangepi@orangepi:~$ '''java hello_world'''</p><p>Hello World!</p></li></ol></li></ol="figure">
<ol style="list-style-type: decimal;"/div></li><p>Ubuntu Jammy is installed with a gcc compilation tool chain by default, which can directly compile C language programs in the Linux system of the development board</pol><ol stylestart="list-style-type: lower-alpha;5"><li><p>The version of a.gcc is as follows</p><p>orangepi@orangepi:~$ '''gcc --version'''</p><p>gcc (Ubuntu 11.3.0-1ubuntu1~22.04.1) '''11.3.0'''</p><p>Copyright (C) 2021 Free Software Foundation, Inc.</p><p>This is free software; see the source for copying conditions. There is NO</p><p>warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p></li><li><p>Write the '''hello_world.c''' program in C language</p><p>orangepi@orangepi:~$ '''vim hello_world.c'''</p><p>#include <stdio.h></p><p>int main(void)</p><p>{</p><p>printf("Hello World!\n");</p><p>return 0;</p><p>}</p></li><li><p>Then compile and run '''hello_world.c'''</p><p>orangepi@orangepi:~$ '''gcc -o hello_world hello_world.c'''</p><p>orangepi@orangepi:~$ '''./hello_world'''</p><p>Hello World!</p></li></ol></li><li><p>Ubuntu Jammy has Python3 installed by default</p><ol style="list-style-type: lower-alphadecimal;"><li><p>The specific version method of Python3 connecting the development board is as follows</p><p>orangepi@orangepi:~$ '''python3'''</p><p>Python 3.10.6 (main, May 29 2023, 11:10:38) [GCC 11.3.0] on linux</p><p>Type "help", "copyright", "credits" or "license" for more information.</p><p>>>></p><p>'''Use the Ctrl+D shortcut to exit python's interactive mode.'''</p></li><li><p>Write the '''hello_world.py''' program shown in Python language</p><p>orangepi@orangepi:~$ '''vim hello_world.py'''</p><p>print('Hello World!')</p></li><li><p>The result of running '''hello_world.py''' is as follows</p><p>orangepi@orangepi:~$ '''python3 hello_world.py'''</p><p>Hello World!</p></li></ol></li><li><p>Ubuntu Jammy does not install Java compilation tools and operating environment by default</p><ol style="list-style-type: lower-alpha;"><li><p>You can use the following command to install openjdk-18</p><p>orangepi@orangepi:~$ '''sudo apt install -y openjdk-18-jdk'''</p></li><li><p>After installation, you can check the version of Java</p><p>orangepi@orangepi:~$ '''java --version'''</p><p>openjdk 18.0.2-ea 2022-07-19</p><p>OpenJDK Runtime Environment (build 18.0.2-ea+9-Ubuntu-222.04)</p><p>OpenJDK 64-Bit Server VM (build 18.0.2-ea+9-Ubuntu-222.04, mixed mode, sharing)</p></li><li><p>Write the Java version of '''hello_world.java'''</p><p>orangepi@orangepifigure below:~$ '''vim hello_world.java'''</p><p>public class hello_world</p><p>{</p><p>public static void main(String[] args)</p><p>{</p><p>System.out.println("Hello World!");</p><p>}</p><p>}</p></li><li><p>Then compile and run '''hello_world.java'''</p><p>orangepi@orangepi:~$ '''javac hello_world.java'''</p><p>orangepi@orangepi:~$ '''java hello_world'''</p><p>Hello World!</p></li></ol></li></ol>
<span iddiv class="the-method-of-uploading-files-to-the-linux-system-of-the-development-boardfigure"></span>== The method of uploading files to the Linux system of the development board ==
<span id="how-to-upload-files-using-the-scp-command"/div></span>==== How to upload files using the scp command ==== <ol style="list-style-type: decimal;"><li><p>Use the scp command to upload files from the Ubuntu PC to the Linux system of the development board. The specific commands are as follows</pol><ol start="6" style="list-style-type: lower-alphadecimal;"><li><p>''Then choose to 'file_path:'''Need to be replaced with the path of the file to > be uploaded</pspan class="mark">save the password</li><li><pspan>'''orangepi:''' It is the user name of the Linux system of the > development board, and it can also be replaced with other > ones, such as root</p></li><li><p>'''192.168.xx.xx:''' It is the IP address of the development > board, please modify it according to the actual situation</p></li><li><p>'''/home/orangepi:then click ''' The path in the Linux system of the > development board can also be modified to other paths</pspan class="mark">OK<p>test@test:~$ '''scp file_path orangepi@192.168.xx.xx:/home/orangepi/'''</p></lispan></ol></li><li><p>If you want to upload a folder, you need to add the -r parameter</p><p>test@test:~$ '''scp -r dir_path orangepi@192.168.xx.xx:/home/orangepi/'''</p></li><li><p>There are more usages of scp, please use the following command to view the man manual</p></li></ol>
<div class="figure">
[[File:media/image279zero3-img289.png|576x453px|截图 2022-12-03 19-04-40]]
</div></li></ol><ol start="7" style="list-style-type: decimal;"><li>Then select '''<pspan class="mark">The method of connecting the development board is shown in the figure belowAlways trust this host</pspan>''', and click '''</lispan class="mark">OK</olspan>'''
<div class="figure">
[[File:media/image280zero3-img290.png|575x128px|图片565]]
</div></li></ol><ol start="58" style="list-style-type: decimal;"><li><p>Then choose select the path to be uploaded to '''<span class="mark">save the password</span>'''development board on the right side of the filezilla software, and then select the file to be uploaded on the Windows PC on the left side of the filezilla software, then click '''<span class="mark">OK</span>'''</p><p>[[File:media/image281.png|249x181px]]</p></li><li><p>Then choose to '''<span class="mark">always trust this host</span>'''the right mouse button, and then click '''<span class="mark">OK</span>'''</p></li></ol>the upload option to start uploading the file to the development board.
<div class="figure">
[[File:media/image282zero3-img291.png|278x150px|IMG_256]]
</div></li></ol><ol start="79" style="list-style-type: decimal;"><li>After Then select the connection is successful, you can see path to be uploaded to the development board on the directory structure right side of the development board linux filezilla software, and then select the file system to be uploaded on the right Windows PC on the left side of the filezilla software</li></ol>, then click the right mouse button, and then click the upload option to start uploading the file to the development board bingo
<div class="figure">
[[File:media/image283zero3-img292.png|533x330px|IMG_256]]
</div></li></ol><ol start="810" style="list-style-type: decimal;"><li>Then select <p>After the path to be uploaded upload is complete, you can go to the development board on corresponding path in the right side Linux system of the filezilla software, and then select development board to view the file to be uploaded in files</p></li><li><p>The method of uploading a folder is the Ubuntu PC on the left side same as that of the filezilla software, then click the right mouse button, and then click the upload option to start uploading the a file to the development board bingo., so I won't go into details here</p></li></ol>
<div classspan id="figureinstructions-for-using-the-switch-logo"></span>
<span id="how-to-uploadshut-filesdown-toand-restart-the-development-board-linux-system-in-windows-pc"></span>=== How to upload files to the development board Linux system in Windows PC ===
<ol start="2" stylespan id="listcompilation-stylesystem-type: decimal;requirements"><li><p>The downloaded installation package is as follows, and then double-click to install directly</pspan><p>'''FileZilla_Server_1.5.1_win64-setup.exe'''</p></li><li><p>During the installation process, please select <span class="mark">Decline</span> on the following installation interface, and then select <span class="mark">Next></span></p></li></ol>Compilation system requirements ==
The Linux SDK, '''orangepi-build''', only supports running on X64 computers with '''<div classspan style="figurecolor:#FF0000">Ubuntu 22.04</span>''' installed, so before downloading orangepi-build, please make sure that the Ubuntu version installed on your computer is Ubuntu 22.04. The command to check the Ubuntu version installed on the computer is as follows. If the Release field does not display '''<span style="color:#FF0000">22.04</span>''', it means that the current Ubuntu version does not meet the requirements. Please replace the system before performing the following operations.
Release: '''</div><ol start="5" span style="list-style-typecolor: decimal;#FF0000"><li>The method of connecting the development board is shown in the figure below:</li>22.04</olspan>'''
<div classspan id="figureget-the-source-code-of-linux-sdk"></span>
</div><ol startspan id="7" style="listdownload-orangepi-build-stylefrom-type: decimal;github"><li>Then select '''<span class="mark">Always trust this host</span>''', and click '''<span class=== Download orangepi-build from github ==="mark">OK</span>'''</li></ol>
test@test:~$ '''git clone https://github.com/orangepi-xunlong/orangepi-build.git <div classspan style="figurecolor:#FF0000">-b next</span>'''|}
<div class="figure">
[[File:media/image292zero3-img294.png|461x340px780px|IMG_256center]]
</div>
|-
| style="text-align: left;"| <p>'''branchgcc-arm-11.2-2022.02-x86_64-aarch64-none-linux-gnu'''</p>| }</li></ol><p>The cross-compilation toolchain used to compile the H618 u-boot source code is:</p><!-- --><ol style="textlist-style-aligntype: leftlower-alpha;"| '''u-boot version'''><li><p>v2018.05</p>{| class="wikitable" style="text-alignwidth: left800px;"| '''Linux kernel version'''
|-
| style="text-align: left;"| <p>'''currentgcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi'''</p>|}</li><li><p>v2021.07</p>{| styleclass="text-align: left;wikitable"| '''u-boot v2018.05'''| style="text-alignwidth: left800px;"| '''linux5.4'''
|-
| style="text-align: left;"| ''<p>'next'''| style="textgcc-align: left;"| '''uarm-boot v202111.07'''| style="text2-align: left;"| '''linux62022.102-x86_64-aarch64-none-linux-gnu'''</p>
|}
</li></ol>
<ol start="2" style="list-style-type: decimal;">
<li><p>When orangepi-build runs for the first time, it will download the cross-compilation toolchain, u-boot and linux kernel source code. After successfully compiling a linux image, the files and folders that can be seen in orangepi-build are:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>'''build.sh''': Compile the startup script</p></li>
<li><p>'''external''': Contains the configuration files needed to compile for compiling the > image, scripts for specific scriptsfunctions, and the source code of some programs, > etc.The rootfs compressed package cached during the compiling process is also stored in external</p></li><li><p>'''kernel''': Store the source code of the linux kernel</p></li>
<li><p>'''LICENSE''': GPL 2 license file</p></li>
<li><p>'''README.md''': orangepi-build documentation</p></li>
<li><p>'''output''': Store compiled u-boot, linux and other deb packages, compilation logs, and compiled images and other files</p></li><li><p>'''scripts''': General script for compiling linux images</p></li><li><p>'''toolchains''': Store the cross-compilation toolchain</p></li><li><p>'''u-boot''': Store the source code of u-boot</p></li><li><p>'''userpatches''': Store the configuration files needed to compile the script</p>{| class="wikitable" style="width:800px;" |-|
<p>test@test:~/orangepi-build$ '''ls'''</p>
<p>'''build.sh external kernel LICENSE output README.md scripts toolchains u-boot userpatches'''</p>|}<p/li>'''If you downloaded the code of orangepi-build from github, after downloading, you may find that orangepi-build does not contain the source code of u-boot and linux kernel, nor does u-boot and linux kernel need to use cross-compilation tools Chain, this is normal, because these things are stored in other separate github warehouses or some servers (the addresses will be detailed below). orangepi-build will specify the address of u-boot, linux kernel and cross-compilation toolchain in the script and configuration file. When running orangepi-build, when it finds that there are no such things locally, it will automatically go to the corresponding place to download them.'''</pol></li></ol>
<span id="downloadcompile-theu-cross-compilation-toolchainboot"></span>=== Download the cross-compilation toolchain ===
<ol style="list-style-type: decimal;">
<li><p>Run the build.sh script, remember to add sudo permission</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~/orangepi-build$ '''sudo ./build.sh'''</p>
|}
</li>
<li><p>Select '''U-boot package''', then press Enter</p>
<div class="figure">
[[File:media/image295zero3-img296.png|575x278px|选区_396]] </div>The mirror URL of the cross-compilation toolchain in China is the open source software mirror site of Tsinghua University: [https://mirrors.tuna.tsinghua.edu.cn/armbian-releases/_toolchain/ '''https://mirrors.tuna.tsinghua.edu.cn/armbian-releases/_toolchain/'''] After the '''toolchains''' are downloaded, it will contain multiple versions of the cross-compilation toolchain: test@test:~/orangepi-build$ '''ls toolchains/''' gcc-arm-11.2-2022.02-x86_64-aarch64-none-linux-gnu gcc-linaro-4.9.4-2017.01-x86_64_aarch64-linux-gnu gcc-linaro-7.4.1-2019.02-x86_64_arm-linux-gnueabi gcc-arm-11.2-2022.02-x86_64-arm-none-linux-gnueabihf gcc-linaro-4.9.4-2017.01-x86_64_arm-linux-gnueabi gcc-linaro-aarch64-none-elf-4.8-2013.11_linux gcc-arm-9.2-2019.12-x86_64-aarch64-none-linux-gnu gcc-linaro-5.5.0-2017.10-x86_64_arm-linux-gnueabihf gcc-linaro-arm-linux-gnueabihf-4.8-2014.04_linux gcc-arm-9.2-2019.12-x86_64-arm-none-linux-gnueabihf gcc-linaro-7.4.1-2019.02-x86_64_aarch64-linux-gnu gcc-linaro-arm-none-eabi-4.8-2014.04_linux The cross-compilation toolchain used to compile the H618 Linux kernel source code is:
</div></li>
<li><p>Then select the model of the development board</p>
<p>[[File:zero3-img297.png]]</p></li>
<li><p>Then select the branch type of u-boot</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The current branch will compile the u-boot v2018.05 code that needs to be used in the linux5.4</p><p>'''gcc-arm-11.2-2022.02-x86_64-aarch64-none-linux-gnu'''image</p></li><li><p>The next branch will compile the u-boot v2021.07 version code that needs to be used in the linux6.1image</p><p>'''gcc-arm-11.2[[File:zero3-2022img298.02-x86_64-aarch64-none-linux-gnu'''png]]</p></li></ol></li><li><p>The cross-compilation toolchain used Then it will start to compile the H618 u-boot source code , and part of the information prompted when compiling the next branch isas follows:</p></li></ol> <!-- -->
<ol style="list-style-type: lower-alpha;">
<li><p>v2018.05u-boot source code version</p>{| class="wikitable" style="width:800px;" |-| <p>'''gcc-linaro-7[ o.4k.1] Compiling u-2019.02-x86_64_arm-linux-gnueabiboot [ '''</p></li><li><p>v2021.07</p><p>'''gcc-arm-11.2-2022.02-x86_64-aarch64-none-linux-gnu''']</p></li></ol>|}<span id="orangepi-build-complete-directory-structure-description"></span>=== orangepi-build complete directory structure description === <ol style="list-style-type: decimal;"li><li><p>The orangepi-build repository does not contain the source code version of the linux kernel, u-boot, and cross-compilation toolchain after downloading. The source code of the linux kernel and u-boot is stored in an independent git repository</p><ol style{| class="list-style-type: lower-alpha;wikitable"><li><p>The git warehouse where the linux kernel source code is stored > is as follows, pay attention to switch the branch of the > linux-orangepi warehouse to</p><ol style="list-style-typewidth: lower-alpha800px;"><li><p>Linux5.4</p>|-| <p>https://github[ o.com/orangepi-xunlong/linux-orangepi/tree/'''orange-pi-5k.4-sun50iw9] Compiler version [ '''</p></li><li><p>Linux6.1</p><p>https://github.com/orangepiaarch64-xunlong/linux-orangepi/tree/'''orangegnu-pi-6.1-sun50iw9gcc 11''']</p></li></ol>|}
</li>
<li><p>The git warehouse where the u-boot source code is stored is as > follows, pay attention Path to switch the branch of the > generated u-boot-orangepi warehouse todeb package</p><ol style{| class="list-style-type: lower-alpha;"><li><p>v2018.05</p><p>https://github.com/orangepi-xunlong/u-boot-orangepi/tree/'''v2018.05-h618'''</p></li><li><p>v2021.07</p></li></ol></li></ol></li></ol> https://github.com/orangepi-xunlong/u-boot-orangepi/tree/'''v2021.07-sunxi''' <ol start="2wikitable" style="list-style-typewidth: decimal800px;"><li><p>When orangepi-build runs for the first time, it will download the cross-compilation toolchain, u-boot and linux kernel source code. After successfully compiling a linux image, the files and folders that can be seen in orangepi|-build are:</p><ol style="list-style-type: lower-alpha;">| <li><p>'''build[ o.sh''': Compile the startup script</p></li><li><p>'''external''': Contains the configuration files needed for > compiling the image, scripts for specific functions, and the > source code of some programsk. The rootfs compressed package > cached during the compiling process is also stored in external</p></li><li><p>'''kernel''': Store the source code of the linux kernel</p></li><li><p>'''LICENSE''] Target directory [ ': GPL 2 license file</p></li><li><p>'''README.md''': orangepi-build documentation</p></li><li><p>'''output''': Store compiled u-boot, linux and other deb packages, > compilation logs, and compiled images and other files</p></li><li><p>'''scripts''': General script for compiling linux images</p><debs/li><li><p>'''toolchains''': Store the cross-compilation toolchain</p></li><li><p>'''u-boot''': Store the source code of u-boot</p></li><li><p>'''userpatches''': Store the configuration files needed to compile > the script</p><p>test@test:~/orangepi-build$ '''ls'''</p><p>'''build.sh external kernel LICENSE output README.md scripts toolchains u-boot userpatches'''</p></li></ol></li></ol> <span id="compile-u-boot"></span>== Compile u-boot == <ol style="list-style-type: decimal;"><li><p>Run the build.sh script, remember to add sudo permission</p><p>test@test:~/orangepi-build$ '''sudo ./build.sh'''</p></li><li><p>Select '''U-boot package''', then press Enter</p><div class="figure"> [[File:media/image296.png|576x132px|选区_238]] </div></li><li><p>Then select the model of the development board</p><p>[[File:media/image297.png|576x123px]]</p></li><li><p>Then select the branch type of u-boot</p><ol style="list-style-type: lower-alpha;"><li><p>The current branch will compile the u-boot v2018.05 code that > needs to be used in the linux5.4 image</p></li><li><p>The next branch will compile the u-boot v2021.07 version code > that needs to be used in the linux6.1 image</p><p>[[File:media/image298.png|576x77px]]</p></li></ol>}
</li>
<li><p>The package name of the generated u-boot deb package</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] File name [ '''linux-u-boot-next-orangepizero3_x.x.x_arm64.deb''' ]</p>|}</li>
<li><p>Compilation time</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Runtime [ '''1 min''' ]</p>|}</li><li><p>Repeat the command to compile u-boot, use the following command > to start compiling u-boot directly without selecting through > the graphical interface</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Repeat Build Options [ '''sudo ./build.sh BOARD=orangepizero3 BRANCH=next BUILD_OPT=u-boot''' ]</p>|}</li></ol>
</li>
<li><p>View the u-boot deb package generated by compilation</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~/orangepi-build$ '''ls output/debs/u-boot/'''</p>
<p>'''linux-u-boot-next-orangepizero3_x.x.x_arm64.deb'''</p>|}</li>
<li><p>When the orangepi-bulid compilation system compiles the u-boot source code, it will first synchronize the u-boot source code with the u-boot source code of the github server, so if you want to modify the u-boot source code, you first need to turn off the download and update function of the source code '''(This function needs to be fully compiled once u-boot, otherwise it will prompt that the source code of u-boot cannot be found)''', otherwise the changes made will be restored, the method is as follows:</p>
<p>Set the IGNORE_UPDATES variable in '''userpatches/config-default.conf''' to "yes"</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~/orangepi-build$ '''vim userpatches/config-default.conf'''</p>
<p>......</p>
<p>IGNORE_UPDATES="'''<span style="color:#FF0000">yes</span>'''"</p><p>......</p>|}</li>
<li><p>When debugging u-boot code, you can use the following method to update u-boot in the linux image for testing</p>
<ol style="list-style-type: lower-alpha;">
<li><p>First upload the compiled u-boot deb package to the linux system > of the development board</p>{| class="wikitable" style="width:800px;" |-|
<p>test@test:~/orangepi-build$ '''cd output/debs/u-boot'''</p>
<p>test@test:~/orangepi_build/output/debs/u-boot$ '''scp \'''</p>
<p>'''linux-u-boot-next-orangepizero3_x.x.x_arm64.deb [mailto:root@192.168.1.xxx:/root root@192.168.1.xxx:/root]'''</p>|}</li>
<li><p>Install the new u-boot deb package just uploaded</p>
{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo dpkg -i''' '''linux-u-boot-next-orangepizero3_x.x.x_arm64.deb'''</p>|}</li>
<li><p>Then run the nand-sata-install script</p>
{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo nand-sata-install'''</p>|}</li>
<li><p>Then select '''5 Install/Update the bootloader on SD/eMMC'''</p>
<p>[[File:media/image299zero3-img299.png|320x174px]]</p></li>
<li><p>After pressing the Enter key, a Warning will pop up first</p>
<p>[[File:media/image300zero3-img300.png|314x170px]]</p></li><li><p>Press the Enter key again to start updating u-boot, and the > following information will be displayed after the update</p><p>[[File:media/image301zero3-img301.png|292x164px]]</p></li><li><p>Then you can restart the development board to test whether the > modification of u-boot takes effect</p></li></ol>
</li></ol>
<span id="compile-the-linux-kernel"></span>
== Compile the linux kernel ==
<ol style="list-style-type: decimal;">
<li><p>Run the '''build.sh''' script, remember to add sudo permission</p>
{| class="wikitable" style="width:800px;" |-| <p>test@test:~/orangepi-build$ '''sudo ./build.sh'''</p>|}</li>
<li><p>Select '''Kernel package''', then press Enter</p>
<div class="figure">
[[File:media/image302zero3-img302.png|575x116px|选区_240]]
</div></li>
<li><p>Then you will be prompted whether you need to display the kernel configuration interface. If you do not need to modify the kernel configuration, select the first one. If you need to modify the kernel configuration, select the second one.</p>
<p>[[File:media/image303zero3-img303.png|576x87px]]</p></li>
<li><p>Then select the model of the development board</p>
<p>[[File:media/image297zero3-img297.png|576x123px]]</p></li>
<li><p>Then select the branch type of the kernel source code</p>
<ol style="list-style-type: lower-alpha;">
<li><p>current branch will compile linux5.4 kernel source code</p></li>
<li><p>The next branch will compile the linux6.1 kernel source code</p>
<p>[[File:media/image298zero3-img298.png|576x77px]]</p></li></ol>
</li>
<li><p>If you choose to display the kernel configuration menu (the second option) in step 3), the kernel configuration interface opened by '''make menuconfig''' will pop up. At this time, you can directly modify the kernel configuration, save and exit after modification. Yes, after exiting, it will start compiling the kernel source code.</p>
<p>[[File:media/image304zero3-img304.png|575x357px]]</p></li></ol>
<ol style="list-style-type: lower-alpha;">
<li><p>If you do not need to modify the configuration options of the > kernel, when running the build.sh script, pass in > '''KERNEL_CONFIGURE=no''' to temporarily block the pop-up kernel > configuration interface</p>{| class="wikitable" style="width:800px;" |-| <p>test@test:~/orangepi-build$ '''sudo ./build.sh KERNEL_CONFIGURE=no'''</p>|}</li><li><p>You can also set '''KERNEL_CONFIGURE=no''' in the > orangepi-build/userpatches/config-default.conf configuration file, > which can permanently disable this function</p></li><li><p>If the following error is displayed when compiling the kernel, it is > because the terminal interface of the Ubuntu PC is too small to > display the make menuconfig interface. Please maximize the > terminal of the Ubuntu PC and run the build.sh script again</p><p>[[File:media/image305zero3-img305.png|574x234px]]</p></li></ol></li></ol>
<!-- -->
<ol start="7" style="list-style-type: decimal;">
<li><p>Part of the information prompted when compiling the next branch kernel source code is as follows:follows:</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The version of the linux kernel source code</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Compiling current kernel [ '''6.1.31''' ]</p>|}</li>
<li><p>The version of the cross-compilation toolchain used</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Compiler version [ '''aarch64-linux-gnu-gcc 11''' ]</p>|}</li><li><p>The configuration file used by the kernel by default and the > path where it is stored are as follows</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Using kernel config file [ '''orangepi-build/external/config/kernel/linux-6.1-sun50iw9-next.config''' ]</p>|}</li><li><p>The path of the deb package related to the kernel generated by > compiling</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Target directory [ '''output/debs/''' ]</p>|}</li>
<li><p>The package name of the compiled kernel image deb package</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] File name [ '''linux-image-next-sun50iw9_x.x.x_arm64.deb''' ]</p>|}</li>
<li><p>The time used for compilation</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Runtime [ '''10 min''' ]</p>|}</li><li><p>Finally, the compilation command to repeatedly compile the > kernel selected last time will be displayed. Use the following > command to start compiling the kernel source code directly > without selecting through the graphical interface</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Repeat Build Options [ '''sudo ./build.sh BOARD=orangepizero3 BRANCH=next BUILD_OPT=kernel KERNEL_CONFIGURE=no''' ]</p>|}</li></ol>
</li>
<li><p>View the deb package related to the kernel generated by compilation</p>
<ol style="list-style-type: lower-alpha;">
<li><p>'''linux-dtb-next-sun50iw9_x.x.x_arm64.deb''' Contains dtb files > used by the kernel</p></li><li><p>'''linux-headers-next-sun50iw9_x.x.x_arm64.deb''' Include kernel > headers</p></li><li><p>'''linux-image-next-sun50iw9_x.x.x_arm64.deb''' Contains kernel > images and kernel modules</p>{| class="wikitable" style="width:800px;" |-|
<p>test@test:~/orangepi-build$ '''ls output/debs/linux-*'''</p>
<p>output/debs/linux-dtb-next-sun50iw9_x.x.x_arm64.deb</p>
<p>output/debs/linux-headers-next-sun50iw9_x.x.x_arm64.deb</p>
<p>output/debs/linux-image-next-sun50iw9_x.x.x_arm64.deb</p>|}</li></ol>
</li>
<li><p>When the orangepi-bulid compilation system compiles the linux kernel source code, it first synchronizes the linux kernel source code with the linux kernel source code of the github server, so if you want to modify the linux kernel source code, you first need to turn off the update function of the source code '''(the linux kernel needs to be fully compiled once This function can only be turned off after the source code, otherwise it will prompt that the source code of the linux kernel cannot be found)''', otherwise the changes made will be restored, the method is as follows:follows:</p>
<p>Set the IGNORE_UPDATES variable in '''userpatches/config-default.conf''' to "yes"</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~/orangepi-build$ '''vim userpatches/config-default.conf'''</p>
<p>IGNORE_UPDATES="'''<span style="color:#FF0000">yes</span>'''"</p>|}</li>
<li><p>If the kernel has been modified, the following method can be used to update the kernel and kernel modules of the development board linux system</p>
<ol style="list-style-type: lower-alpha;">
<li><p>Upload the deb package of the compiled linux kernel to the linux > system of the development board</p>{| class="wikitable" style="width:800px;" |-|
<p>test@test:~/orangepi-build$ '''cd output/debs'''</p>
<p>test@test:~/orangepi-build/output/debs$ '''scp \'''</p>
<p>'''linux-image-next-sun50iw9_x.x.x_arm64.deb root@192.168.1.xxx:/root'''</p>|}</li>
<li><p>Install the deb package of the new linux kernel just uploaded</p>
{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo dpkg -i linux-image-next-sun50iw9_x.x.x_arm64.deb'''</p>|}</li><li><p>Then restart the development board, and then check whether the > kernel-related modifications have taken effect</p>{| class="wikitable" style="width:800px;" |-| <p>orangepi@orangepi:~$ '''sudo''' '''reboot'''</p>|}</li></ol>
</li></ol>
<span id="compile-rootfs"></span>
== Compile rootfs ==
<ol style="list-style-type: decimal;">
<li><p>Run the build.sh script, remember to add sudo permission</p>
{| class="wikitable" style="width:800px;" |-| <p>test@test:~/orangepi-build$ '''sudo ./build.sh'''</p>|}</li><li><p>Select '''Rootfs and all deb packages''', then press Enter</p></li></ol>
<div class="figure">
[[File:media/image306zero3-img306.png|576x119px|选区_241]]
</div></li></ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>Then select the model of the development board</p>
<p>[[File:media/image297zero3-img297.png|576x123px]]</p></li>
<li><p>Then select the branch type of the kernel source code, the type of rootfs maintained by different versions of the kernel source code is different</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The current branch can see debian11, ubuntu20.04, ubuntu22.04 > three options</p></li><li><p>The next branch can see debian11, debian12, ubuntu22.04 three > options</p><p>[[File:media/image298zero3-img298.png|576x77px]]</p></li></ol>
</li>
<li><p>Then select the type of rootfs</p>
<p>[[File:media/image307zero3-img307.png|576x79px]]</p></li>
<li><p>Then select the type of image</p>
<ol style="list-style-type: lower-alpha;">
<li><p>'''Image with console interface (server)''' Indicates the image of > the server version, which is relatively small</p></li><li><p>'''Image with desktop environment''' Indicates a mirror image with > a desktop, which is relatively large</p>
<div class="figure">
[[File:media/image308zero3-img308.png|576x75px|选区_245]]
</div></li></ol>
<div class="figure">
[[File:media/image309zero3-img309.png|576x78px|选区_397]]
</div></li>
<li><p>If you are compiling the image of the desktop version, you also need to select the type of desktop environment. Currently only XFCE is maintained, so please choose the XFCE type desktop</p>
<p>[[File:media/image310zero3-img310.png|576x76px]]</p><p>[[File:media/image311zero3-img311.png|576x74px]]</p>
<p>You can then select additional packages that need to be installed. Please press the Enter key to skip directly here.</p>
<p>[[File:media/image312zero3-img312.png|575x264px]]</p></li>
<li><p>Then it will start to compile rootfs, and some information prompted during compilation is explained as follows</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The type of rootfs</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] local not found [ Creating new rootfs cache for '''bullseye''' ]</p>|}</li>
<li><p>The storage path of the compiled rootfs compressed package</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Target directory [ '''orangepi-build/external/cache/rootfs''' ]</p>|}</li><li><p>The name of the rootfs compressed package generated by > compilation</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] File name [ '''bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4''' ]</p>|}</li></ol>
</li>
<li><p>View the rootfs compressed package generated by compilation</p>
<ol style="list-style-type: lower-alpha;">
<li><p>'''bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4''' > is the rootfs compressed package, the meaning of each field of > the name is</p><ol style="list-style-type: lower-alphanone;"><li><p>a) '''bullseye''' indicates the type of linux distribution of > rootfs</p></li><li><p>b) '''xfce''' means rootfs is the type of desktop version, if it > is '''cli''', it means the type of server version</p></li><li><p>c) '''arm64''' represents the architecture type of rootfs</p></li><li><p>d) '''25250ec7002de9e81a41de169f1f89721''' is the MD5 hash value generated by the package names of all software packages installed by rootfs. As long as the list of software packages installed by rootfs is not modified, this value will not change. The compilation script will use this MD5 hash value to generate Determine whether rootfs needs to be recompiled</p></li></ol>
</li>
<li><p>'''bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4.list''' > lists the package names of all packages installed by rootfs</p>{| class="wikitable" style="width:800px;" |-|
<p>test@test:~/orangepi-build$ '''ls external/cache/rootfs/'''</p>
<p>bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4</p>
<p>bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4.current</p>
<p>bullseye-xfce-arm64.5250ec7002de9e81a41de169f1f89721.tar.lz4.list</p>|}</li></ol>
</li>
<li><p>If the required rootfs already exists under '''external/cache/rootfs''', then compiling rootfs again will directly skip the compilation process and will not restart the compilation. When compiling the image, it will also go to '''external/cache/rootfs''' to find out whether it has If there is rootfs available in the cache, use it directly, which can save a lot of download and compilation time</p></li></ol>
<span id="compile-linux-image"></span>
== Compile linux image ==
<ol style="list-style-type: decimal;">
<li><p>Run the '''build.sh''' script, remember to add sudo permission</p>
{| class="wikitable" style="width:800px;" |-| <p>test@test:~/orangepi-build$ '''sudo ./build.sh'''</p>|}</li><li><p>Select '''Full OS image for flashing''', then press Enter</p></li></ol>
<div class="figure">
[[File:media/image313zero3-img313.png|576x128px|选区_242]]
</div></li></ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>Then select the model of the development board</p>
<p>[[File:media/image297zero3-img297.png|576x123px]]</p></li>
<li><p>Then select the branch type of the kernel source code, the type of rootfs maintained by different versions of the kernel source code is different</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The current branch can see debian11, ubuntu20.04, ubuntu22.04 > three options</p></li><li><p>The next branch can see debian11, debian12, ubuntu22.04 three > options</p><p>[[File:media/image298zero3-img298.png|576x77px]]</p></li></ol>
</li>
<li><p>Then select the type of rootfs</p>
<p>[[File:media/image307zero3-img307.png|576x79px]]</p></li>
<li><p>Then select the type of image</p>
<ol style="list-style-type: lower-alpha;">
<li><p>'''Image with console interface (server)''' Indicates the image of > the server version, which is relatively small</p></li><li><p>'''Image with desktop environment''' Indicates a mirror image with > a desktop, which is relatively large</p>
<div class="figure">
[[File:media/image308zero3-img308.png|576x75px|选区_245]]
</div></li></ol>
<div class="figure">
[[File:media/image309zero3-img309.png|576x78px|选区_397]]
</div></li>
<li><p>If you are compiling the image of the desktop version, you also need to select the type of desktop environment. Currently only XFCE is maintained, so please select the XFCE type desktop</p>
<p>[[File:media/image310zero3-img310.png|576x76px]]</p><p>[[File:media/image311zero3-img311.png|576x74px]]</p>
<p>You can then select additional packages that need to be installed. Please press the Enter key to skip directly here.</p>
<p>[[File:media/image312zero3-img312.png|575x264px]]</p></li>
<li><p>Then it will start to compile the linux image. The general process of compilation is as follows</p>
<ol style="list-style-type: lower-alpha;"><li><p>a. Initialize the compilation environment of Ubuntu PC and install the software packages required for the compilation process</p></li><li><p>b. Download the source code of u-boot and linux kernel (if cached, only update the code)</p></li><li><p>c. Compile u-boot source code and generate u-boot deb package</p></li><li><p>d. Compile the linux source code and generate linux-related deb packages</p></li><li><p>e. Make the deb package of linux firmware</p></li><li><p>f. Make the deb package of the orangepi-config tool</p></li><li><p>g. Create a deb package supported by the board</p></li><li><p>h. If you are compiling the desktop image, you will also create desktop-related deb packages</p></li><li><p>i. Check whether the rootfs has been cached, if not, recreate the rootfs, if it has been cached, directly decompress and use</p></li><li><p>j. Install the previously generated deb package into rootfs</p></li><li><p>k. Make some specific settings for different development boards and different types of images, such as pre-installing additional software packages, modifying system configuration, etc.</p></li><li><p>l. Then make an image file and format the partition, the default type is ext4</p></li><li><p>m. Then copy the configured rootfs to the mirrored partition</p></li><li><p>n. Then update initramfs</p></li><li><p>o. Finally, write the bin file of u-boot into the image through the dd command</p></li></ol></li>
<li><p>After compiling the image, the following information will be prompted</p>
<ol style="list-style-type: lower-alpha;">
<li><p>The storage path of the compiled image</p>
{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Done building [ '''output/images/orangepizero3_x.x.x_debian_bullseye_linux6.1.xx_xfce_desktop/orangepizero3_x.x.x_debian_bullseye_linux6.1.xx_xfce_desktop.img''' ]</p>|}</li><li><p>Compilation time</p></li></ol></li></ol>{| class="wikitable" style="width:800px;" |-|
'''[ o.k. ] Runtime [ 19 min ]'''
|}</ol>
<ol start="3" style="list-style-type: lower-alpha;">
<li><p>Repeat the command to compile the image, and use the following > command to start compiling the image directly without selecting > through the graphical interface</p>{| class="wikitable" style="width:800px;" |-| <p>[ o.k. ] Repeat Build Options [ '''sudo ./build.sh BOARD=orangepizero3 BRANCH=next BUILD_OPT=image RELEASE=bullseye BUILD_MINIMAL=no BUILD_DESKTOP=no KERNEL_CONFIGURE=yes''' ]</p>|}</li></ol></li></ol><span id="android-12-tv-system-instructions"></span>
<span id="supported-android-versions"></span>
== Supported Android versions ==
{| class="wikitable" style="width:800px;"
|-
| style="text-align: leftcenter;"| Android version| style="text-align: leftcenter;"| kernel version
|-
| style="text-align: leftcenter;"| '''Android 12 TV version'''| style="text-align: leftcenter;"| '''linux5.4'''
|}
<span id="android-12-tv-function-adaptation"></span>
== Android 12 TV function adaptation ==
{| class="wikitable" style="width:800px;"
|-
| style="text-align: leftcenter;"| Function| style="text-align: leftcenter;"| Android12
|-
| style="text-align: leftcenter;"| HDMI Video| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| HDMI Audio| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| USB2.0 x 3| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| TFcard boot| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| network card| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| infrared| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| WIFI| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| WIFI hotsport| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| Bluetooth| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| BLE Bluetooth| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| headphone audio| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| TV-OUT| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| USB camera| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| LED light| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| Temperature Sensor| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| Mali GPU| style="text-align: leftcenter;"| OK
|-
| style="text-align: leftcenter;"| video codec| style="text-align: leftcenter;"| OK
|}
<span id="onboard-led-light-display-instructions"></span>
== Onboard LED light display instructions ==
{| class="wikitable" style="width:800px;"
|-
|
| style="text-align: leftcenter;"| '''Green Light'''| style="text-align: leftcenter;"| '''Red Light'''
|-
| '''u-boot startup phase'''
| style="text-align: leftcenter;"| '''Off'''| style="text-align: leftcenter;"| '''Bright'''
|-
| '''The kernel boots into the system'''
| style="text-align: leftcenter;"| '''Bright'''| style="text-align: leftcenter;"| '''Off'''
|}
<span id="android-method-to-return-to-the-previous-interface"></span>
== Android method to return to the previous interface ==
<ol style="list-style-type: decimal;">
<li><p>We generally use the mouse and keyboard to control the Android system of the development board. When entering certain interfaces and need to return to the previous interface or desktop, we can only return through the '''<span style="color:#FF0000">right mouse button</span>''', and the keyboard cannot return.</p></li>
<li><p>If you have purchased the infrared remote control (other remote control does not work) and the expansion board that match the development board, after inserting the expansion board into the development board, you can return to the previous menu through the return key in the remote control. The position of the return key is shown in the figure below shown:</p>
<p>[[File:media/image314zero3-img314.png|231x199px]]</p></li></ol>
<span id="how-to-use-adb"></span>
== How to use ADB ==
=== Use network connection adb debugging ===
{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big>'''Using the network adb does not require a USB Type C interface data cable to connect the computer and the development board, but to communicate through the network, so first make sure that the wired or wireless network of the development board has been connected, and then obtain the IP address of the development board, and then to use.'''</big>|}
<ol style="list-style-type: decimal;">
<li><p>Make sure that the '''service.adb.tcp.port''' of the Android system is set to port number 5555</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>apollo-p2:/ # '''getprop | grep "adb.tcp"'''</p>
<p>[service.adb.tcp.port]: [5555]</p>|}</li><li><p>If '''service.adb.tcp.port''' is not set, you can use the following command to set the port number of network adb in the serial port</p></li>< {| class="wikitable" style="width:800px;" |-| apollo-p2:/ol># '''setprop service.adb.tcp.port 5555'''
apollo-p2:/ # '''stop adbd'''
apollo-p2:/ # '''start adbd'''
|}</ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>Install adb tool on Ubuntu PC</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~$ '''sudo apt-get update'''</p>
<p>test@test:~$ '''sudo apt-get install -y adb'''</p>|}</li>
<li><p>Then connect network adb on Ubuntu PC</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~$ '''adb connect 192.168.1.xxx:5555''' '''(It needs to be modified to the IP address of the development board)'''</p>
<p>* daemon not running; starting now at tcp:5037</p>
<p>* daemon started successfully</p>
<p>connected to 192.168.1.xxx:5555</p>
<p>test@test:~$ '''adb devices'''</p>
<p>List of devices attached</p>
<p>192.168.1.xxx:5555 device</p>|}</li><li><p>Then you can log in to the android system through the adb shell on the Ubuntu PC</p></li></ol>
{| class="wikitable" style="width:800px;"
|-
|
test@test:~$ '''adb shell'''
apollo-p2:/ #
|}
</li></ol>
<span id="use-the-data-cable-to-connect-to-adb-debugging"></span>
=== Use the data cable to connect to adb debugging ===
<ol style="list-style-type: decimal;">
<li><p>Prepare a data cable with USB Type C interface, plug one end of the USB interface into the USB interface of the computer, and insert one end of the USB Type C interface into the power interface of the development board. In this case, the development board is powered by the USB interface of the computer, so please make sure that the USB interface of the computer can provide the most power to drive the development board</p>
<p>[[File:media/image315zero3-img315.png|178x178px]]</p></li>
<li><p>Install adb tool on Ubuntu PC</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~$ '''sudo apt-get update'''</p>
<p>test@test:~$ '''sudo apt-get install -y adb'''</p>|}</li>
<li><p>View the identified ADB device</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>test@test:~$ '''adb devices'''</p>
<p>List of devices attached</p>
<p>4c00146473c28651dd0 device</p>|}</li><li><p>Then you can log in to the android system through the adb shell on the Ubuntu PC</p></li></ol>
{| class="wikitable" style="width:800px;"
|-
|
test@test:~$ '''adb shell'''
apollo-p2:/ $
|}
</li></ol>
<span id="view-the-method-of-setting-hdmi-display-resolution"></span>
== View the method of setting HDMI display resolution ==
<ol style="list-style-type: decimal;">
<li><p>First enter '''Settings'''</p>
<p>[[File:media/image316zero3-img316.png|234x83px]]</p></li>
<li><p>Then select '''Device Preferences'''</p>
<p>[[File:media/image317zero3-img317.png|415x170px]]</p></li>
<li><p>Then select '''Display & Sound'''</p>
<p>[[File:media/image318zero3-img318.png|420x133px]]</p></li>
<li><p>Then select '''Advanced display settings'''</p>
<p>[[File:media/image319zero3-img319.png|423x96px]]</p></li>
<li><p>Then select '''HDMI outpu mode'''</p>
<p>[[File:media/image320zero3-img320.png|423x101px]]</p></li>
<li><p>Then you can see the list of resolutions supported by the display. At this time, click the corresponding option to switch to the corresponding resolution. Please note that the resolutions supported by different monitors may be different. If you connect to a TV, you will generally see more resolution options than the picture below.</p>
<p>[[File:media/image321zero3-img321.png|429x136px]]</p></li>
<li><p>The HDMI output of the development board supports 4K display. When connected to a 4K TV, you can see the option of 4K resolution</p>
<p>[[File:media/image322zero3-img322.png|429x242px]]</p></li></ol>
<span id="hdmi-to-vga-display-test-1"></span>
<ol style="list-style-type: lower-alpha;">
<li><p>HDMI to VGA Converter</p>
<p>[[File:media/image145zero3-img145.png|155x104px]]</p></li><li><p>A VGA cable and a Micro HDMI male to HDMI female conversion > cable</p><p>[[File:media/image146zero3-img146-1.png|148x133px300px]] [[File:media/image147zero3-img147.jpegpng|157x139px|IMG_6140(20220104-134930)300px]]</p></li>
<li><p>A monitor or TV that supports VGA interface</p></li></ol>
</li>
<li><p>HDMI to VGA display test as shown below</p>
<p>[[File:media/image323zero3-img323.png|576x330px]]</p>{| class="wikitable" style="background-color:#ffffdc;width:800px;" |-| <big><p>'''When using HDMI to VGA display, the development board and the Android system of the development board do not need to make any settings, only the Micro HDMI interface of the development board can display normally. So if there is a problem with the test, please check whether there is a problem with the HDMI to VGA converter, VGA cable and monitor.'''</p></big>|}</li></ol>
<span id="wi-fi-connection-method"></span>
== WI-FI connection method ==
<ol style="list-style-type: decimal;">
<li><p>First select '''Settings'''</p>
<p>[[File:media/image316zero3-img316.png|234x83px]]</p></li>
<li><p>Then select '''Network & Internet'''</p>
<p>[[File:media/image324zero3-img324.png|373x103px]]</p></li>
<li><p>Then open WI-FI</p>
<p>[[File:media/image325zero3-img325.png|381x50px]]</p></li>
<li><p>After turning on WI-FI, you can see the searched signal under '''Available networks'''</p>
<p>[[File:media/image326zero3-img326.png|381x187px]]</p></li>
<li><p>After selecting the WI-FI you want to connect to, the password input interface shown in the figure below will pop up</p>
<div class="figure">
[[File:media/image327zero3-img327.png|386x180px|Screenshot_20220104-164114]]
</div></li>
<li><p>Then use the keyboard to enter the password corresponding to the WI-FI, and then use the '''<span style="color:#FF0000">mouse</span>''' to click the Enter button in the virtual keyboard to start connecting to the WI-FI</p>
<div class="figure">
[[File:media/image328zero3-img328.png|401x165px|图片1]]
</div></li>
<li><p>After the WI-FI connection is successful, the display is as shown in the figure below</p>
<p>[[File:media/image329zero3-img329.png|402x141px]]</p></li></ol>
<span id="how-to-use-wi-fi-hotspot"></span>
== How to use WI-FI hotspot ==
<li><p>First, please make sure that the Ethernet port is connected to the network cable and can access the Internet normally</p></li>
<li><p>Then select '''Settings'''</p>
<p>[[File:media/image316zero3-img316.png|234x83px]]</p></li>
<li><p>Then select '''Network & Internet'''</p>
<p>[[File:media/image324zero3-img324.png|373x103px]]</p></li>
<li><p>Then select '''WIFI hotspot'''</p>
<p>[[File:media/image330zero3-img330.png|378x104px]]</p></li>
<li><p>Then turn on '''Hotspot Enable''', you can also see the name and password of the generated hotspot in the figure below, remember them and use them when connecting to the hotspot (if you need to modify the name and password of the hotspot, you need to turn off '''Hotspot Enable''' first, before modifying)</p>
<p>[[File:media/image331zero3-img331.png|402x174px]]</p></li>
<li><p>At this point, you can take out your mobile phone. If everything is normal, you can find the WIFI hotspot with the same name '''(here AndroidAP_7132)''' displayed under the '''Hotspot name''' in the above picture in the WI-FI list searched by the mobile phone. Then you can click '''AndroidAP_7132''' to connect to the hotspot, and the password can be seen under the '''Hotspot password''' in the above picture</p>
<p>[[File:media/image332zero3-img332.png|269x191px]]</p></li>
<li><p>After the connection is successful, it will be displayed as shown in the figure below (the interface of different mobile phones will be different, the specific interface is subject to the display of your mobile phone). At this point, you can open a webpage on your mobile phone to see if you can access the Internet. If you can open the webpage normally, it means that the '''WI-FI Hotspot''' of the development board can be used normally.</p>
<p>[[File:media/image333zero3-img333.png|269x125px]]</p></li></ol>
<span id="how-to-check-the-ip-address-of-the-ethernet-port"></span>
<li><p>First, please make sure that the Gigabit Ethernet port of the development board is connected to a router or switch</p></li>
<li><p>Then open '''Settings'''</p>
<p>[[File:media/image334zero3-img334.png|431x161px]]</p></li>
<li><p>Then select '''Network & Internet'''</p>
<p>[[File:media/image335zero3-img335.png|576x186px]]</p></li>
<li><p>Then you can see the IP address of the development board's wired network port at the position shown in the figure below</p>
<p>[[File:media/image336zero3-img336.png|576x200px]]</p></li></ol>
<span id="bluetooth-connection-method"></span>
<ol style="list-style-type: decimal;">
<li><p>First select '''Settings'''</p>
<p>[[File:media/image316zero3-img316.png|234x83px]]</p></li>
<li><p>Then select '''Bluetooth'''</p>
<p>[[File:media/image337zero3-img337.png|377x111px]]</p></li>
<li><p>Then open '''Bluetooth Enable'''</p>
<p>[[File:media/image338zero3-img338.png|384x180px]]</p></li>
<li><p>Then click '''Pair new device''' to start scanning the surrounding Bluetooth devices</p>
<p>[[File:media/image339zero3-img339.png|389x129px]]</p></li>
<li><p>The searched Bluetooth devices will be displayed under '''Available devices'''</p>
<p>[[File:media/image340zero3-img340.png|407x181px]]</p></li>
<li><p>Then click the Bluetooth device you want to connect to start pairing. When the following interface pops up, please use the mouse to select the '''Pair''' option</p>
<p>[[File:media/image341zero3-img341.png|420x115px]]</p></li><li><p>The test here is the configuration process of the development board and the Bluetooth of the '''<span style="color:#FF0000">Android mobile phone</span>'''. At this time, the following confirmation interface will pop up on the mobile phone. After clicking the pairing button on the mobile phone, the pairing process will start</p><p>[[File:media/image342zero3-img342.png|178x200px]]</p></li>
<li><p>After the pairing is complete, open '''Paired devices''' and you can see the paired Bluetooth devices</p>
<p>[[File:media/image343zero3-img343.png|430x136px]]</p></li>
<li><p>At this time, you can use the Bluetooth of your mobile phone to send a picture to the development board. After sending, you can see the following confirmation interface in the Android system of the development board, and then click '''Accept''' to start receiving the picture sent by the mobile phone.</p>
<p>[[File:media/image344zero3-img344.png|433x113px]]</p></li>
<li><p>The pictures received by the Android system Bluetooth of the development board can be viewed in '''Received files'''</p>
<p>[[File:media/image345zero3-img345.png|432x209px]]</p></li></ol>
<span id="how-to-use-the-usb-camera"></span>
== How to use the USB camera ==
<li><p>First insert the USB (UVC protocol) camera into the USB interface of the development board</p></li>
<li><p>If the USB camera is recognized normally, a corresponding video device node will be generated under /dev</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>console:/ # '''ls /dev/video0'''</p>
<p>/dev/video0</p>|}</li><li><p>Then make sure that the adb connection between the Ubuntu PC and the development board is normal. For how to use adb, please refer to the instructions in the section on [[Orange Pi Zero 3#How to use ADB|'''how to use ADB''']]</p></li>
<li><p>Download the USB camera test APP in the <span class="mark">official tool</span> on the development board data download page</p>
<p>[[File:media/image346zero3-img346.png|344x183px]]</p><p>[[File:media/image347zero3-img347.png|575x145px]]</p></li>
<li><p>Then use the adb command to install the USB camera test APP to the Android system, of course, you can also use the U disk to copy the installation</p>
{| class="wikitable" style="width:800px;" |-| <p>test@test:~$ '''adb install usbcamera.apk'''</p>|}</li>
<li><p>After installation, you can see the startup icon of the USB camera on the Android desktop</p>
<p>[[File:media/image348zero3-img348.png|576x132px]]</p></li>
<li><p>Then double-click to open the USB camera APP and you can see the output video of the USB camera</p></li></ol>
<span id="android-system-root-instructions"></span>
== Android system ROOT instructions ==
<ol style="list-style-type: decimal;">
<li><p>Download '''rootcheck.apk''' from the <span class="mark">[http://www.orangepi.org/html/hardWare/computerAndMicrocontrollers/service-and-support/Orange-Pi-Zero-3.html '''official tool''']</span> on the development board data download page</p><p>[[File:media/image349zero3-img349.png|576x172px1200px]]</p><p>[[File:media/image350zero3-img350.png|575x124px1200px]]</p></li><li><p>Then make sure that the adb connection between the Ubuntu PC and the development board is normal. For how to use adb, please refer to the instructions in the section on [[Orange Pi Zero 3#How to use ADB|'''how to use ADB''']]</p></li>
<li><p>Then use the adb command to install rootcheck.apk to the Android system, of course, you can also use the U disk to copy the installation</p>
{| class="wikitable" style="width:800px;" |-| <p>test@test:~$ '''adb install rootcheck.apk'''</p>|}</li>
<li><p>After installation, you can see the startup icon of the ROOT test tool on the Android desktop</p>
<p>[[File:media/image351zero3-img351.png|575x119px]]</p></li>
<li><p>The display interface after opening the '''ROOT test tool''' for the first time is shown in the figure below</p>
<p>[[File:media/image352zero3-img352.png|575x162px]]</p></li>
<li><p>Then you can click '''CHECK NOW''' to start checking the ROOT status of the Android system. After the check, the display is as follows, and you can see that the Android system has obtained the ROOT permission</p>
<p>[[File:media/image353zero3-img353.png|575x161px]]</p></li></ol>
<span id="the-method-of-using-miracastreceiver-to-cast-the-mobile-phone-screen-to-the-development-board"></span>
== The method of using MiracastReceiver to cast the mobile phone screen to the development board ==
<ol style="list-style-type: decimal;">
<li><p>First, please make sure that the development board and the mobile phone are connected to the same WIFI hotspot. For the method of connecting the development board to WIFI, please refer to the description in the section of [[Orange Pi Zero 3#WI-FI connection method|'''WI-FI connection method''']]</p></li>
<li><p>Then open the '''MiracastReceiver''' application in the Android system of the development board</p>
<p>[[File:media/image354zero3-img354.png|576x124px]]</p></li>
<li><p>The interface after '''MiracastReceiver''' is opened is as follows</p>
<div class="figure">
[[File:media/image355zero3-img355.png|420x236px|Screenshot_20230625-193535]]
</div></li>
<li><p>Then find the screen projection function in the mobile phone settings. '''Here we take the Mi 12S Pro mobile phone as an example'''. Please research other brands of mobile phones by yourself. As shown in the figure below, click the button in the red box to open the screen projection function of the mobile phone</p>
<p>[[File:media/image356zero3-img356-1.png|167x266px]]</p></li>
<li><p>After waiting for a while, you can see the searched and connectable devices on the mobile phone, and then we can select the device corresponding to the development board to connect</p>
<p>[[File:media/image357zero3-img357-1.png|146x308px]]</p></li>
<li><p>Then the selection box shown in the figure below will pop up on the '''MiracastReceiver''' application interface of the development board, here we can select '''Accept'''</p>
<p>[[File:media/image358zero3-img358.png|468x265px]]</p></li>
<li><p>Then you can see the content of the mobile phone screen on the HDMI screen connected to the development board</p>
<p>[[File:media/image359zero3-img359-1.png|576x352px]]</p></li></ol>
<span id="pin-interface-gpio-uart-spi-test"></span>
== 26pin interface GPIO, UART, SPI test ==
<ol style="list-style-type: decimal;">
<li><p>First open the wiringOP APP on the desktop</p>
<p>[[File:media/image360zero3-img360.png|576x133px]]</p></li>
<li><p>Then click the '''GPIO_TEST''' button to open the GPIO test interface</p>
<p>[[File:media/image361zero3-img361.png|413x77px]]</p></li>
<li><p>The GPIO test interface is shown in the figure below. There is a one-to-one correspondence between the two rows of '''CheckBox''' buttons on the left and the 26pin pins '''(PC1/PI16/PI6/PH10 in the lower left corner are GPIO ports in the 13pin pins)'''. When the '''CheckBox''' button is checked, the corresponding GPIO pin will be set to '''OUT''' mode, and the pin level will be set to high level; when the checkbox is unchecked, the GPIO pin level will be set to low level; When the '''GPIO READALL''' button is pressed, information such as the wPi number, GPIO mode, and pin level can be obtained.</p>
<p>[[File:media/image362zero3-img362.png|425x236px]]</p></li><li><p>Then click the '''GPIO READALL''' button, the output information is as shown in the figure below:below:</p>
<div class="figure">
[[File:media/image363zero3-img363.png|444x249px|Screenshot_20230609-155643]]
</div></li>
<li><p>There are a total of 17 GPIO ports in the 26pin of the development board that can be used '''(if you add 4 GPIO ports in the 13pin, then there are 21 in total)''', and the following pin No. 7 - corresponding to GPIO is PC9 - corresponding to wPi The serial number is 2——as an example to demonstrate how to set the high and low levels of the GPIO port. First click the '''CheckBox''' button corresponding to pin 7. When the button is selected, pin 7 will be set to high level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is '''3.3v''', it means setting high level success</p>
<p>[[File:media/image364zero3-img364.png|432x210px]]</p></li>
<li><p>Then click the '''GPIO READALL''' button, you can see that the current pin 7 mode is '''OUT''', and the pin level is high</p>
<p>[[File:media/image365zero3-img365.png|430x207px]]</p></li>
<li><p>Click the '''CheckBox''' button in the figure below again to cancel the check status. Pin 7 will be set to low level. After setting, you can use a multimeter to measure the voltage value of the pin. If it is '''0v''', it means that the low level is set successfully.</p>
<p>[[File:media/image366zero3-img366.png|434x212px]]</p></li>
<li><p>Then click the '''GPIO READALL''' button, you can see that the current pin 7 mode is OUT, and the pin level is low</p>
<p>[[File:media/image367zero3-img367.png|438x217px]]</p></li></ol>
<span id="pin-uart-test-method"></span>
<ol style="list-style-type: decimal;">
<li><p>'''UART5''' is enabled by default in Android, and the corresponding device node is '''/dev/ttyAS5'''</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>apollo-p2:/ # '''ls /dev/ttyAS5'''</p>
<p>/dev/ttyAS5</p>|}</li>
<li><p>First open the wiringOP APP on the desktop</p>
<p>[[File:media/image360zero3-img360.png|576x133px]]</p></li>
<li><p>Then click the '''UART_TEST''' button to open the UART test interface</p>
<p>[[File:media/image368zero3-img368.png|505x94px]]</p></li><li><p>The serial port test interface of wiringOP is shown in the figure below</p></li></ol> [[File:media/image369.png|511x133px]]
[[File:zero3-img369.png]]
</ol>
<ol start="5" style="list-style-type: decimal;">
<li><p>Then select the '''/dev/ttyAS5''' node in the selection box</p>
<p>[[File:media/image370zero3-img370.png|499x269px]]</p></li><li><p>Enter the baud rate you want to set in the edit box, and then click the '''OPEN''' button to open the '''/dev/ttyAS5''' node. After the opening is successful, the '''OPEN''' button becomes unselectable, and the '''CLOSE''' button and '''SEND''' button become selectable.</p></li></ol> [[File:media/image371.png|334x107px]]
[[File:zero3-img371.png]]
</ol>
<ol start="7" style="list-style-type: decimal;">
<li>Then use Dupont wire to short the rx and tx pins of uart5</li></ol>
{| class="wikitable" style="width:800px;"
|-
|
| style="text-align: leftcenter;"| uart5
|-
| Tx pin
| style="text-align: leftcenter;"| Corresponding to pin 8 of 26pin
|-
| Rx pin
| style="text-align: leftcenter;"| Corresponding to pin 10 of 26pin
|}
</li></ol>
<ol start="8" style="list-style-type: decimal;">
<li>Then you can enter a character in the send edit box below, click the '''SEND''' button to start sending</li></ol> [[File:media/image372.png|376x189px]]
[[File:zero3-img372.png]]
</ol>
<ol start="9" style="list-style-type: decimal;">
<li>If everything is normal, the received string will be displayed in the receiving box</li></ol>
[[File:media/image373zero3-img373.png|382x196px]]</ol><span id="pin-spi-test-method"></span>
=== 26pin SPI test method ===
<ol style="list-style-type: decimal;">
<li><p>The SPI that can be used in 26pin is SPI1, and the corresponding device node is '''/dev/spidev1.1'''</p>
<p>[[File:media/image360zero3-img360.png|576x133px]]</p></li><li><p>Here is a demonstration to test the SPI1 interface through the '''w25q64''' module, first connect the w25q64 module to the SPI1 interface</p></li></ol> '''It doesn’t matter if there is no w25q64 module, because there is a SPIFlash connected to SPI0 on the development board, and the configuration of SPI0 is also enabled by default in Android, so we can also directly use the onboard SPIFlash test.'''
{| class="wikitable" style="background-color:#ffffdc;width:800px;"
|-
|
<big>'''It doesn't matter if there is no w25q64 module, because there is a SPIFlash connected to SPI0 on the development board, and the configuration of SPI0 is also enabled by default in Android, so we can also directly use the onboard SPIFlash test.'''</big>
|}
</li></ol>
<ol start="3" style="list-style-type: decimal;">
<li><p>Then open the wiringOP APP on the desktop</p></li>
<li><p>Then click the '''SPI_TEST''' button to open the SPI test interface</p>
<p>[[File:media/image374zero3-img374.png|518x96px]]</p></li>
<li><p>Then select the spi device node in the upper left corner. If you directly test the onboard SPIFlash, then keep the default '''/dev/spidev0.0'''. If you connect the '''w25q64''' module to the 26pin spi1, then please select /dev '''/dev/spidev1.1'''</p>
<div class="figure">
[[File:media/image375.jpeg|296x135px|C:\Users\orangepi\Desktop\用户手册插图\Zero3\未标题zero3-7img375.jpg未标题-7png]]
</div></li>
<li><p>Then click the '''OPEN''' button to initialize the SPI</p></li></ol> [[File:media/image376.png|295x168px]]
[[File:zero3-img376.png]]
</ol>
<ol start="7" style="list-style-type: decimal;">
<li><p>Then fill in the bytes that need to be sent, such as reading the ID information of the onboard SPIFlash, fill in the address 0x9f in data[0], and then click the '''TRANSFER''' button</p>
<p>[[File:media/image377zero3-img377.png|294x169px]]</p></li><li><p>Finally, the APP will display the read ID information of the onboard SPI Flash</p></li></ol> [[File:media/image378.png|299x217px]]
[[File:zero3-img378.png]]
</ol>
<ol start="9" style="list-style-type: decimal;">
<li><p>If it is to read the w25q64 module connected to 26pin SPI1, then the read ID information is shown in the figure below</p>
<p>[[File:media/image379zero3-img379.png|302x201px]]</p></li>
<li><p>The MANUFACTURER ID of the w25q64 module is EFh, and the Device ID is 4017h, corresponding to the value read above (h stands for hexadecimal)</p>
<p>[[File:media/image380zero3-img380.png|336x113px]]</p></li></ol>
<span id="pin-i2c-test-method"></span>
=== 26pin I2C test method ===
<ol style="list-style-type: decimal;">
<li><p>The i2c3 in 26pin is enabled by default in Android, and the corresponding device node is '''/dev/i2c-3'''</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>apollo-p2:/ # '''ls /dev/i2c-3'''</p>
<p>/dev/i2c-3</p>|}</li>
<li><p>First open the wiringOP APP on the desktop</p>
<p>[[File:media/image360zero3-img360.png|576x133px]]</p></li>
<li><p>Then click the '''I2C_TEST''' button to open the i2c test interface</p>
<p>[[File:media/image381zero3-img381.png|506x110px]]</p></li><li><p>The i2c test interface of wiringOP is shown in the figure below. You can see that the default i2c is '''/dev/i2c-3''', so we don’t don't need to re-select</p></li></ol> [[File:media/image382.png|353x159px]]
[[File:zero3-img382.png]]
</ol>
<ol start="5" style="list-style-type: decimal;">
<li><p>Then connect an i2c device to the 26pin i2c3 pin, here we take the ds1307 rtc module as an example</p>
<p>[[File:media/image186zero3-img186.png|121x103px]]</p></li></ol>
{| class="wikitable" style="width:800px;"
|-
| style="text-align: leftcenter;"| '''Pins of the RTC module'''| style="text-align: leftcenter;"| '''The pin corresponding to the 26pin of the development board'''
|-
| style="text-align: leftcenter;"| '''5V'''| style="text-align: leftcenter;"| '''pin 2'''
|-
| style="text-align: leftcenter;"| '''GND'''| style="text-align: leftcenter;"| '''pin 6'''
|-
| style="text-align: leftcenter;"| '''SDA'''| style="text-align: leftcenter;"| '''pin 3'''|-| style="text-align: leftcenter;"| '''SCL'''| style="text-align: leftcenter;"| '''pin 5'''|}</ol><ol start="6" style="list-style-type: decimal;"><li><p>The i2c address of the ds1307 rtc module is 0x68. After connecting the wires, we can use the '''i2cdetect -y 3''' command in the serial port command line to check whether the i2c address of the ds1307 rtc module can be scanned. As shown in the figure below, if you can see the address 0x68, it means that the wiring of the ds1307 rtc module is correct.</p>{| class="wikitable" style="width:800px;" |-| <p>apollo-p2:/ # '''i2cdetect -y 3'''</p>|}<p>[[File:zero3-img383.png]]</p></li><li><p>Then set the address of i2c to 0x68 in wiringOP, and then click the '''OPEN''' button to open i2c3</p><p>[[File:zero3-img384.png]]</p></li><li><p>The display after clicking the '''OPEN''' button to open i2c3 is as follows:</p><p>[[File:zero3-img385.png]]</p></li><li><p>Then we test to write a value into the register of the rtc module, for example, write 0x55 to the 0x1c address</p><ol style="list-style-type: lower-alpha;"><li><p>We first set the address of the register to be written to 0x1c</p><p>[[File:zero3-img386.png]]</p></li><li><p>Then set the value to be written to 0x55</p><p>[[File:zero3-img387.png]]</p></li><li><p>Then click the '''WRITE BYTE''' button to execute the write action</p><p>[[File:zero3-img388.png]]</p></li></ol></li><li><p>Then click the '''READ BYTE''' button to read the value of the 0x1c register, if it is displayed as 0x55, it means that the i2c read and write test has passed</p><p>[[File:zero3-img389.png]]</p></li></ol> <span id="appendix"></span> = '''Appendix''' = <span id="user-manual-update-history"></span>== User Manual Update History == {| class="wikitable" style="width:800px;" |-| style="text-align: center;"| '''Version'''| style="text-align: center;"| '''Date'''| style="text-align: center;"| '''Update Notes'''|-| style="text-align: center;"| v1.0| style="text-align: center;"| 2023-07-05| style="text-align: center;"| initial version|-| style="text-align: center;"| v1.1| style="text-align: center;"| 2023-07-14| style="text-align: center;"| Add the compilation method of Android 12 source code|} <span id="image-update-history"></span> == Image update history == {| class="wikitable" style="width:800px;text-align: center;" |-| '''Date''' | '''Update Notes'''|-| 2023-07-05| Orangepizero3_1.0.0_ubuntu_jammy_server_linux5.4.125.7z Orangepizero3_1.0.0_debian_bullseye_server_linux5.4.125.7z Orangepizero3_1.0.0_ubuntu_focal_desktop_xfce_linux5.4.125.7z Orangepizero3_1.0.0_ubuntu_jammy_desktop_xfce_linux5.4.125.7z Orangepizero3_1.0.0_debian_bullseye_desktop_xfce_linux5.4.125.7z Orangepizero3_1.0.0_ubuntu_jammy_server_linux6.1.31.7z Orangepizero3_1.0.0_debian_bookworm_server_linux6.1.31.7z Orangepizero3_1.0.0_debian_bullseye_server_linux6.1.31.7z Orangepizero3_1.0.0_ubuntu_jammy_desktop_xfce_linux6.1.31.7z Orangepizero3_1.0.0_debian_bookworm_desktop_xfce_linux6.1.31.7z Orangepizero3_1.0.0_debian_bullseye_desktop_xfce_linux6.1.31.7z OrangePi_Zero3_Android12_v1.0.tar.gz
|-
: *initial version
|}