==== Orange Pi Zero ====
{{:boards:opi0-1.jpg?200|Orange Pi Zero}}
The Orange Pi Zero is a Linux compatible computer with high speed GPIO.
It contains four ARMv7 CPU cores present in the AllWinner H2+ (cost reduced H3) system on a chip.
A debian derived distribution of Linux called Armbian works on this device. It's important
to install this on a class 10 microsd card and not a class 4 which has incredibly poor
write performance. A sandisk ultra micro SDHC 10x works well.
=== GPIO ===
The board has a [[boards:rpi|Raspberry Pi]] compatible GPIO header with 26 pins, an Orange Pi Zero specific header with 13 pins and a serial console at 9600 baud.
Whilst the GPIO header is compatible with the RPi the orientation is different.
5V USB LAN GND PA10 26 25 GND
GND RX PA13 24 23 PA14
USB-DM2 TX PA02 22 21 PA16
USB-DP2 GND 20 19 PA15
USB-DM3 PA18 18 17 3V3
USB-DP3 PA19 16 15 PA03
LINEOUTR GND 14 13 PA00
LINEOUTL PA07 12 11 PA01
TV-OUT PG07 10 09 GND
MIC-BIAS PG06 08 07 PA06
MIN1P GND 06 05 PA11
MIN1N 5V 04 03 PA12
IR-TX POWER 5V 02 01 3V3
This is the relationship between the Orange Pi Zero GPIO pins, H2+/H3 I/O, Linux sysfs interface and the H2+/H3 alternate pin functions.
^Pin ^H2+/H3 I/O ^sysfs ^ALT |
| 3 | PA12 | 12 | SDA |
| 5 | PA11 | 11 | SCK |
| 7 | PA6 | 6 | PWM |
| 8 | PG6 | 198 | TxD |
| 10 | PG7 | 199 | RxD |
| 11 | PA1 | 1 | RxD |
| 12 | PA7 | 7 | |
| 13 | PA0 | 0 | TxD |
| 15 | PA3 | 3 | CTS |
| 16 | PA16 | 16 | SDA |
| 18 | PA18 | 18 | SCK |
| 19 | PA15 | 15 | MOSI |
| 21 | PA16 | 16 | MISO |
| 22 | PA2 | 2 | RTS |
| 23 | PA14 | 14 | CLK |
| 24 | PA13 | 13 | CS |
| 26 | PA10 | N/A | |
=== Pickle Microchip PIC ICSP ===
{{:boards:opi0-icsp.jpg?200|La naranja 0}}
We can use the Orange Pi Zero GPIOs to program PICMicros using [[projects:pickle|Pickle Microchip PIC ICSP]].
The [[projects:gpio-bb|GPIO bit-bang driver for Linux]] may also be utilised on the Orange Pi Zero
and uses the same numbering.
== Low Voltage Programming with VPP at 3V3 ==
Low voltage ICSP at 3V3 can be performed directly from the GPIOs.
The following connections refer to the GPIO header. Ensure that power is only ever applied from GPIO 3V3 on PIN 1 and never 5V.
Single common data I/O connection (OPI0 or GPIO bit-bang driver) without PGM.
OPi0 H2+/H3 PICMicro GPIO header .pickle
=========== ======== =========== =======
3V3-------------------------------VDD--+ PIN 1
|
GND-------------------------------VSS R1 PIN 9
|
PA12-----------R2-390R------------VPP--+ PIN 3 VPP=12
PA11-----------R3-390R------------PGC PIN 5 PGC=11
PA06-----------R4-390R------------PGD PIN 7 PGD=6
PGM=-1
(R1) 10K !MCLR pull-up
(R2..R4) 390R.
DEVICE=OPI0
or
DEVICE=GPIO-BB
IFACE=/dev/gpio-bb
=== Resources ===
[[http://linux-sunxi.org/images/4/4b/Allwinner_H3_Datasheet_V1.2.pdf|H2+/H3 data-sheet]] \\
[[http://linux-sunxi.org/images/e/e0/Orange-Pi-Zero-Schanetics-v1_11.pdf|Schematic]] \\