Page 1 of 1

ESP32 - CSI Camera interface driver

Posted: Thu May 03, 2018 9:14 pm
by wwwenrico
Hi,

I can't find the driver of the CSI Camera interface in the ESP32 IDF.

Does the ESP32 chip actually have a hardware CSI Camera interface?
The pins are: D0, D1, D2, D3, D4, D5, D6, D7, PXCLK, HREF, VSINCH

Thanks,
Enrico Migliore

Re: ESP32 - CSI Camera interface driver

Posted: Thu May 03, 2018 9:17 pm
by WiFive

Re: ESP32 - CSI Camera interface driver

Posted: Thu May 03, 2018 10:45 pm
by wwwenrico
Thank you for the link.

What is the parallel "I2S input interface"?

The I2S interface is meant for digital audio and it's supposed to be a serial interface.

Enrico Migliore

Re: ESP32 - CSI Camera interface driver

Posted: Thu May 03, 2018 11:45 pm
by kolban
Howdy,
I found that chapter 12 of the ESP32 technical reference manual to be useful in this regard:

https://www.espressif.com/sites/default ... ual_en.pdf

Think of "I2S" in ESP32 as being "more" than just the basic I2S protocol (which it can do handily). The I2S subsystem in the ESP32 also provides a high speed bus connected directly to RAM for Direct Memory Access. Putting it simply, you can configure the ESP32 I2S subsystem to send or receive parallel data under hardware control. For example, if a frame from a camera is 16bit pixel sizes and is 320x240 pixels ... that is 320x240x2 bytes = 153KBytes. If the frame rate is 24 frames/second then 1 frame is about 40msecs. It would be impossible (or VERY hard) to read 16 parallel pins 76800 times in 40msecs AND store that in RAM under application logic control. Hence we need a DMA technology that will read lots of data that is synchronized by a high speed clock line and writes it sequentially into RAM. The ESP32 can do this well.

Arguably, this subsystem might have been described as the "DMA subsystem" however its primary purpose was for I2S data and hence got lumped in as the I2S subsystem. But a rose by any other name still smells as sweet.

Re: ESP32 - CSI Camera interface driver

Posted: Fri May 04, 2018 12:49 pm
by wwwenrico
Hi Kolban,

>> you can configure the ESP32 I2S subsystem to send or receive parallel data under hardware control
Thank you for your explanation.

Enrico Migliore