#Turn off Crowsnest when idle

23 messages Β· Page 1 of 1 (latest)

placid gazelle
#

Is there a way for klipper to stop the crowsnest service?
Essentially I would like to turn off the webcamera once my printer turns off with action_call_remote_method.

round thicket
#

The only inofficial way, would be gcode_shell_command. With a sudo systemctl stop crowsnest. But I don't know if you can run sudo commands with it

#

That module can be installed with kiauh

placid gazelle
round thicket
#

Yes

midnight pawnBOT
#

Ahoi @placid gazelle!
It looks like you did not provide all the necessary information we need to help you.
Please upload your logfiles and a detailed description of your problem.
For further information see: https://docs.mainsail.xyz/faq/getting-help/discord#provide-information
Note: We only accept .log and .txt files as log files.
This is an automated message

We are glad to help and chat with you on our Community Discord, but if you need help and want the best support possible you should, follow a few simple rules:

placid gazelle
#

Hmm, could I write a service that periodically checks if a print is running?

#

Ahh, I forgot that #NoLogsNeeded...

round thicket
placid gazelle
#

I'll play with that. Figure there's no reason for it to run all the time.. And RPi currently idles at 70 degrees, goes down to 50/60 without camera.

round thicket
#

You would either to have connect to Moonraker or directly to Klipper. I'm not sure if the second one is easily possible.
The best thing for Moonraker should be python, as you need some networking capabilities, that might be a bit annoying with bash

#

And RPi currently idles at 70 degrees, goes down to 50/60 without camera.
Just add a fan ^^

round thicket
#

or at least a heatsink

placid gazelle
#

Tbf, maybe I should just wait for that rather than mess with more stuff πŸ˜›

#

Can't I just curl a moonraker endpoint for the print status?

round thicket
#

Might be possible πŸ€·β€β™‚οΈ

#

Never tried it

placid gazelle
#

curl -X GET localhost:7125/server/info

{"result": {"klippy_connected": true, "klippy_state": "ready", "components": ["secrets", "template", "klippy_connection", "jsonrpc", "internal_transport", "application", "websockets", "dbus_manager", "database", "file_manager", "authorization", "klippy_apis", "shell_command", "machine", "data_store", "proc_stats", "job_state", "job_queue", "http_client", "announcements", "webcam", "extensions", "history", "power", "octoprint_compat", "update_manager"], "failed_components": [], "registered_directories": ["config", "logs", "gcodes", "config_examples", "docs"], "warnings": [], "websocket_count": 3, "moonraker_version": "v0.8.0-320-g6b1b8c5", "missing_klippy_requirements": [], "api_version": [1, 4, 0], "api_version_string": "1.4.0"}}
#

Thinking I could probably check klippy_state right? πŸ˜„

round thicket
#

Should be correct, yes

placid gazelle
#

Yah, or if that is not enough, I could check print_stats, so seems possible πŸ˜„