All the sensor drivers are open source now, so there's no need for the magic messing around that raspiraw did.
Compile based on https://www.raspberrypi.com/documentati ... l#building and ensure that you can get your kernel running.
Take the driver at https://github.com/raspberrypi/linux/bl ... i2c/ov5647.
Duplicate the table ov5647_640x480_10bpp and modify it with the relevant cropping registers (0x3808/9 for width, 0x380a/b for height, 0x3800/1 for left, and 0x3802/3 for top).
Add a new entry in ov5647_modes with your width, height, pointed at your new register table, and set vts to the relevant height with blanking for your settings.
Enjoy your shiny new mode.
In theory this can be done via the s_selection API hook (as done for imx296 GS camera), but it's implementing all the restrictions on the alignment that is a real faff.
Compile based on https://www.raspberrypi.com/documentati ... l#building and ensure that you can get your kernel running.
Take the driver at https://github.com/raspberrypi/linux/bl ... i2c/ov5647.
Duplicate the table ov5647_640x480_10bpp and modify it with the relevant cropping registers (0x3808/9 for width, 0x380a/b for height, 0x3800/1 for left, and 0x3802/3 for top).
Add a new entry in ov5647_modes with your width, height, pointed at your new register table, and set vts to the relevant height with blanking for your settings.
Enjoy your shiny new mode.
In theory this can be done via the s_selection API hook (as done for imx296 GS camera), but it's implementing all the restrictions on the alignment that is a real faff.
Statistics: Posted by 6by9 — Thu Dec 18, 2025 5:12 pm