#Pi Camera v2.1 - i need help
82 messages · Page 1 of 1 (latest)
It seems ustreamer cant read the data from the cam. Also it has some settings that arent supported by v4l2.
(The section in log with 0x..... entries)
[01/01/23 20:27:16] crowsnest: 1: -3667 (0xfffffffffffff1ad)
[01/01/23 20:27:16] crowsnest: 2: -3333 (0xfffffffffffff2fb)
[01/01/23 20:27:16] crowsnest: 3: -3000 (0xfffffffffffff448)
[01/01/23 20:27:16] crowsnest: 4: -2667 (0xfffffffffffff595)
[01/01/23 20:27:16] crowsnest: 5: -2333 (0xfffffffffffff6e3)
[01/01/23 20:27:16] crowsnest: 6: -2000 (0xfffffffffffff830)
[01/01/23 20:27:16] crowsnest: 7: -1667 (0xfffffffffffff97d)
[01/01/23 20:27:16] crowsnest: 8: -1333 (0xfffffffffffffacb)
[01/01/23 20:27:16] crowsnest: 9: -1000 (0xfffffffffffffc18)
[01/01/23 20:27:16] crowsnest: 10: -667 (0xfffffffffffffd65)
[01/01/23 20:27:16] crowsnest: 11: -333 (0xfffffffffffffeb3)
[01/01/23 20:27:16] crowsnest: 12: 0 (0x0)
[01/01/23 20:27:16] crowsnest: 13: 333 (0x14d)
[01/01/23 20:27:16] crowsnest: 14: 667 (0x29b)
[01/01/23 20:27:16] crowsnest: 15: 1000 (0x3e8)
[01/01/23 20:27:16] crowsnest: 16: 1333 (0x535)
[01/01/23 20:27:16] crowsnest: 17: 1667 (0x683)
[01/01/23 20:27:16] crowsnest: 18: 2000 (0x7d0)
[01/01/23 20:27:16] crowsnest: 19: 2333 (0x91d)
[01/01/23 20:27:16] crowsnest: 20: 2667 (0xa6b)
[01/01/23 20:27:16] crowsnest: 21: 3000 (0xbb8)
[01/01/23 20:27:16] crowsnest: 22: 3333 (0xd05)
[01/01/23 20:27:16] crowsnest: 23: 3667 (0xe53)
[01/01/23 20:27:16] crowsnest: 24: 4000 (0xfa0)```
Well, i tried it in every possible way:
Sry, somehow i sent this incomplete..
I tried:
camera_auto_detect=1
camera_auto_detect=0
dt-overlay=imx219
camera_auto_detect=0
dt-overlay=imx219,media-controller=0
vcgen.. reports
supported=1 detected=1, libcamera interfaces=0
Der Offizielle Raspberry Pi Kamera unterstützt Raspberry Pi und Jetson Nano Mit Sony IMX219 8-Megapixel-Sensor Erfasst Bilder von 3280 x 2464 Pixel Unterstützt 1080p30, 720p60 und 640x480p90 Videoaufnahmen Abmessungen: 25mm × 24mm × 9mm Kompatibel Raspberry pi 4, Raspberry pi 3 B +, Raspberry Pi ...
Somehow i'm actually stuck with this while:
-having the Legacy Camera Interface enabled
-boot.txt is set to camera_auto_detect=0
dt-overlay=imx219,media-controller=0
Well, do you use MainsailOS?
If yes, you shouldnt have made these changes. Ustreamer relies on the legacy camera stack. It simply does not work with libcamera
Set gpu_mem=256 ( for pi4 4G) and camera_auto_detect=0 nothing else.
Crowsnest does all needed modifications on install.
Yes, i'm on mainsail.
Please dont mix that terms! Mainsail is the gui running in your browser, mainsailOS the operating system running on your pi.
I'll give it a try, yet i'm a little suspicious that upping the gpu memory will make any differences.
I'm allready runing on legacy camera, with auto detect disabled. Thats how i've achieved the stuff posted above (latest log from )
And yes, i'm runing mainsail on mainsail os x64 1.0.1
Yes, the difference is, it enables the legacy camera stack 😉
Well, i dont know if it does. I just went on and enabled that manually to be safe.
Then please check for start_x=1 that is also needed
Sometimes enabling it using raspi-config it deletes thos entry for what ever reason
Remove the overlay entrys
gpu mem was allready set to 256.
The overlay entrys are only needed for libcamera stack
So like this?
Yes
Okay. I'll give it a try and send you a logfile.
I'm waiting for a print to finish before i can rebot tho.. will take 30 min.
I am only concerned about the entrys without correct translated v4l2 values
May be possible they changed the firmware to match libcamera stack, but thats out of my scope I only own a v2
I'd have guessed, that it simply ignores features it doesnt understand.
I am hoping for that
Well, it's an 8 years old camera - i have high doubts that it supports libcamera.
^^
Pardon me. 6 years.
We are a step further now at least. Ustreamer doesnt refuse to start correctly.
[01/01/23 22:46:16] crowsnest: DEBUG: ustreamer [cam 1]: -- ERROR [121.300 stream] -- Mainloop select() error: Inappropriate ioctl for device
That one shows the issue why there is no picture
I could imagine the ribbon is damaged or latest ustreamer changed something that I am not aware of
Well, i've actually meassured the ribbon end to end. It's fine. 😦
The last thing you could check, if the connector on the picamera pcb sits correctly, if you have thwn no luck, i will check tommorow if there where major or minor changes in ustreamer
Good morning. Unluckily the connector seems to sit tight.
Which leads me to assume that everything is correct, at least on the hardware.
I will look after possible changes in ustreamer. If there are non, something in your Hardware might died. But, I am at work so could take time.
Take your time. I'm in no hurry. I also have a space C920, so i'll might just use this in the meantime.
Well, I flashed a fresh copy of 1.0.1, waited for rebooting complete, added in Mainsail a webcam and it just works. There wasnt a change in ustreamer which could cause an Issue.
That is my Version that I use..
Looks mostly as mine does.
But mine says V2.1
Anyhow, i've tried the cam using the stock raspberry os (it worked there) and gone so far to use a spare sd to write mainsail os to it etc. - nada, doesnt work,
Stock RaspiOS uses Libcamera not legacy stack. I guess thats the issue here
I've had enough tbh.
As much as i love tinkering with stuff, it's just not worth wasting another day, and even someone elses time on this.
I would like to help you, but I guess its easier to mount the Logitech to that printer then. But will see to get some more info about that
Well, thats been the firt image (0114) i've sent you.
I just did that, i modified the c920 mount to fit my setup, printed it and attached that one.
Worked OOTB.
Glad to see there is a solution, even not the one you'd like to see 🙂 But, I will keep investigating, for that Cam, I am really curious to see why it doesnt like Crowsnest 😉
While it is an solution, i'm not quite happy with it. It's slow as hell when there's a print runing. I'm getting around 10-15fps in Idle, as soon as i prind it breaks apart to 1-3fps. It's really annoying.
Thats your wifi bandwidth, best idea would be reduce your resolution
Well, i highly doubt that. I'm on Wifi6 all the way.
Also it's slow on 640x480 as it is on 1920x1080p
This also sort of contradicting to the way it behaves, it's slow when it prints, when on idle or pause its back to around 10 fps.
Not sure if a rPI works on wifi6 but even yes that would not be a guarantee for a high data rate
It should run much smoother with lower resolution as you transfer less data
adaptive could be also an option in low resolution is it takes snapshots as fast as possible what get you a lower latency
Is it possible you run the cam on a usb hub where your boards are connected?
And no, the pis Wifi Module is limited to 72.2Mbits/s, so no gain in performance with wifi6.
Well, while i said im on wifi6 i didnt meant the pi4 is going hyperspeed, i just meant that i'm in doubt that it's a network issue (which proved to be the right assumption). Actually i could replicate the issue: idle: 20fps, in print 0-3 fps - i honetly dont know what the issue was, but i can assure that removing and reinstalling crowsnest fixed the issue.
No one said it is a network issue! Your usage bandwidth depending on the location, how much traffic you have in your area and so one
Well, thats what i count as network issue - talked at cross purposes i guess. But like i said, i've fixed it.