paukstelis / octoprint_deploy

Bash script for rapid deployment of multiple octoprint instance on a single machine
MIT License
390 stars 39 forks source link

Problem connecting to Ender 3 printers #108

Closed joelstitch closed 11 months ago

joelstitch commented 11 months ago

So After a ton of hours wasted trying to get this to work I decided to once again start from scratch.

  1. Installed raspbian.
  2. ssh into the pi, update, install git, install octoprint_deploy.
  3. run octoprint_deploy
  4. Prepare the system
  5. Add Instance
  6. open instance web address.
  7. make sure its showing the right Serial Port
  8. Click Connect.
  9. get error State: Offline after error No more candidates to test, and no working port/baudrate combination detected.

Please help me understand what I'm doing wrong so I can get this to work.why does it detects the printer when adding the instance but refuses to connect on Octoprint?

joelstitch commented 11 months ago

octoprint_deploy diagnostic information. Please provide ALL output for support h elp


/etc/octoprint_deploy


haproxy: true streamer: ustreamer octoexec: /home/pi/OctoPrint/bin/octoprint octopip: /home/pi/OctoPrint/bin/pip


/etc/octoprint_instances


instance:ender3 port:5000 udev:true instance:ender3pro port:5001 udev:true cat: /etc/octoprint_cameras** /etc/octoprint_cameras


: No such file or directory


/etc/udev/rules.d/99-octoprint.rules


KERNELS=="1-1.5:1.0",SUBSYSTEM=="tty",SYMLINK+="octo_ender3" KERNELS=="1-1.4:1.0",SUBSYSTEM=="tty",SYMLINK+="octo_ender3pro" lrwxrwxrwx 1 root root 7 Jul 23 16:54 /dev/octo_ender3 -> ttyUSB0 ls: cannot access '/dev/cam*': No such file or directory


● ender3.service - The snappy web interface for your 3D printer Loaded: loaded (/etc/systemd/system/ender3.service; enabled; vendor preset: enabled) Active: active (running) since Sun 2023-07-23 16:54:41 CDT; 23min ago Main PID: 386 (octoprint) Tasks: 22 (limit: 1595) CPU: 1min 8.516s CGroup: /system.slice/ender3.service └─386 /home/pi/OctoPrint/bin/python3 /home/pi/OctoPrint/bin/octopri nt serve --config=/home/pi/.ender3/config.yaml --basedir=/home/pi/.ender3 --port =5000

Jul 23 17:15:34 raspberrypi octoprint[386]: 2023-07-23 17:15:34,099 - octoprint. plugins.action_command_notification - INFO - Notifications cleared Jul 23 17:15:39 raspberrypi octoprint[386]: 2023-07-23 17:15:38,984 - octoprint. util.comm - INFO - Changing monitoring state from "Offline" to "Opening serial c onnection" Jul 23 17:15:39 raspberrypi octoprint[386]: 2023-07-23 17:15:38,993 - octoprint. util.comm - INFO - Connecting to port /dev/ttyUSB0, baudrate 115200 Jul 23 17:15:39 raspberrypi octoprint[386]: 2023-07-23 17:15:39,029 - octoprint. util.comm - INFO - Changing monitoring state from "Opening serial connection" to "Connecting" Jul 23 17:15:39 raspberrypi octoprint[386]: 2023-07-23 17:15:39,042 - octoprint. util.comm - INFO - M110 detected, setting current line number to 0 Jul 23 17:15:39 raspberrypi octoprint[386]: 2023-07-23 17:15:39,196 - octoprint. server - INFO - Autorefresh of serial port list stopped Jul 23 17:16:23 raspberrypi octoprint[386]: 2023-07-23 17:16:23,534 - octoprint. util.comm - INFO - M110 detected, setting current line number to 0 Jul 23 17:16:38 raspberrypi octoprint[386]: 2023-07-23 17:16:38,542 - octoprint. util.comm - INFO - Changing monitoring state from "Connecting" to "Offline" Jul 23 17:16:38 raspberrypi octoprint[386]: 2023-07-23 17:16:38,564 - octoprint. server - INFO - Starting autorefresh of serial port list Jul 23 17:16:38 raspberrypi octoprint[386]: 2023-07-23 17:16:38,573 - octoprint. plugins.action_command_notification - INFO - Notifications cleared None None {'bitrate': '10000k', 'cleanTmpAfterDays': 7, 'defaultWebcam': 'classic', 'ffmpeg': None, 'ffmpegCommandline': '{ffmpeg} -framerate {fps} -i "{input}" -vcodec ' '{videocodec} -threads {threads} -b:v {bitrate} -f ' '{containerformat} -y {filters} "{output}"', 'ffmpegThreads': 1, 'ffmpegThumbnailCommandline': '{ffmpeg} -sseof -1 -i "{input}" -update 1 -q:v ' '0.7 "{output}"', 'ffmpegVideoCodec': 'libx264', 'snapshotWebcam': 'classic', 'timelapse': {'fps': 25, 'options': {'capturePostRoll': None, 'interval': None, 'retractionZHop': None}, 'postRoll': 0, 'type': 'off'}, 'timelapseEnabled': True, 'watermark': True, 'webcamEnabled': True}


● ender3pro.service - The snappy web interface for your 3D printer Loaded: loaded (/etc/systemd/system/ender3pro.service; enabled; vendor pres et: enabled) Active: active (running) since Sun 2023-07-23 16:54:41 CDT; 24min ago Main PID: 387 (octoprint) Tasks: 19 (limit: 1595) CPU: 54.053s CGroup: /system.slice/ender3pro.service └─387 /home/pi/OctoPrint/bin/python3 /home/pi/OctoPrint/bin/octopri nt serve --config=/home/pi/.ender3pro/config.yaml --basedir=/home/pi/.ender3pro --port=5001

Jul 23 16:55:10 raspberrypi octoprint[387]: 2023-07-23 16:55:10,979 - octoprint. plugins.tracking - INFO - Sent tracking event startup, payload: {'version': '1.9 .2', 'os': 'linux', 'bits': 32, 'python': '3.9.2', 'pip': '23.2.1', 'cores': 4, 'freq': 1200.0, 'ram': 966750208, 'pi_model': 'Raspberry Pi 3 Model B Rev 1.2'} Jul 23 17:11:41 raspberrypi octoprint[387]: 2023-07-23 17:11:41,773 - octoprint. server.heartbeat - INFO - Server heartbeat <3 Jul 23 17:11:42 raspberrypi octoprint[387]: 2023-07-23 17:11:42,537 - octoprint. plugins.tracking - INFO - Sent tracking event ping, payload: {'octoprint_uptime' : 16, 'printer_state': 'OFFLINE'} Jul 23 17:11:43 raspberrypi octoprint[387]: 2023-07-23 17:11:43,929 - octoprint. server.util.sockjs - INFO - User admin logged in on the socket from client 192.1 68.69.4 Jul 23 17:12:00 raspberrypi octoprint[387]: 2023-07-23 17:12:00,057 - octoprint. server.preemptive_cache - INFO - ... done in 20.23s Jul 23 17:14:04 raspberrypi octoprint[387]: 2023-07-23 17:14:04,695 - octoprint. server.util.sockjs - INFO - Client connection closed: 192.168.69.4 Jul 23 17:14:09 raspberrypi octoprint[387]: 2023-07-23 17:14:09,858 - octoprint. server.util.sockjs - INFO - New connection from client: 192.168.69.4 Jul 23 17:14:10 raspberrypi octoprint[387]: 2023-07-23 17:14:10,042 - octoprint. server.util.flask - INFO - Passively logging in user admin from 192.168.69.4 Jul 23 17:14:10 raspberrypi octoprint[387]: 2023-07-23 17:14:10,043 - octoprint. access.users - INFO - Logged in user: admin Jul 23 17:14:10 raspberrypi octoprint[387]: 2023-07-23 17:14:10,111 - octoprint. server.util.sockjs - INFO - User admin logged in on the socket from client 192.1 68.69.4 None None {'bitrate': '10000k', 'cleanTmpAfterDays': 7, 'defaultWebcam': 'classic', 'ffmpeg': None, 'ffmpegCommandline': '{ffmpeg} -framerate {fps} -i "{input}" -vcodec ' '{videocodec} -threads {threads} -b:v {bitrate} -f ' '{containerformat} -y {filters} "{output}"', 'ffmpegThreads': 1, 'ffmpegThumbnailCommandline': '{ffmpeg} -sseof -1 -i "{input}" -update 1 -q:v ' '0.7 "{output}"', 'ffmpegVideoCodec': 'libx264', 'snapshotWebcam': 'classic', 'timelapse': {'fps': 25, 'options': {'capturePostRoll': None, 'interval': None, 'retractionZHop': None}, 'postRoll': 0, 'type': 'off'}, 'timelapseEnabled': True, 'watermark': True, 'webcamEnabled': True} cat: /etc/octoprint_cameras: No such file or directory


● haproxy.service - HAProxy Load Balancer Loaded: loaded (/lib/systemd/system/haproxy.service; enabled; vendor preset: enabled) Active: active (running) since Sun 2023-07-23 16:54:49 CDT; 24min ago Docs: man:haproxy(1) file:/usr/share/doc/haproxy/configuration.txt.gz Process: 647 ExecStartPre=/usr/sbin/haproxy -f $CONFIG -c -q $EXTRAOPTS (code=exited, status=0/SUCCESS) Main PID: 652 (haproxy) Tasks: 5 (limit: 1595) CPU: 459ms CGroup: /system.slice/haproxy.service ├─652 /usr/sbin/haproxy -Ws -f /etc/haproxy/haproxy.cfg -p /run/haproxy.pid -S /run/haproxy-master.sock └─654 /usr/sbin/haproxy -Ws -f /etc/haproxy/haproxy.cfg -p /run/haproxy.pid -S /run/haproxy-master.sock

Jul 23 16:54:49 raspberrypi systemd[1]: Starting HAProxy Load Balancer... Jul 23 16:54:49 raspberrypi haproxy[652]: [WARNING] 203/165449 (652) : parsing [/etc/haproxy/haproxy.cfg:38] : a 'http-request' rule placed after a 'use_backend' rule will still be processed before. Jul 23 16:54:49 raspberrypi haproxy[652]: [NOTICE] 203/165449 (652) : New worker #1 (654) forked Jul 23 16:54:49 raspberrypi systemd[1]: Started HAProxy Load Balancer.

paukstelis commented 11 months ago

Based on the previous issues you opened and this one I would say that you likely installed Klipper firmware on your printers. Once you do that, they will no longer connect to OctoPrint as normal USB devices. They now need to connect to OctoPrint through Klipper. Re-install Marlin firmware and you can see if it works.

The printers are still detected during the setup because what is actually being detected is the USB->UART chip.