Xunlong Orange Pi One & Lite

Orange Pi One and Lite are H3 based development boards produced by Xunlong.

The One is clearly Orange Pi PC's little/smaller sibling. Compared to the PC the following is different: smaller size, 512MiB instead of 1GiB DRAM (still two DDR3L modules making use of the full 32 bit memory bandwidth), 2 USB host ports aren't exposed and the following is also missing: IR receiver, microphone and TRRS jack for Audio/CVBS video.

The Lite features RTL8189FTV WiFi (shipping with a small external antenna connected to the u.FL connector between the USB ports), saves the Ethernet port but regains one more USB port, IR receiver and microphone.

Xunlong chose a different voltage regulator on these two boards that requires software adjustments to get dynamic voltage frequency scaling (dvfs) working. Apart from that Xunlong tried to keep both small boards as compatible as possible to the PC so that all OS images for the PC work with One and Lite with just two drawbacks: Non functional dvfs without fex file adjustments and no WiFi without new drivers on the Lite.

= Identification = OPi One PCB has the following silkscreened on it: Orange Pi One V1.1 Orange Pi Lite shows: Orange Pi Lite V1.1

= Expansion Port =

The Orange Pi One & Lite both have a Raspberry Pi model B+ compatible 40-pin, 0.1" connector with several low-speed interfaces.

= Tips, Tricks, Caveats =

FEL mode
Both boards will fail over to FEL mode if it doesn't detect a card present in the µSD slot. There is no dedicated FEL button.

Compatibility
Since Xunlong didn't provide new OS images with Orange Pi One's release users try to use images/settings for Orange Pi PC. While this seems to work and Ethernet and USB are functional on the One the logs get flooded with "ARISC ERROR" messages due to a different voltage regulator (full log):

[ARISC ERROR] :message process error [ARISC ERROR] :message addr  : f004b840 [ARISC ERROR] :message state : 5 [ARISC ERROR] :message attr  : 2 [ARISC ERROR] :message type  : 30 [ARISC ERROR] :message result : ff [ARISC WARING] :callback not install [cpu_freq] ERR:set cpu frequency to 1008MHz failed!

On the Orange Pi PC the SY8106A is accessible through I2C and the H3's AR100 OpenRISC core tries to adjust the CPU core voltage (VDD_CPUX) this way. On One and Lite a different voltage regulator is used: the SY8113B (datasheet) is a step-down converter that can adjust its output voltage driven by two resistors. According to Xunlong staff on OPi One this is used to switch between 1.1V at 624 MHz and 1.3V at every cpufreq above. Users that looked a little bit closer discovered that the similar AX3833 is used on the first batch of boards instead (see Gallery and link to datasheet below).

To get reliable performance/thermal behaviour with OS images that use legacy 3.4.x kernels adopted fex settings are needed. Please have a look in the aforementioned fex files from Armbian that implement this correctly. Same regarding WiFi: Please see above where to get the necessary patches to get RTL8189FTV up and running (the good news: since OpenELEC team who fixed the drivers relied on 8189es driver already ported to mainline the necessary fixes can be easily used to get WiFi working with kernel 4.x too)

CPU clock speed limit
Xunlong advertises both boards as being only capable of running at 'up to 1.2GHz'. Since the SY8113B/AX3833 voltage regulator should only be able to switch between 1.1V and 1.3V this would prevent clocking the SoC higher than 1200MHz according to the common comments in the FEX files from various H3 SDK variants:
 * dvfs voltage-frequency table configuration
 * pmuic_type:0:none, 1:gpio, 2:i2c
 * pmu_gpio0: gpio config.
 * pmu_levelx: 0~9999: voltage(mV), 10000~90000:gpio0 state. voltage form high to low.
 * extremity_freq(Hz): cpu extremity frequency when run benckmark or demo apk
 * 1536MHz@1500mV with radiator, 1296MHz@1340mV without radiator
 * max_freq: cpu maximum frequency, based on Hz, can not be more than 1200MHz
 * min_freq: cpu minimum frequency, based on Hz, can not be less than 60MHz
 * LV_count: count of LV_freq/LV_volt, must be < 16
 * LV1: core vdd is 1.50v if cpu frequency is (1296Mhz, 1536Mhz]
 * LV2: core vdd is 1.34v if cpu frequency is (1200Mhz, 1296Mhz]
 * LV3: core vdd is 1.32v if cpu frequency is (1008Mhz, 1200Mhz]
 * LV4: core vdd is 1.20v if cpu frequency is (816Mhz,  1008Mhz]
 * LV5: core vdd is 1.10v if cpu frequency is (648Mhz,   816Mhz]
 * LV6: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]
 * LV7: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]
 * LV8: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]
 * LV5: core vdd is 1.10v if cpu frequency is (648Mhz,   816Mhz]
 * LV6: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]
 * LV7: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]
 * LV8: core vdd is 1.04v if cpu frequency is (0Mhz,     648Mhz]

DRAM clock speed limit
DRAM is clocked at 672 MHz by the hardware vendor. But the reliability still needs to be verified. One of the ways of doing reliability tests may be https://github.com/ssvb/lima-memtester/releases/tag/20151207-orange-pi-pc-fel-test (developed for Orange Pi PC). An adoption of this using a fex file suited for Orange Pi One's/Lite's different voltage regulator is available here (md5sum: e600db41f94446bb77224223fc1dc2a0 fel-boot-lima-memtester-on-orange-pi-one-v3.tgz). Use the fel-boot-lima-memtester-on-orange-pi-one script inside to test both boards.

'''We need still more test results in the table above in order to have more accurate statistics and finally pick a safe default DRAM clock speed for U-Boot. Preferably there should be at least 10 entries in the table (more is always better). And there are no "good" or "bad" test results. Even if your result looks very similar to the already reported results from the other people, please still add yours to the table! Because if people don't feel like reporting their "boring" results, then "interesting" outliers will unfortunately skew the statistics. Thanks!'''

DRAM clock speed limit (automated statistical analysis)
Below is an intermediate analysis of the currently reported results, using the lima-memtester-genchart script (run the script using this page URL as the command line argument). Assuming that the Gaussian distribution is a good approximation, try to predict what percentage of boards is expected to pass the lima-memetser test at different DRAM clock frequencies. The lima-memtester page provides more information.

Updating the analysis report: wget https://raw.githubusercontent.com/ssvb/lima-memtester/master/lima-memtester-genchart ruby lima-memtester-genchart https://linux-sunxi.org/Xunlong_Orange_Pi_One
 * 1) copy/paste the script output into the linux-sunxi wiki

LEDs
The boards have two LEDs next to the 40 pin GPIO header:
 * A red LED, connected to the PA15 pin.
 * A green LED, connected to the PL10 pin.

When using kernel 3.4 with Xunlong's or loboris' settings then the LEDs can only be switched on/off. By changing the definition in the fex files (see patch or the aforementioned fex files for the One/Lite OpenElec and Armbian use) both LEDs can be used the usual way (using different triggers and so on)

Camera module
Xunlong sells also a cheap 2MP camera (an attempt to fix the driver's limited resolutions can be found here). Unlike Orange Pi Plus/2 that can directly connect to the camera module for the Orange Pi PC/One/Lite an 'expansion board' is needed (see gallery below). If you order from Xunlong simply tell them that you need the camera for Orange Pi One or Lite and they ship camera together with the small board.

HDMI to DVI converters
When trying to use HDMI to DVI converters with Allwinner's 3.4.x kernel for H3/R16/A83T/H8/R58 a small fix has to be applied. The fex file has to be modified (and converted back to script.bin afterwards) so that the following has been added to the [hdmi_para] section: hdcp_enable = 0 hdmi_cts_compatibility = 1

Orientation of the GPIO header
Due to the position of USB and/or Ethernet jacks Xunlong chose to rotate the 40 pin GPIO connector by 180° so RPi HATs can still be used but will project over the board in the opposite direction than intended. Keep this also in mind when you want to power the board through GPIO pins 2/4/6 (2/4 being connected directly with DC-IN and 6 being GND)

Adding ports/connectors that are missing
On the One the two missing USB ports, analog audio out, microphone, IR receiver and TV out are still available for people with soldering skills. Have a look into the gallery below or in the aforementioned thread for details. Same applies to the one missing USB port, analog audio out and TV out on the Lite

Locating the UART
The UART pins are located next to Ethernet / USB jack on the boards. They are marked as TX, RX and GND on the PCB. Just attach some leads according to our UART Howto.

= Pictures =

Orange Pi Lite
Please note that the boards are sold without any heatsink. This is just the tester's standard heatsink for all H3 boards now.

= See also =


 * Xunlong Orange Pi site
 * Official Github Repository.
 * Official Orange Pi Form.
 * H3_Manual_build_howto
 * Opi One Schematic v1.1: [[File:ORANGE PI-ONE-V1_1.pdf]]
 * Opi Lite Schematic v1.1: [[File:Orange_pi-lite-v1_1.pdf]]
 * AX3833 datasheet: [[File:AX3833.pdf]]

OS images
At the moment only OS images relying on Allwinner's 3.4.x BSP kernel are available for the boards. Most of them suffer from wrong settings for the different voltage regulator used on One and Lite, the only known exceptions are currently the Armbian images and OpenELEC for both boards and WiFi support for the Lite. Xunlong also released a new Android image for the Lite that should support the new WiFi chip and also work with the One (just based on assumptions and not tested).

In case you want to use other OS images with One and Lite be prepared to adjust fex settings to get thermal/performance settings right, that you need a kernel patch for the new WiFi module on the Lite and that all OS images except OpenELEC/Armbian use a horribly outdated kernel version 3.4.39 missing tons of fixes.

= References =