Notifications
Clear all

Can't get the webcam to work with Octoprint.  

Strona 1 / 4
  RSS
BillR94
(@billr94)
Eminent Member
Can't get the webcam to work with Octoprint.

I  put a raspberrypi zero 2 W in my MK3S+ and can't get the webcam to work. I have followed the instructions from Prusa's help files and configured the settings as instructed. Everything seems to work except for the camera. I am getting a "webcam stream not loading" error. I have attached the settings page showing the webcam stream url. I am using a Logitech C270 HD Webcam, 720p. It previously worked just fine. I also tested the webcam on another device and it worked as it should. And yes, I enabled the webcam.

Can anyone help with a resolution for this issue? Thank you for your time.

Bill

Best Answer by Walter Layher:

What is this IP address there? Is this your DNS server? If this is the IP of your Pi you have found the source of the problem. Replace it with "nameserver 8.8.8.8" and you will most certainly see a difference.

This topic was modified 12 months temu by BillR94
Opublikowany : 02/10/2023 12:18 am
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

Did you attach the camera to the correct USB port? One is for power, the other for data. See here: https://community.octoprint.org/t/c270-octoprint-prusa-mk3-the-webcam-server-is-currently-not-running/41541/4

Opublikowany : 02/10/2023 12:51 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

Yes, I have it connected to the micro USB 2.0 (for peripherals).

Any other suggestions?  Good suggestion tho!

Opublikowany : 02/10/2023 2:13 am
Walter Layher
(@walter-layher)
Prominent Member
RE:

Which kind of adapter are you using to get from USB A on the webcam to MicroUSB on the Pi? Did you use the same adapter for connecting the camera on other host devices? Or did you connect the camera to those with the USB A plug?

Did you test with lsusb on the Pi console (via ssh) if the Pi does recognize the camera?

Opublikowany : 02/10/2023 2:46 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE:

I did not use the adapter when I connected the camera to the other device. I never thought to check that! VERY good idea! I check it ASAP.

Also, there error talks about the url settings (as shown in the picture). Is that the correct url for this application?

Opublikowany : 02/10/2023 2:50 am
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

I think the URL should work if the camera is recognized by OctoPrint.

Opublikowany : 02/10/2023 2:59 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

ok...thanks. I went to check the adapter but realized that I have no place/device to plug the end in that goes to the raspberrypi!

Opublikowany : 02/10/2023 3:02 am
Walter Layher
(@walter-layher)
Prominent Member
RE:

An older Android phone or tablet that still has MicroUSB?
I saw some recommended connecting the camera via a powered hub in case the power supply for the Pi (via the MK3S board) does not have enough power. OTG adapters also are a bit temperamental and do not always work with all devices. You could also try to temporarily use a normal power supply via the USB socket on the Pi to see if that changes anything.

Opublikowany : 02/10/2023 3:29 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

I will try that. Thank you

Opublikowany : 02/10/2023 3:43 am
Hello
(@hello)
Noble Member
RE: Can't get the webcam to work with Octoprint.

 

Posted by: @billr94

I will try that. Thank you

Can you take a picture of how it's connected to the pi please 

Please help me out by downloading a model it's free and easy but really helps me out https://www.printables.com/@Hello_474427/models

Opublikowany : 02/10/2023 8:32 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

Here you go.....

Opublikowany : 02/10/2023 8:11 pm
Hello
(@hello)
Noble Member
RE: Can't get the webcam to work with Octoprint.

 

Posted by: @billr94

Here you go.....

Can you confirm if the camera is plugged into top or bottom usb port I've got a feeling that cable coming out of the blue adapter is power only

Please help me out by downloading a model it's free and easy but really helps me out https://www.printables.com/@Hello_474427/models

Opublikowany : 02/10/2023 10:46 pm
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

Nope, I confirmed that the it is MOT plugged into the power port.

Opublikowany : 03/10/2023 4:43 am
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

I don't know if you understand German, but I found this forum posting (no. 14 on the page) here.
It basically says that his camera works with a passive USB hub between the camera and the pi, but not when the camera is plugged in directly into the pi.

Opublikowany : 03/10/2023 7:54 am
Hello
(@hello)
Noble Member
RE: Can't get the webcam to work with Octoprint.

 

Posted by: @billr94

Nope, I confirmed that the it is MOT plugged into the power port.

Im not unabout on the pi some usb leads are power only so the one from the blue adapter to pi might not be data

Please help me out by downloading a model it's free and easy but really helps me out https://www.printables.com/@Hello_474427/models

Opublikowany : 03/10/2023 8:14 am
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

OK... I have replaced the pi, re-imaged it, replaced the dongle and still the camera will not connect. I then re-imaged it to Prusalink and the camera works fine.

So, there must be an issue with Octopi.

Opublikowany : 05/10/2023 4:39 pm
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

Can you post the content of the file /boot/octopi.txt?

Opublikowany : 05/10/2023 5:34 pm
BillR94
(@billr94)
Eminent Member
Topic starter answered:
RE: Can't get the webcam to work with Octoprint.

ok...I attached it

Opublikowany : 05/10/2023 6:38 pm
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

I can't open the attachment. That file is just a few lines of text, you can just paste the content into the message box as text.

I have just imaged a new octopi onto a Raspberry Zero W. Have been trying to get a new Zero 2 W for quite a while without success. I hope the old style Zero W will be enought to get you going ... 🙂

I still have a Logi Webcam.  lsusb via ssh looks good so far:

pi@octopi:~ $ lsusb
Bus 001 Device 002: ID 046d:0826 Logitech, Inc. HD Webcam C525
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Perhaps we'll get somewhere with this. I used the new image with the new camera stack, available here.

Opublikowany : 05/10/2023 6:49 pm
Walter Layher
(@walter-layher)
Prominent Member
RE: Can't get the webcam to work with Octoprint.

Just ran the install assistant for OctoPrint. The webcam is working for me!
For setting up the sdcard I only filled in my wifi credentials  in the wpa_supplicant file. No other changes for the camera. Worked out of the box.
Which image version of OctoPi did you use?

Opublikowany : 05/10/2023 6:54 pm
Strona 1 / 4
Share: