PicoCamera 0.2.0
Camera library for RP2040 with an esp32-camera compatible API
GitHub
Loading...
Searching...
No Matches
gc032a.cpp File Reference

GC032A sensor driver. More...

#include "gc032a.h"
#include "pico/stdlib.h"
#include "../driver/sccb.h"
#include "gc032a_regs.h"
#include "gc032a_settings.h"
Include dependency graph for gc032a.cpp:

Macros

#define H8(v)
#define L8(v)

Functions

int gc032a_detect (sensor_t *sensor)
 Probe the bus for a GC032A. On success fills sensor->id.
int gc032a_init_sensor (sensor_t *sensor)
 Fill sensor_t function pointers and write the default register set.

Detailed Description

GC032A sensor driver.

Register tables and control logic adapted from esp32-camera's gc032a.c (Apache-2.0). The GC032A has no JPEG encoder, so set_pixformat(PIXFORMAT_JPEG) always fails; the core also rejects it up front via camera_sensor_info_t.support_jpeg.

Framesize scaling uses windowing: crop the requested window out of the full VGA frame (esp32-camera's gc032a.c has no subsample mode).

Macro Definition Documentation

◆ H8

#define H8 ( v)
Value:
((v)>>8)

◆ L8

#define L8 ( v)
Value:
((v)&0xff)

Function Documentation

◆ gc032a_detect()

int gc032a_detect ( sensor_t * sensor)

Probe the bus for a GC032A. On success fills sensor->id.

Returns
0 if detected

◆ gc032a_init_sensor()

int gc032a_init_sensor ( sensor_t * sensor)

Fill sensor_t function pointers and write the default register set.

Returns
0 on success
中文文档