ArduCAM / Arducam_Mega

MIT License
14 stars 12 forks source link

Manual exposure not working + gain oddities #12

Open tbbuck opened 1 year ago

tbbuck commented 1 year ago

I'm using the 3MP model on a Raspberry Pi Pico with the full_featured example. Setting manual exposure via the Ardulink app does not change the output image at all, and the image data is returned instantly. Changing the manual gain, values seem very on/off, with huge jumps in sensitivity between integer steps between 1 and 10. Both of these actions are performed after turning off auto exposure / gain.

I wrote a test Web Serial implementation to query over Ardulink, and ReportCameraInfo says:

Status: ReportCameraInfo
Camera Type:3MP
Camera Support Resolution:7638
Camera Support specialeffects:319
Camera Support Focus:0
Camera Exposure Value Max:30000
Camera Exposure Value Min:1
Camera Gain Value Max:1023
Camera Gain Value Min:1
Camera Support Sharpness:1

Is the correct register being used? I've noticed that this varies in implementations, for example CAM_REG_MANUAL_EXPOSURE_BIT_7_0 is 0x35 in https://github.com/ArduCAM/Arducam_Mega/blob/3e7eb78bfcabf80aeafd05c2c040760ca69adc49/src/Arducam/ArducamCamera.c#L65 and it is 0x2f in https://github.com/ArduCAM/Arducam_Mega/blob/3e7eb78bfcabf80aeafd05c2c040760ca69adc49/examples/RaspberryPi/capture/Arducam.c#L61

Thanks!