#help Every time the printer is powered on or restarted, the pi camera doesn't work

172 messages · Page 1 of 1 (latest)

lethal tulip
#

Saya menggunakan RPI 3B+ dan Pi Cam V1.3. Setiap kali printer didukung atau dihidupkan ulang, kamera tidak berfungsi kecuali saya menekan tombol "Restart Crowsnest" terlebih dahulu - dan bahkan kemudian, kadang -kadang hanya berfungsi.

Ketika saya mencoba menjalankan libcamera-hello-list-cameras via ssh, saya mendapatkan:

pi @blissful umbra os: ~ $ libcamera-hello-list-cameras
Tidak ada kamera yang tersedia!

Saya juga memeriksa file crowsnest.log dan tidak ada ID perangkat yang ditampilkan - hanya sesuatu seperti:

Perangkat 'LibCamera' yang terdeteksi ->/basis/soc/i2c0mux/i2c@1/ov5647@36@36

Tapi sekarang hanya mendeteksi perangkat 'raspicam' di /dev /video0.

Saya sudah mengikuti panduan dari tautan ini:
https://crowsnest.mainsail.xyz/faq/how-to-setup-a-raspicam
Tapi saya masih mendapatkan hasil yang sama.

timber ibexBOT
#

Ahoi @lethal tulip!
Welcome to the Mainsail support-forum!
There is a problem with the tags you selected for this post. Please fix them to fit your question.
For further information on tags please check the readme: https://discord.com/channels/758059413700345988/1320321898009071616

To change the tags of this post:

  1. Open the ... menu on the top right corner of this post.
  2. Find Edit tags
  3. Select the checkbox of the correct tags.

Usually you just need to select one tag!
If you still have no idea which one to choose, feel free to ask here.

Note: This is an automated message

Thanks for your cooperation!

magic viper
#

Fix your tags

#

This server is english only too. So don't write in your native language
You copied it multiple times already and now you decide to change language?
I start to think that you want to annoy me

lethal tulip
#

@magic viper I would like to ask for your help. For some reason, every time I turn on my printer, my Pi Camera v1.3 stops working, as shown in the picture I sent. It was working fine before. Could you please help me with this?

magic viper
#

Stop pinging me!

#

What's so hard

#

This is a ping @lethal tulip

#

This is a ping too @lethal tulip

#

Don't do this

lethal tulip
magic viper
#

For some reason, every time I turn on my printer, my Pi Camera v1.3 stops working, as shown in the picture I sent
What do you mean? You mean it's just not working right?
Turning on your printer has nothing to do with it has it? It's just about not working?

#

If so send a screenshot of your webcam settings

lethal tulip
#

I mean it's normal every time I turn on a camera printer on mansail, immediately work well for some reason. Now I don't work

magic viper
#

Still hard to understand. You just meant to say, in the past it worked and now it doesn't?

lethal tulip
magic viper
#

I still want the camera settings

lethal tulip
#

I connected the printer and the Raspberry Pi adapter to the same power outlet, so when I turn on the printer, both the Raspberry Pi and the printer power on at the same time — that’s what I meant.

#

This is my monraker.cfg configuration. I can also turn the printer on and off through the Mainsail UI.

magic viper
#

Set log_level: debug and delete_log: true in your crowsnest.conf and send a new log

lethal tulip
#

I followed the guide at https://crowsnest.mainsail.xyz/faq/how-to-setup-a-raspicam
and tried running
libcamera-hello --list-cameras but the result was:
pi@blissful umbraos:~ $ libcamera-hello --list-cameras
No cameras available!
I also noticed there was no detected 'libcamera' device like /base/soc/i2c0mux/i2c@1/ov5647@36@,
but instead it only detects a 'raspicam' device at /dev/video0

magic viper
#

I don't care about that

#

I didn't ask for that

lethal tulip
magic viper
magic viper
# lethal tulip

Reboot your pi and try send again a log after like a minute

lethal tulip
#

well I will reebot Pi and send log back to you

magic viper
#

also noticed there was no detected 'libcamera' device like /base/soc/i2c0mux/i2c@1/ov5647@36@, but instead it only detects a 'raspicam' device at /dev/video0
btw read through the stuff you do and try to understand it.
It tells you exactly that

lethal tulip
#

When I turn on the printer, the camera does not work like before. Previously, I did not turn on the printer for 1 week. Yesterday, I turned it back on, but the camera is not functioning. I have tried restarting Crowsnest, but the Pi camera sometimes works and sometimes doesn't. I have also updated Crowsnest and other things on Mainsail. I just started experiencing this problem.

#

Previously, every time I turned on the printer, the camera worked immediately. How can I make the camera work immediately every time I turn on the printer in the Mainsail UI like before, without having to click restart on Crowsnest and Moonraker?

#

The camera works after I click restart on Crowsnest, but before it used to work immediately.

#

This is the newest log after I click on Restart Crowsnest

#

If I reboot the Pi host, the camera doesn’t work again unless I click restart on Crowsnest.

#

What should I fix so that the camera works normally like before, without having to click restart on Crowsnest in the Mainsail UI every time I turn on the printer to make the camera function?

#

@magic viper I have also tried uninstalling Crowsnest and reinstalling it, but the result is the same. Can you help me?

magic viper
#

I'm doing this in my free time. Just wait until you get a response

lethal tulip
lethal tulip
magic viper
lethal tulip
magic viper
lethal tulip
#

now I have changed it to delete_log: true. I will try to reboot pi then I will send the log again

magic viper
#

What about debug_log?

#

Did you just ignore that part?

lethal tulip
magic viper
#

And why?

#

Read and follow everything

#

I don't want to repeat myself over and over again

lethal tulip
#

I am not ignoring your suggestion to set log_level: debug and delete_log: true. I have already changed it, but I still have to refresh to get the latest time in Crowsnest.log.

magic viper
#

I haven't changed it
You basically wrote that you did not change it....

lethal tulip
#

I haven't changed it

magic viper
#

And again, you wrote that you did not change it. But you changed it, as it seems

#

No idea, what you want to say with that screenshot

lethal tulip
#

I just rebooted the Pi, but the time on the log stays the same if I don't refresh.

magic viper
#

then you should refresh?

lethal tulip
#

After I refresh

magic viper
#

And now you send it

lethal tulip
magic viper
#

I don't know why you told me that it doesn't change without refreshing, instead of just refreshing it

#

Something is blocking port 8080

lethal tulip
#

What causes port 8080 to be blocked? I have an EnderSW with Mainsail OS as well, and the camera works normally. After powering on, the camera immediately functions, unlike this printer which started having issues about a week ago.

magic viper
#

I cannot tell on my own what is blocking it

#

It's just after a reboot?

#

So clicking on restart makes it work?

lethal tulip
#

I’m also confused. I didn’t change anything. I just didn’t use the printer for one week, then updated Klipper, Crowsnest, etc., because the camera wasn’t working.

lethal tulip
lethal tulip
#

after I rebbot

#

After clicking Click Restart the Crowsnest Camera Work

#

Do you need the moonraker.log and mainsail.log files as well?

#

What I find strange is that when I switch to camera-streamer mode, after rebooting or powering off and on the Pi, the camera works normally. I hardly ever change the crowsnest.conf, only the resolution part. When I first installed MainsailOS, I changed the resolution from 640x480 to 1280x720. Using camera-streamer mode causes the camera to have some delay, and I have tried WebRTC but it didn’t work. So at that time, I decided to use the default settings, which are ustreamer and adaptive-MJPEG-Streamer.

#

I tried restoring the crowsnest.conf settings to default by only changing the mode to camera-streamer. Then I rebooted, and the camera worked immediately without needing to click restart on Crowsnest. I also tried turning the power off and on, and after the printer turned on, the camera worked normally like it did a week ago. But the problem is, when I use camera-streamer mode, the camera experiences delay. Do you have any suggestions?

magic viper
lethal tulip
#

Is it in the log_level set: Debug and Delete_log: True or returned to the defaul like now?

magic viper
lethal tulip
magic viper
magic viper
#

We are still debugging

lethal tulip
lethal tulip
#

I do not understand configuration config.txt whether there is something to change because with camera-camera-streamer I can't use webrtc

#

Is there anything that needs to be changed in /boot/config.txt so that when using ustreamer mode, the camera works normally after every reboot or when turning on the printer, without having to click restart on Crowsnest?

magic viper
#

Send me a picture of the camera PCB

lethal tulip
magic viper
magic viper
lethal tulip
magic viper
#

Ok that's a fake

lethal tulip
#

I don't know whether this is the original Pi Cam or not

magic viper
#

Try to edit ~/printer_data/systemd/crowsnest.env and add -s. So the file content should look like this, after you have edit it:
CROWSNEST_ARGS="-c /home/pi/printer_data/config/crowsnest.conf -s"

magic viper
lethal tulip
#

As I recall, I once tried webrtc but I couldn't then try libcamera-hello--list-camera through the ssh device id appeared but now it was not detected

magic viper
#

Just don't bother about that part

lethal tulip
magic viper
magic viper
lethal tulip
#

How do I edit ~/printer_data/SystemD/Crowsnest.env and add K -S whether using WINSCP?

magic viper
#

You can use winscp, but keep in mind. DO NOT CAPITALIZE IT

#

Like I said, just use Google

#

E.g. "how to edit a file on linux"

#

or use a chatbot

lethal tulip
#

well I'll try it

#

Well, I'll try it.
On the other Ender SW, I'm using the same Pi camera, a 3B+, and a Raspberry Pi running MainsailOS 1.3.2. I once tried using WebRTC, but it didn’t work, so I ended up using adaptive-MJPEG-Streamer.

magic viper
#

Open a different post for separate problems. Just to keep it separated that no one gets confused

lethal tulip
#

If the camera is quite problematic using the MAINSAILOS version 1.2.1

#

Sorry if my English sounds strange — I’m using a translator.

magic viper
#

What is your native language if I may ask?

lethal tulip
#

Is the step like this
nano ~/printer_data/systemd/crowsnest.env

Crowsnest_args =

Crowsnest_args = " -C /Home/MRYEL/PRINTER_DATA/CONFIG/CrowSNEST.CONF -S"

magic viper
#

I might recommend to use a chatbot for translation or try out deepl. Whatever you are using, it's pretty weird

magic viper
#

And no, the mryel is wrong ofc

#

Just add the -s at the end, before the closing "

lethal tulip
#

"I'm not familiar with Linux. I use a plugin for translation."

magic viper
#

That plugin does not seem to be that good....

#

I'm not familiar with Linux
That's why I said to use a chatbot

#

E.g. ChatGPT or Gemini

lethal tulip
#

"I'm confused about how to access and edit ~/printer_data/systemd/crowsnest.env and add -s

magic viper
#

You can actually run this command:

echo 'CROWSNEST_ARGS="-c /home/pi/printer_data/config/crowsnest.conf -s"' > ~/printer_data/systemd/crowsnest.env
```DO NOT TRANSLATE THAT CODE BLOCK
#

Just copy and paste the original text

magic viper
lethal tulip
magic viper
#

Yes and then just reboot

lethal tulip
#

Is this correct?

magic viper
#

send the output of cat ~/printer_data/systemd/crowsnest.env

lethal tulip
magic viper
#

perfect

#

Now reboot and see if it works

lethal tulip
#

I have restored crowsnest.conf to ustreamer mode and then rebooted.

#

Before I rebooted, I changed the mode to ustreamer in crowsnest.conf. After rebooting, the camera did not work.

magic viper
#

That thing that I added should exactly help with that. But we can just increase it.

lethal tulip
magic viper
#

Then try thissh echo 'CROWSNEST_ARGS="-c /home/pi/printer_data/config/crowsnest.conf -s 15"' > ~/printer_data/systemd/crowsnest.env

lethal tulip
#

I have already changed it.

magic viper
#

Then try reboot

#

It might take longer for crowsnest to start now

lethal tulip
#

Now it works, although it takes a few seconds to start. Does the previous command function to set the initial restart time of Crowsnest when the printer reboots or is turned on?

#

I have tried rebooting, turning off the power, and turning it back on, and it works. Thank you very much.

#

If someday I want to revert to default, do I just need to remove -s and 15 like this:
echo 'CROWSNEST_ARGS="-c /home/pi/printer_data/config/crowsnest.conf "' > ~/printer_data/systemd/crowsnest.env?

magic viper
lethal tulip
#

Thank you very much, it is now working well. I tried
echo 'CROWSNEST_ARGS="-c /home/pi/printer_data/config/crowsnest.conf -s 10"' > ~/printer_data/systemd/crowsnest.env
and it works well.

magic viper
#

Yes that's the issue, why I initially added it

#

But that one was actually correlated to the so called SpeederPad

lethal tulip
#

I saw your old post, so I tried changing to -s 10 and it worked very well. Once again, thank you for taking the time to help someone inexperienced like me. I really appreciate it. Thank you.

magic viper
#

The -s 10 was just an example. You can put whatever you want there. It's just the amounts of seconds it's delayed. 10 for 10 seconds. 15 for 15 seconds. No number is equal to -s 5

magic viper
lethal tulip
#

Where is the delete section?

magic viper
#

Click on the three dots and select close

#

That's why I wrote close and not delete

#

The sixth point on my end

lethal tulip
#

Is this what you meant? Sorry, it’s my first time posting on the support forum.

lethal tulip
magic viper
#

yes, that says close post. Like I wrote before

lethal tulip
#

Ok, thank you