CR Touch intermittently failing when connected to Octoprint

What is the problem?

I have printed on this base ender 3 (if it's important, its the 4.2.2 board) for almost a year now with very little issues, but for some reason now. the CR Touch is not working when connected to Octoprint and I have tried everything I know to do. When it fails I can disconnect the USB cable from the printer to the pi, power cycle, then run any bed leveling on the printer itself, but once I connect to Octoprint again it will work the initial time with the Bed Visualizer add on, but on the second time it will fail either immediately or in the middle of the leveling process. It seems like it can't communicate with the cr touch as sometimes it will momentarily mess up, then start working again and do a test in the middle of the mesh and then go back to working if it gets that far.

What did you already try to solve it?

I have tried with multiple different firmwares including a custom compiled one, and the issue still persists. I don't believe it is on the cr touch as it works when not connected to Octoprint but I am not 100% positive.

Have you tried running in safe mode?

yes

Did running in safe mode solve the problem?

no as I cannot run bed leveler in safe mode

Systeminfo Bundle

You can download this in OctoPrint's System Information dialog ... no bundle, no support!)

browser.user_agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36
connectivity.connection_check: 1.1.1.1:53
connectivity.connection_ok: True
connectivity.enabled: True
connectivity.online: True
connectivity.resolution_check: octoprint.org
connectivity.resolution_ok: True
env.hardware.cores: 4
env.hardware.freq: 1800.0
env.hardware.ram: 3970777088
env.os.bits: 32
env.os.id: linux
env.os.platform: linux
env.plugins.pi_support.model: Raspberry Pi 4 Model B Rev 1.5
env.plugins.pi_support.octopi_camera_stack: webcamd
env.plugins.pi_support.octopi_version: 1.0.0
env.plugins.pi_support.octopiuptodate_build: 1.0.0-1.9.3-20231009151442
env.plugins.pi_support.octopiuptodate_build_short: 2023.10.09.151442
env.plugins.pi_support.throttle_check_enabled: True
env.plugins.pi_support.throttle_check_functional: True
env.plugins.pi_support.throttle_state: 0x0
env.python.pip: 22.3
env.python.version: 3.9.2
env.python.virtualenv: True
octoprint.last_safe_mode.date: 2024-09-29T23:10:15Z
octoprint.last_safe_mode.reason: settings
octoprint.safe_mode: False
octoprint.version: 1.10.2
systeminfo.generated: 2024-09-29T23:14:12Z
systeminfo.generator: zipapi

Additional information about your setup

OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ... as much data as possible

Octoprint ver: 1.10.2
firmware : marlin bugfix 2.1, and Ender 3 -4.2.2 mainboard(32 bit) TESTED BOTH
motherboard: 4.2.2
Printer:Creality Ender 3 base
Bed Level Visualizer Ver: 1.1.1
Browser: Chrome

Terminal Read out:
Send: M140 S60
Recv: ok
Send: M117 Homing all axes
Recv: ok
Send: G28
Recv: T:21.03 /0.00 B:36.04 /60.00 @:0 B@:0
Recv: echo:busy: processing
Printer seems to support the busy protocol, will adjust timeouts and set busy interval accordingly
Recv: T:20.99 /0.00 B:36.03 /60.00 @:0 B@:0
Recv: T:21.05 /0.00 B:36.06 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.96 /0.00 B:36.42 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.94 /0.00 B:36.86 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:21.02 /0.00 B:37.34 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.95 /0.00 B:38.01 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.97 /0.00 B:38.65 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: echo:busy: processing
Recv: T:20.88 /0.00 B:40.86 /60.00 @:0 B@:127
Recv: T:20.88 /0.00 B:41.50 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.85 /0.00 B:42.27 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.87 /0.00 B:42.96 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.91 /0.00 B:43.68 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.89 /0.00 B:44.40 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.89 /0.00 B:45.12 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: T:20.97 /0.00 B:45.70 /60.00 @:0 B@:127
Recv: echo:busy: processing
Recv: X:160.00 Y:124.00 Z:5.00 E:0.00 Count X:12800 Y:9920 Z:2000
Recv: ok
Send: M420 S0
Recv: echo:Bed Leveling OFF
Recv: echo:Fade Height 10.00
Recv: ok
Send: M117 Heating the bed
Recv: ok
Send: M190 S60
Recv: T:20.87 /0.00 B:46.09 /60.00 @:0 B@:127 W:?
Recv: T:20.82 /0.00 B:46.38 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.94 /0.00 B:46.67 /60.00 @:0 B@:127 W:?
Recv: T:20.99 /0.00 B:46.97 /60.00 @:0 B@:127 W:?
Recv: T:20.91 /0.00 B:47.36 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.96 /0.00 B:47.55 /60.00 @:0 B@:127 W:?
Recv: T:20.94 /0.00 B:47.91 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.96 /0.00 B:48.18 /60.00 @:0 B@:127 W:?
Recv: T:20.86 /0.00 B:48.52 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.94 /0.00 B:48.78 /60.00 @:0 B@:127 W:?
Recv: T:20.94 /0.00 B:49.04 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.97 /0.00 B:49.31 /60.00 @:0 B@:127 W:?
Recv: T:21.06 /0.00 B:49.66 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.95 /0.00 B:49.90 /60.00 @:0 B@:127 W:?
Recv: T:20.87 /0.00 B:50.16 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.94 /0.00 B:50.39 /60.00 @:0 B@:127 W:?
Recv: T:20.91 /0.00 B:50.61 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.93 /0.00 B:50.87 /60.00 @:0 B@:127 W:?
Recv: T:20.91 /0.00 B:51.04 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.95 /0.00 B:51.29 /60.00 @:0 B@:127 W:?
Recv: T:20.90 /0.00 B:51.55 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.88 /0.00 B:51.76 /60.00 @:0 B@:127 W:?
Recv: T:20.90 /0.00 B:52.01 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.89 /0.00 B:52.13 /60.00 @:0 B@:127 W:?
Recv: T:20.92 /0.00 B:52.47 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.96 /0.00 B:52.65 /60.00 @:0 B@:127 W:?
Recv: T:20.88 /0.00 B:52.88 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.95 /0.00 B:53.09 /60.00 @:0 B@:127 W:?
Recv: T:20.97 /0.00 B:53.36 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.93 /0.00 B:53.54 /60.00 @:0 B@:127 W:?
Recv: T:21.04 /0.00 B:53.74 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.91 /0.00 B:53.93 /60.00 @:0 B@:127 W:?
Recv: T:21.00 /0.00 B:54.16 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.01 /0.00 B:54.35 /60.00 @:0 B@:127 W:?
Recv: T:21.00 /0.00 B:54.57 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.94 /0.00 B:54.75 /60.00 @:0 B@:127 W:?
Recv: T:21.02 /0.00 B:55.00 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.99 /0.00 B:55.17 /60.00 @:0 B@:127 W:?
Recv: T:20.95 /0.00 B:55.35 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:20.97 /0.00 B:55.54 /60.00 @:0 B@:127 W:?
Recv: T:21.00 /0.00 B:55.75 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.09 /0.00 B:55.85 /60.00 @:0 B@:127 W:?
Recv: T:20.99 /0.00 B:56.11 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.05 /0.00 B:56.28 /60.00 @:0 B@:127 W:?
Recv: T:21.05 /0.00 B:56.45 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.04 /0.00 B:56.59 /60.00 @:0 B@:127 W:?
Recv: T:20.98 /0.00 B:56.80 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.10 /0.00 B:56.98 /60.00 @:0 B@:127 W:?
Recv: T:21.08 /0.00 B:57.20 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.17 /0.00 B:57.34 /60.00 @:0 B@:127 W:?
Recv: T:21.05 /0.00 B:57.51 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.05 /0.00 B:57.65 /60.00 @:0 B@:127 W:?
Recv: T:21.09 /0.00 B:57.85 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.03 /0.00 B:58.02 /60.00 @:0 B@:127 W:?
Recv: T:21.05 /0.00 B:58.20 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.14 /0.00 B:58.38 /60.00 @:0 B@:127 W:?
Recv: T:21.10 /0.00 B:58.58 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.07 /0.00 B:58.74 /60.00 @:0 B@:127 W:?
Recv: T:21.18 /0.00 B:58.88 /60.00 @:0 B@:127 W:?
Recv: echo:busy: processing
Recv: T:21.13 /0.00 B:59.06 /60.00 @:0 B@:127 W:9
Recv: T:21.12 /0.00 B:59.27 /60.00 @:0 B@:127 W:8
Recv: echo:busy: processing
Recv: T:21.19 /0.00 B:59.40 /60.00 @:0 B@:127 W:7
Recv: T:21.17 /0.00 B:59.59 /60.00 @:0 B@:127 W:6
Recv: echo:busy: processing
Recv: T:21.11 /0.00 B:59.76 /60.00 @:0 B@:127 W:5
Recv: T:21.16 /0.00 B:59.92 /60.00 @:0 B@:127 W:4
Recv: echo:busy: processing
Recv: T:21.24 /0.00 B:60.10 /60.00 @:0 B@:127 W:3
Recv: T:21.17 /0.00 B:60.24 /60.00 @:0 B@:127 W:2
Recv: echo:busy: processing
Recv: T:21.19 /0.00 B:60.36 /60.00 @:0 B@:127 W:1
Recv: T:21.16 /0.00 B:60.54 /60.00 @:0 B@:127 W:0
Recv: echo:busy: processing
Recv: ok
Send: M300 S1000 P500
Recv: ok
Send: M117 Creating the bed mesh levels
Recv: ok
Send: M155 S30
Recv: ok
Send: G29 T
Recv: T:21.14 /120.00 B:60.61 /60.00 @:0 B@:127 W:?
Recv: T:21.23 /120.00 B:60.78 /60.00 @:127 B@:0 W:?
Recv: T:21.65 /120.00 B:60.82 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:22.88 /120.00 B:60.87 /60.00 @:127 B@:0 W:?
Recv: T:24.80 /120.00 B:60.82 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:26.80 /120.00 B:60.81 /60.00 @:127 B@:0 W:?
Recv: T:29.60 /120.00 B:60.73 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:32.13 /120.00 B:60.68 /60.00 @:127 B@:0 W:?
Recv: T:35.02 /120.00 B:60.56 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:37.59 /120.00 B:60.43 /60.00 @:127 B@:0 W:?
Recv: T:40.82 /120.00 B:60.23 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:43.52 /120.00 B:60.12 /60.00 @:127 B@:0 W:?
Recv: T:46.39 /120.00 B:60.00 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:49.20 /120.00 B:59.80 /60.00 @:127 B@:0 W:?
Recv: T:52.39 /120.00 B:59.60 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:55.15 /120.00 B:59.44 /60.00 @:127 B@:0 W:?
Recv: T:57.84 /120.00 B:59.23 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:60.56 /120.00 B:59.09 /60.00 @:127 B@:127 W:?
Recv: T:63.60 /120.00 B:59.01 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:66.18 /120.00 B:58.95 /60.00 @:127 B@:127 W:?
Recv: T:68.72 /120.00 B:58.96 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:71.28 /120.00 B:59.07 /60.00 @:127 B@:127 W:?
Recv: T:74.19 /120.00 B:59.05 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:76.60 /120.00 B:59.11 /60.00 @:127 B@:127 W:?
Recv: T:79.04 /120.00 B:59.23 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:81.39 /120.00 B:59.38 /60.00 @:127 B@:127 W:?
Recv: T:84.12 /120.00 B:59.49 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:86.37 /120.00 B:59.67 /60.00 @:127 B@:127 W:?
Recv: T:88.59 /120.00 B:59.80 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:90.79 /120.00 B:59.96 /60.00 @:127 B@:127 W:?
Recv: T:93.36 /120.00 B:60.14 /60.00 @:127 B@:127 W:?
Recv: echo:busy: processing
Recv: T:95.53 /120.00 B:60.33 /60.00 @:127 B@:127 W:?
Recv: T:97.68 /120.00 B:60.47 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:99.83 /120.00 B:60.59 /60.00 @:127 B@:0 W:?
Recv: T:102.23 /120.00 B:60.58 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:104.29 /120.00 B:60.59 /60.00 @:127 B@:0 W:?
Recv: T:106.34 /120.00 B:60.62 /60.00 @:127 B@:0 W:?
Recv: echo:busy: processing
Recv: T:108.37 /120.00 B:60.62 /60.00 @:127 B@:0 W:?
Recv: T:110.72 /120.00 B:60.53 /60.00 @:92 B@:0 W:?
Recv: echo:busy: processing
Recv: T:112.69 /120.00 B:60.45 /60.00 @:59 B@:0 W:?
Recv: T:114.46 /120.00 B:60.39 /60.00 @:34 B@:0 W:?
Recv: echo:busy: processing
Recv: T:115.91 /120.00 B:60.29 /60.00 @:17 B@:0 W:?
Recv: T:117.03 /120.00 B:60.19 /60.00 @:10 B@:0 W:?
Recv: echo:busy: processing
Recv: T:117.56 /120.00 B:60.07 /60.00 @:12 B@:0 W:?
Recv: T:117.76 /120.00 B:59.95 /60.00 @:19 B@:0 W:?
Recv: echo:busy: processing
Recv: T:117.71 /120.00 B:59.82 /60.00 @:30 B@:0 W:?
Recv: T:117.46 /120.00 B:59.64 /60.00 @:43 B@:0 W:?
Recv: echo:busy: processing
Recv: T:117.19 /120.00 B:59.53 /60.00 @:54 B@:127 W:?
Recv: T:116.98 /120.00 B:59.39 /60.00 @:62 B@:127 W:?
Recv: echo:busy: processing
Recv: T:116.85 /120.00 B:59.41 /60.00 @:68 B@:127 W:?
Recv: T:116.83 /120.00 B:59.45 /60.00 @:71 B@:127 W:?
Recv: echo:busy: processing
Recv: T:116.97 /120.00 B:59.45 /60.00 @:70 B@:127 W:?
Recv: T:117.22 /120.00 B:59.50 /60.00 @:67 B@:127 W:?
Recv: echo:busy: processing
Recv: T:117.52 /120.00 B:59.62 /60.00 @:64 B@:127 W:?
Recv: T:117.97 /120.00 B:59.74 /60.00 @:58 B@:127 W:?
Recv: echo:busy: processing
Recv: T:118.36 /120.00 B:59.91 /60.00 @:54 B@:127 W:?
Recv: T:118.70 /120.00 B:60.03 /60.00 @:50 B@:127 W:?
Recv: echo:busy: processing
Recv: T:118.99 /120.00 B:60.17 /60.00 @:48 B@:127 W:?
Recv: T:119.29 /120.00 B:60.32 /60.00 @:46 B@:0 W:9
Recv: echo:busy: processing
Recv: T:119.49 /120.00 B:60.34 /60.00 @:45 B@:0 W:8
Recv: T:119.63 /120.00 B:60.36 /60.00 @:45 B@:0 W:7
Recv: echo:busy: processing
Recv: T:119.72 /120.00 B:60.43 /60.00 @:45 B@:0 W:6
Recv: T:119.79 /120.00 B:60.41 /60.00 @:46 B@:0 W:5
Recv: echo:busy: processing
Recv: T:119.79 /120.00 B:60.40 /60.00 @:48 B@:0 W:4
Recv: T:119.83 /120.00 B:60.36 /60.00 @:49 B@:0 W:3
Recv: echo:busy: processing
Recv: T:119.84 /120.00 B:60.30 /60.00 @:49 B@:0 W:2
Recv: T:119.87 /120.00 B:60.21 /60.00 @:50 B@:0 W:1
Recv: echo:busy: processing
Recv: T:119.88 /120.00 B:60.12 /60.00 @:50 B@:0 W:0
Recv: echo:busy: processing
Recv: Error:!! STOP called because of BLTouch error - restart with M999
Changing monitoring state from "Operational" to "Error"
Send: M112
Send: N2 M11235
Send: N3 M104 T0 S0
34
Send: N4 M140 S0*97
Changing monitoring state from "Error" to "Offline after error"
Connection closed, closing down monitor
octoprint-systeminfo-20240929191412.zip (109.2 KB)

If you click on the link Systeminfo Bundle, it will show you haw to make one...
Other than that I am unsure how those commands are being sent to the print, as OctoPrint usually sends a line number with everything (like at the end after the M112).
You are using 'G29 T' so it must be either Linear or Unified Leveling? You could use a V4 and they get really verbose when running.

added system info bundle, and I thought I configured the firmware for bi-linear.

Doesn't use T and I don't know how it responds to it.

Okay that’s really interesting, I definitely have it on bi linear then because it does probe the specific points and make the mesh off that. So that may be the cause, any idea how I could have it swap from sending the “T” commands to the appropriate ones? And is this on octopi’s side or the printer side?

Go to the BedLevelVisializer setup page [Settings(the wranch)->Plugins(scroll the left pane down to find the plugin's setting page)] and there is a GCode section you can play with.

so did change the G29 T command and just sent a plain G29 code, and it still failed. so it is not that.

Try the 'G29 V4' to get verbose reporting. Turn on 'Serial logging' to record everything.
And post a new Systminfo zip.

octoprint-systeminfo-20240930190752.zip (100.3 KB)
here is the new system info bundle after a failed run with the serial logging enabled. unfortunately it seems like it failed before the g29 even kicked off.

here is one with V4 that did get past g28 code
octoprint-systeminfo-20240930203958.zip (66.6 KB)

Wow! Error on homing... It almost looks like you have a wiring problem.
I would turn it on and let the probe do the self test and then go in and jiggle all the head wires one at a time and see if anything trips.
If that doesn't do anything, home it and jiggle everything again.

So I’ve tried that, and I am starting to lean towards it being a wiring thing, a person on Reddit mentioned the connector on the mobo is weak on these 4.2.2 boards and that hot glue helped him.. I’m hesitant to try, but do you think that’s an idea? Lol

You can try... But it bothers me that there was stuff you had to do to use a CRTouch. I just don't remember. It's all so dependent on boards and versions. And you still say running without OctoPrint it works fine?

yes, now it will take a while for the printer to recognize it's fine after it messes up initially. but after 1 or 2 power cycles it is fine. or if you auto home it from the printer without octoprint attached then the printer will try and succeed. but I'm also considering just buying an additional cr touch for the wire, and seeing if that changes anything as well.

Well, if it works, give it the command to store the mesh to EEPROM and you can just recall it. It shouldn't vary a lot unless you pound on the bed a lot. Like "To save time and machine wear, save your mesh to EEPROM with [M500] and in your slicer’s “Starting G-code” replace G29 with M420 S1 to enable your last-saved mesh."
I haven't heard a lot of 'good' things about the CR Touch but you use what you got!

oh really? I haven't seen a lot of complaints with the CR Touch, though I have not looked deeply admittedly, you think I should switch to the BL?

No, just things like connectors, sloppy internals, sudden/random failures. I made a probe, got my bed flat and now only do the corners to make sure it's still aligned. Don't use the mesh (glass plate). Zero in with baby stepping on the first layer. Everyone goes thru the steps to get the machine set up and then you leave it alone. It really shouldn't change that much between prints.