Raspberry Pi 4 Webcam doesn't work

Hi there,

I'm the new one :wink: I've been trying for weeks now to get my webcam on my Raspberry 4 to work. Without success. The problem: the snapshot of the camera is displayed, but not the stream. I give up and therefore turn to you :wink:

Here are my log files:

octoprint-systeminfo-20220114112252.zip (17.6 KB)

My webcam is: MakerHawk night vision camera with 5 MP and OV5647 chip.
Exactly it is this one:

I have been the owner of a Creality CR-10 v3 and and Raspi 4 since 11/2021, so for a short time and had no experience with Linux until then. However, after hours of reading forum posts, I got a bit into it. I've turned a lot on the screws for the settings, but nothing has worked. What am I doing wrong?

I downloaded the current image here and installed it according to the numerous instructions available on the Internet.

  • Image downloaded here

  • Written to a Sandisk extreme 32GB MicroSD with rufus

  • Raspi is in my LAN with a fixed IP of 192.168.1.7, so no WLAN configuration

  • Login to the raspi with PuTTY and change the password, sudo get update / upgrade and activate the camera in the config with sudo raspi-config

  • Start and initial setup of the Octopi web interface

I haven't changed anything in the webcam settings in Octopi, with the address octopi.local/webcam/ there is a snapshot of the camera but the stream doesn't work.

I give up and hope to find an answer here.

Thanks very much !

Greetings ZBX

Hi :octopus:

Try http://192.168.1.7/webcam/?action=stream as stream url.

Also try to open the url in a browser.

Hi Weezl,

no result for http://192.168.1.7/webcam/?action=stream

This is what I see when I type http://octopi.local/webcam/ into my Chrome Browser:

Any other ideas?

That's weird
Can you check if the snapshot was taken recently (for example by putting a rubber ducky in front of the cam :wink: )?

I want to make sure that the webcam streamer software didn't crash and is showing the snapshot of a live stream.

It a fresh snapshot :wink:

One more thing:
The settings in Octopi:

(As a new user, I can only insert 1 picture, hence 3 posts)

When I press the "Test" button comes a snapshot:

If I type this address in the browser, nothing comes up:

Very strange...

Indeed.

Can you ssh into the pi and run

sudo systemctl restart webcamd

we had other users that had to restart the webcam streamer once after each boot
if it helps we will automate it

Hi,
nothing happens or changes.
The screenshot can be called up again after approx. 1 minute. The stream still doesn't work...
I'm still clueless...

Is there anything in the browser console when you open that page with the stream/snapshot displayed? Any errors might give you a clue as to what is going on there. The webcam log in your systeminfo bundle makes it seem like everything is going OK.

@Charlie: What do you mean with "browser console"?
This is a current snapshot with typing http://octopi.local/webcam/ into Chrome

This also work with the octopi-URL http://127.0.0.1:8080/?action=snapshot

The URL for Stream in octopi /webcam/?action=stream doesn't work

The URL should be with http://yourIP in front of it, like http://192.168.1.155/webcam/?action=stream.

Here's a guide of how to access the browser console to check for errors:

Hi, everyone,
I was about to continue troubleshooting and suddenly the stream works :wink:

I haven't changed or added anything. The same computer only that and the Raspi were switched off for 3 days ;-))))

I haven't changed or added anything. The same computer only that and the Raspi were switched off for 3 days ;-))))
I almost don't believe it myself...
Hopefully it stays that way now. Not that the stream stops working the next time you turn it off.

Nevertheless, many thanks to you!

It looks like you are using the IP address now, instead of octopi.local. I wonder if that is making a difference.

Hi Charlie,
octopi.local also works...

the screenshot before was directly from Octoprint... the camera didn't work there...