@TDK said in How to run gcode commands remotely on a Duet3 + RPi?:
Running sudo /opt/dsf/bin/CodeConsole from the console seems to work.
they've started moving away from running as root so wasn't sure if that applied to CodeConsole or not.
you can also pipe commands for a one off echo M114 | sudo /opt/dsf/bin/CodeConsole
(edit: you could also run the whole thing securely over ssh from another host as single command ssh pi@printer_ip "echo M114 | sudo /opt/dsf/bin/CodeConsole" (use with public key in authorized_keys (ssh-keygen and ssh-copy-id pi@printer_ip) and specify ssh -t or set up sudo on the remote host to not require password for the command in question))