Lichee Pi Zero Camera support


No, not all pins are camera outputs if you consider the OV5647: external clock XCLK is an input, as well as PWDN and RESET.
OV5647 is I2C slave, so its SCL is an input too, that you feed with 3.3V when it is 3.0V max, not good design. An I2C translator should be used in this case, too.


The OV5647 has 3 voltages; core, analog and I/O.

The one used for data lines is the VDD-DO I/O voltage, which is specified as 1.7V~3.0V, typical is 1.8V, see OV5647 datasheet section 8.3 “DC characteristics”:

So, 3.3V is over the max voltage for I/O, which is 3.0V, it is out of specs, not good design!


XCLK input connected to generator on-camera-board. Not need connect to V3s.
PWDN, RESET, I2C - are “open drain”, pull-up resistors may be connected to +2.8V … +3V.


OK for XLCK, but the oscillator must then be powered from the correct power supply, not 3.3V! This is the case on the RPi camera board, but may not be the case for other camera boards.

PWDN and RESET are standard INPUTS, not open-drain OUTPUTS, so not good.

I2C SDA is I/O and SCL is INPUT, so not open-drain OUTPUT, and even SDA is mostl used as standard INPUT (except during ACK bit), so not good either. It is not good design at all to drive an I2C bus with different voltage supplies, this is why there exist I2C voltage translator chips or why FET transistors are used!

  1. PWDN and RESET sensor inputs, controlled by V3s pins.
    This pseudo-code emulate “open-drain” output (V3s pin + pull-up resistor):

if (value == “0”)
port_direction = “output”;
port_value = “0”;
port_direction = “input”;

If set “0”, pin output voltage = 0V,
if set “1”, pin output voltage = pull-up voltage.

  1. I2C “nodes” controls only “0” logical level (excluding “ultra-fast” mode).
    Logical “1” is by pull-up resistor.

Problems may be with logical levels thresholds. But differenсes of thresholds 2.8 and 3.3 V is small.


I think have more TODO, such as Allwinner sunxi-vfe, mipi-csi driver, must trasnsplant to linux-zero.
Looked at the source of linux-zero, some hardware have not drivers.
So firstly I plan to transplant sunxi-vfe relation code to current linux-zero.


thank you very much!
at this moment, you can use mainline uboot + bsp kernel to driver camera


Is there an update on the CSI camera driver? Which cameras are supported today for the CSI? Do you have instructions for installing the software and driver for CSI? Thank you!


Just to let you know: The CSI driver is now in the mainline linux kernel. So no patch is needed anymore!



So would IMX377 work now with this?

thank you!


No, only cameras with a parallel bus output are supported, like the OV7670 or OV2640 and even the OV5640. The maximum resolution supported by the V3s is 5 Megapixels in still images and 1080p@30fps in video.


OK, so IMX 264 would work? 5MP global shutter sensor?


I would rather use the OV5640 it has a parallel output and also has good driver support in the linux kernel.