adafruit_ov2640
CircuitPython driver for OV2640 Camera.
Author(s): Jeff Epler
Implementation Notes
Hardware:
Software and Dependencies:
Adafruit CircuitPython firmware for the supported boards: https://github.com/adafruit/circuitpython/releases
Adafruit’s Bus Device library: https:# github.com/adafruit/Adafruit_CircuitPython_BusDevice
- class adafruit_ov2640.OV2640(i2c_bus: I2C, data_pins: Pin, clock: Pin, vsync: Pin, href: Pin, shutdown: Pin | None = None, reset: Pin | None = None, mclk: Pin | None = None, mclk_frequency: int = 20000000, i2c_address: int = 48, size: int = 1)
Library for the OV2640 digital camera
- Parameters:
i2c_bus (busio.I2C) – The I2C bus used to configure the OV2640
data_pins (List[microcontroller.Pin]) – A list of 8 data pins, in order.
clock (microcontroller.Pin) – The pixel clock from the OV2640.
vsync (microcontroller.Pin) – The vsync signal from the OV2640.
href (microcontroller.Pin) – The href signal from the OV2640, sometimes inaccurately called hsync.
shutdown (Optional[microcontroller.Pin]) – If not None, the shutdown signal to the camera, also called the powerdown or enable pin.
reset (Optional[microcontroller.Pin]) – If not None, the reset signal to the camera.
mclk (Optional[microcontroller.Pin]) – The pin on which to create a master clock signal, or None if the master clock signal is already being generated.
mclk_frequency (int) – The frequency of the master clock to generate, ignored if mclk is None, requred if it is specified
i2c_address (int) – The I2C address of the camera.
- capture(buf: array | bytearray | memoryview | rgbmatrix.RGBMatrix | ulab.numpy.ndarray) memoryview | None
Capture an image into the buffer.
- Parameters:
buf (WriteableBuffer) – A WritableBuffer to contain the captured image. Note that this can be a ulab array or a displayio Bitmap.
- property capture_buffer_size: int
Return the size of capture buffer to use with current resolution & colorspace settings