Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing support for RPi camera (sensor IMX219) #123

Open
silentjet opened this issue Jul 20, 2024 · 7 comments
Open

Missing support for RPi camera (sensor IMX219) #123

silentjet opened this issue Jul 20, 2024 · 7 comments

Comments

@silentjet
Copy link

silentjet commented Jul 20, 2024

RPi camera module of the first version is rather rarely available these days, instead the most common is RPi camera module v2, which uses a different sensor - IMX219. Please add the support for this camera module....
Also it would be nice to add IMX708 as well

@piotr-defendeye
Copy link

Bump

@Gety0
Copy link

Gety0 commented Jul 23, 2024

I just today hooked it up expecting it to work right away, but: init middleware failed! ret=ffffffff.
The cameras should have identical pin-outs. It seems some drivers are already out there: IMX219 driver for linux(github.com)

@Gety0
Copy link

Gety0 commented Jul 25, 2024

After a bit of digging i found out there are "traces" of it in Milk-v buildroot:

I am not too good at Milk-V embedded Linux OS but maybe we only need to add an appropriate configuration "sensor_cfg.ini" to /mnt/data/sensor_cfg.ini in order to make it work... I will tinker with this later and report if i there is more progress after creating the correct .ini... I do not know if the lane_id is the same or not, but i would not know where to look to find out... I do not know if i need to pinmux stuff to make the camera work etc. I know that in order to use I2C one has to pinmux the SDA,SCL pins. Disregarding all worries, the github link above suggests that it should be pretty much plug and play.

edit
this is the file i came up with, will test later and report if it works or not:

edit2
it does not work unfortunately. i do not have an rpi to confirm if the camera is even functional, so i am going to stop here... Hope this helps someone

sensor_cfg.ini

;section for source
[source]
type = SOURCE_MIPI_2M_30FPS_10BIT
dev_num = 1

;section for sensor
[sensor]
name = OV_IMX219_MIPI_8MP_30FPS_10BIT
bus_id = 2
sns_i2c_addr = 0x10
mipi_dev = 0
lane_id = 5, 3, 4, -1, -1
pn_swap = 0, 0, 0, 0, 0

@silentjet
Copy link
Author

So when we talk about different RPI cameras on a physical level (by pin designation) they are the same or compatible. What IS different is a sensor's bus configuration, because the configuration depends on the sensor hardware. Normally it shall be configured via device tree files (remember that Rpi's *.dtbo files?), but here is taken a different approach...

@piotr-defendeye
Copy link

Has anyone had any success with this?

@raphaelscholle
Copy link

getting new cameras working is really hard and expensive, I did glance at this repo a while, but didn't really work on anything here.
Usually I'll just write a device tree overlay and make the driver work, (everything else is usually commissioned).But it looks like this is a little different.

@raphaelscholle
Copy link

you also forget something important .. the rpi-mipi-csi port is 3.3V logic level, the civitec one is 1.8, so a adapter should always be needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants