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

Does not work with Raspberry Pi Camera Module 3 #15

Open
cHemingway opened this issue Sep 17, 2023 · 4 comments
Open

Does not work with Raspberry Pi Camera Module 3 #15

cHemingway opened this issue Sep 17, 2023 · 4 comments

Comments

@cHemingway
Copy link

Hi,

I am trying to run this on Raspberry pi OS 64 bit (thanks for the update!) on a Pi4 with Camera Module 3, and a HDMI display.

On startup, it connects to the web portal, then immediately crashes with a GetUserMedia error. Here is the debug output:

2023/09/17 11:51:56 Arena: WS connected
2023/09/17 11:51:56 GetUserMedia error inappropriate ioctl for device
panic: inappropriate ioctl for device

goroutine 37 [running]:
github.com/roboportal/bot_box/pkg/arena.(*AnArena).Run(0x400011da00)
        /home/pi/bot_box/pkg/arena/arena.go:220 +0x1c10
created by main.main in goroutine 1
        /home/pi/bot_box/main.go:167 +0x8b4

With legacy camera support enabled instead, I get a similar error, though not exactly the same.

2023/09/17 11:58:45 GetUserMedia error Failed to start streaming: invalid argument
panic: Failed to start streaming: invalid argument

goroutine 23 [running]:
github.com/roboportal/bot_box/pkg/arena.(*AnArena).Run(0x40000ad860)
        /home/pi/bot_box/pkg/arena/arena.go:220 +0x1c10
created by main.main in goroutine 1
        /home/pi/bot_box/main.go:167 +0x8b4
@malykhin
Copy link
Member

Hi @cHemingway,
Thank you for opening this issue.

As far as I can see, the error is coming from https://github.com/pion/mediadevices, specifically from its dependency: https://github.com/blackjack/webcam.

These packages only work with 'Legacy camera mode' on the new OS and do not support camera module v3.

We are working on an alternative camera driver for mediadevices based on libcamera. However, it will be a long process if successful.

@cHemingway
Copy link
Author

Thanks for getting back to me. I am using the legacy camera mode as well as I suspected as such, but legacy camera mode still does not work, see my 2nd error message.

@malykhin
Copy link
Member

Correct, it won’t work for both “non-legacy” mode and camera module v3

@cHemingway
Copy link
Author

Ah sorry, didn't see that bit! Thanks for letting me know.

@cHemingway cHemingway changed the title Error/s in GetUserMedia Does not work with Raspberry Pi Camera Module 3 Sep 22, 2023
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

2 participants