Jana-Marie / OtterCam-s3

Open source 1080p60Hz USB & IP camera based on Sochip s3 and OS05A10/OS05A20 (general MIPI CSI IP camera interface).
Other
41 stars 4 forks source link

Firmware #1

Open EmmanuelP opened 1 year ago

EmmanuelP commented 1 year ago

Hi Jana-Marie,

Interesting project. Do you plan to also open source the firmware ?

I'm the maintainer of the Aravis project, an open source implementation of GiGEVision and USB3Vision protocols. If time permits, I'd like to try to implement the camera part of one of these protocols for the OtterCam.

https://github.com/AravisProject/aravis

Emmanuel.

Jana-Marie commented 1 year ago

Hey Emmanuel! Yea I plan to Open Source everything, include FW and all build sources. It sadly just isn't there yet. The Linux boots already and shows the sensor on the I2C bus, and has a ready to receive MIPI driver. However userspace software sending the right I2C commands is missing, we are working on that!

I would love to have the OtterCam-s3 (another OtterCam with NDI is in the works. It has the FW, Linux and HDL ready, but is missing the HW. The OtterCam-s3 is a HW sanity check and the cheaper variant of it.) added to aravis! I stumbled across your library just a few days ago, trying to revive a SVS-Vistek GigE cam. Fantastic work! :3

Jana-Marie commented 1 year ago

Bump: We are still working on it, sorry for all the delay 🙈

Alan01252 commented 2 weeks ago

As someone about to potentially embark on a similar journey, how did you get on :)?

Jana-Marie commented 2 weeks ago

Honestly, we didn't. Didn't yet, although what is that yet worth. I haven't given up on the OtterCamS3, but I also haven't worked on it in a while. We lost all momentum and haven't regained it yet, so I'm afraid there is no good answer to "how did you get on" :/

peteallenm commented 1 week ago

I'm very interested in this. I've got some very relevant experience-I've written a mipi driver for S3 with hdzero cameras (drone cameras with mipi csi yuyv output). I'm looking for better sensors (hdzero is 720/60) and so was looking at these omnivision sensors. Do you want to collaborate?

Jana-Marie commented 1 week ago

Hey all and @peteallenm,

Thank you so much for your interest, collaboration would be highly welcome :3

As it seems, we need to tackle the following tasks next:

There is actually already a working fork of the OtterCam3, which already addresses the driver + stream issue 🙈 We will try to incorporate it back into the OtterCamS3, leaving us with less and easier issues to work on. https://gregdavill.com/posts/allwinner-s3-videoencoders/

I'm away until mid-July. Your interest motivates me to work on this project again, I will return to it in July and I will try to get it to a working point. I'm not entirely sure how further collaboration works the best, any ideas?

~ Jana

peteallenm commented 1 week ago

Have you got a datasheet for the OS05A10? One of the first things with the driver is to set up the (MIPI) bus format, and that is not easy without the datasheet. I also presume you are using the onboard ISP, so intending to get the sensor to give you what it describes as RGB? I haven't looked into the S3 ISP at all, but understand debayering should be possible, but tuning the ISP for a sensor is out of reach for hobbyists, so the onboard ISP makes a lot of sense. The datasheet for OS08A20 (same range, different sensor) mentions YUV420p output (which would be ideal), but not anything about specifics of it. The OS05A20 drivers I've seen on github confuse me a little as they seem to be bayer output, which is not ideal, but I've only looked at a couple. Just FYI I had to fix a load of bugs in the MIPI driver for YUYV formats on S3.

It's pretty easy to send I2C from userspace... i2cset is your friend.

peteallenm commented 1 week ago

Oh - you mentioned getting raw images out: v4l2-ctl --set-fmt-video=width=1280,height=720,pixelformat=NV12 --stream-mmap --stream-count=1 -d /dev/video0 --stream-to=CamOutNV12.raw Obviously change the video format to suit.

Can you point me to the working fork of ottercam 3? I am pretty interested