Manta MP8 v2 shutdown: i2c timeout

thank you for participating in this too)

Where should I indicate the connection pins?
You don’t need Eddy USB. For Eddy coil you need specify pins

Nowhere. The corresponding pins are bound to the bus. See klipper/src/stm32/i2c.c at 87ac69363aecd51c282999f8bf0f5c3513f58ed2 · Klipper3d/klipper · GitHub

i2c_bus: i2c1 #_PB6_PB7 # I2C bus actually connected to Eddy Coil

**mcu sb2240** (stm32g0b1xx)

Version: v0.11.0-479-g95747542

Load: 0.01, Awake: 0.00, Freq: 64 MHz, Temp: 32°C

maybe the firmware version is not suitable?

Interesting. Color me surprised.

For these mcu, the i2c bus definitions do indeed include the pin assignments in the enumeration string. So i2c_bus: i2c1_PB6_PB7 is ‘correct’.

  DECL_ENUMERATION("i2c_bus", "i2c1_PB6_PB7", 0);
  DECL_ENUMERATION("i2c_bus", "i2c1_PB8_PB9", 1);
  DECL_ENUMERATION("i2c_bus", "i2c1_PA9_PA10", 2);
  DECL_ENUMERATION("i2c_bus", "i2c2_PB10_PB11", 3);
  DECL_ENUMERATION("i2c_bus", "i2c2_PB13_PB14", 4);
  #ifdef I2C3
    DECL_ENUMERATION("i2c_bus", "i2c3_PB3_PB4", 5);
    DECL_ENUMERATION("i2c_bus", "i2c3_PC0_PC1", 6);
  #endif

You should match the firmware version of the mcu to the version of your Klippy install.

10k pullups to 3v3 for the SDA / SCL should be ‘ok’, even if there are programmable pullups from the mcu in use also. Are you sure you’ve got the SDA / SCL wired to the correct points on the Eddy Coil.
They’re not interchangeable signals, they need to be connected SDA to SDA and SCL to SCL…

I don’t know what to think anymore! I’ve run out of options to solve the problem(((
I’m looking at this diagram of the pull-up resistor and I see that on the other side there is a resistor 1k and a capacitor to GND
maybe that’s the problem???

since you and I are out of ideas
I’m moving to plan B. I’ll connect to BLTouch Connector P9
pins: PB8,PB9

No. They should be fine - I wouldn’t have suggested them if I thought the 1k and cap were issues. I might ask you to pull the caps, but I want to see what the I2C waveforms look like first.

Can we go back to what I last asked you for?

  1. Give me an accurate state of where things are now and what you’ve done. I think you’re using PB6/PB7, as I suggested but have added additional resistors to the wiring. It might be helpful to provide a drawing/photograph to show exactly what the state of things are.
  2. When you do a new experiment, show the oscilloscope view of the waveforms. That is really helpful to understanding what is happening as well as getting an idea whether or not there’s a chance that things will work.
  3. Stop posting abbreviated/edited klipyy.log files. I would really like to see the complete file. If you think it is too large (although you should be able to .zip it and post it here), then do a Reset on the Mainsail “Machine” page and then post the new file after you’ve run a new test.

You seem to have indicated that you just have PB6/PB7 wired. I would still like a picture of what you have done and how things are wired.

You indicated that there is a problem with getting 'scope pictures of the data. With the soldering/desoldering (I was expecting that you would only use plug in connectors) I think it’s really critical to see what’s going on the lines. I don’t understand why you are unable to get a shot of what’s going on the line.

I’m looking at your latest klippy.log and the most recent error indicates that you are not getting a response from the I2C. This means that I would really like to see physically what you have (ie pictures) done and electrically ('scope images).

If I can make an observation, you are thrashing. I know what I’m asking for is pedantic but I think it’s important we work through things step by step and not get ahead and change things without fully understanding what’s going on currently or completely responding to my requests.

We’ll get there. There’s a reason for everything I’m asking you to do so please follow my instructions and requests before doing anything else.

I don’t mind questions, just be patient because I’m not sitting at the computer waiting for you to come back with information or requests.

ok, I won’t move on to plan B for now. )))

  1. this is what my connection looks like now. !!!no resistors to the wiring!!!



nothing happens on the oscilloscope! !!!voltage 3.36v!!!

until the bus transmission starts! but the transmission does not start, a Klipper error appears

klippy (8).zip (4.0 MB)

Okay, this is helpful.

Let’s work through this until we see the SDA/SCL lines wiggling.

It looks like to me that there is a software issue in how the pins are specified - my first thought is that the I2C pins on the EBB SB2240 are not being set up correctly.

@nefelim4ag I think you’re the expert here - do you see anything wrong with how @borysne has specified the Eddy Coil interface. The printer.cfg statement (taken from the klippy.log) is:

[probe_eddy_current btt_eddy]
sensor_type = ldc1612
z_offset = 1
i2c_mcu = sb2240
i2c_bus = i2c1_PB6_PB7
x_offset = 0
y_offset = 20
data_rate = 500
calibrate = 
	0.050000:3207699.594,0.100000:3207141.189,0.150000:3206564.339,
	0.200000:3205998.528,0.250000:3205421.329,0.300000:3204883.073,
	0.350000:3204292.184,0.400000:3203773.146,0.450000:3203294.481,
	0.500000:3202757.730,0.550000:3202274.951,0.600000:3201774.550,
	0.650000:3201297.859,0.700000:3200833.363,0.750000:3200338.938,
	0.800000:3199845.502,0.850000:3199407.159,0.900000:3198946.967,
	0.950000:3198530.107,1.000000:3198082.834,1.050000:3197664.912,
	1.100000:3197276.036,1.150000:3196856.075,1.200000:3196451.244,
	1.250000:3196078.298,1.300000:3195679.907,1.350000:3195317.339,
	1.400000:3194942.274,1.450000:3194586.297,1.500000:3194228.212,
	1.550000:3193862.701,1.600000:3193531.575,1.650000:3193212.875,
	1.700000:3192868.353,1.750000:3192565.119,1.800000:3192225.248,
	1.850000:3191914.767,1.900000:3191612.717,1.950000:3191313.087,
	2.000000:3190989.028,2.050000:3190716.184,2.100000:3190420.831,
	2.150000:3190181.490,2.200000:3189895.656,2.250000:3189617.857,
	2.300000:3189364.023,2.350000:3189101.713,2.400000:3188853.082,
	2.450000:3188591.115,2.500000:3188374.243,2.550000:3188117.857,
	2.600000:3187888.238,2.650000:3187649.940,2.700000:3187435.040,
	2.750000:3187194.958,2.800000:3186970.903,2.850000:3186768.375,
	2.900000:3186547.824,2.950000:3186341.320,3.000000:3186143.320,
	3.050000:3185920.156,3.100000:3185734.683,3.150000:3185529.662,
	3.200000:3185330.516,3.250000:3185135.867,3.300000:3184957.732,
	3.350000:3184787.230,3.400000:3184617.410,3.450000:3184430.081,
	3.500000:3184274.324,3.550000:3184080.004,3.600000:3183911.964,
	3.650000:3183775.656,3.700000:3183615.235,3.750000:3183438.456,
	3.800000:3183266.390,3.850000:3183143.953,3.900000:3182988.757,
	3.950000:3182845.322,4.000000:3182721.499,4.050000:3182564.965
reg_drive_current = 15
calibration_temp = 0.000000

Things look right sb2240 is the CAN device and PB6/PB7 are I2C1 in the STM32G0B1. I can confirm that in the klippy.log on the connection statement:

MCU 'sb2240' config: ADC_MAX=4095 BUS_PINS_i2c1_PA9_PA10=PA9,PA10 BUS_PINS_i2c1_PB6_PB7=PB6,PB7...

The only thing I can think of is that the PB6/PB7 being accessed are on the Manta M8P V2.0 but that should be specified by the i2c_mcu parameter - correct?

is this a question for me? or @nefelim4ag

if the question is for me, then I think that everything is correct in the config! we indicate which MCU we are addressing
i2c_mcu = sb2240
i2c_bus = i2c1_PB6_PB7

when I was connected directly to the Manta MP8 v2. board via a long cable, the config was like this:
i2c_mcu: mcu
i2c_bus: i2c3_PA8_PC9

It’s strange where this calibration comes from if I’ve never managed to launch Eddy in a new pin configuration
This is probably an old calibration when the connection was via directly Manta mp8

[probe_eddy_current btt_eddy]
sensor_type = ldc1612
z_offset = 1
i2c_mcu = sb2240
i2c_bus = i2c1_PB6_PB7
x_offset = 0
y_offset = 20
data_rate = 500
calibrate =
0.050000:3207699.594,0.100000:3207141.189,0.150000:3206564.339,
0.200000:3205998.528,0.250000:3205421.329,0.300000:3204883.073,
0.350000:3204292.184,0.400000:3203773.146,0.450000:3203294.481,
0.500000:3202757.730,0.550000:3202274.951,0.600000:3201774.550,
0.650000:3201297.859,0.700000:3200833.363,0.750000:3200338.938,
0.800000:3199845.502,0.850000:3199407.159,0.900000:3198946.967,
0.950000:3198530.107,1.000000:3198082.834,1.050000:3197664.912,
1.100000:3197276.036,1.150000:3196856.075,1.200000:3196451.244,
1.250000:3196078.298,1.300000:3195679.907,1.350000:3195317.339,
1.400000:3194942.274,1.450000:3194586.297,1.500000:3194228.212,
1.550000:3193862.701,1.600000:3193531.575,1.650000:3193212.875,
1.700000:3192868.353,1.750000:3192565.119,1.800000:3192225.248,
1.850000:3191914.767,1.900000:3191612.717,1.950000:3191313.087,
2.000000:3190989.028,2.050000:3190716.184,2.100000:3190420.831,
2.150000:3190181.490,2.200000:3189895.656,2.250000:3189617.857,
2.300000:3189364.023,2.350000:3189101.713,2.400000:3188853.082,
2.450000:3188591.115,2.500000:3188374.243,2.550000:3188117.857,
2.600000:3187888.238,2.650000:3187649.940,2.700000:3187435.040,
2.750000:3187194.958,2.800000:3186970.903,2.850000:3186768.375,
2.900000:3186547.824,2.950000:3186341.320,3.000000:3186143.320,
3.050000:3185920.156,3.100000:3185734.683,3.150000:3185529.662,
3.200000:3185330.516,3.250000:3185135.867,3.300000:3184957.732,
3.350000:3184787.230,3.400000:3184617.410,3.450000:3184430.081,
3.500000:3184274.324,3.550000:3184080.004,3.600000:3183911.964,
3.650000:3183775.656,3.700000:3183615.235,3.750000:3183438.456,
3.800000:3183266.390,3.850000:3183143.953,3.900000:3182988.757,
3.950000:3182845.322,4.000000:3182721.499,4.050000:3182564.965
reg_drive_current = 15
calibration_temp = 0.000000

The question was for @nefelim4ag

Anyway, I didn’t realize that wasn’t the original printer.cfg statement.

Could you try the basic one you used with the Manta M8P?

connect Eddie back to Manta mp8?
to check if Eddy works after everything we did to him)

No, the same printer.cfg statement you had with the Manta M8P V2 but with specify the sb2240 and i2c1_PB6_PB7.

so what do we do!?
connect eddy to manta as before?
what bus ports to specify?

I connected everything as it was before, Eddy directly to the Manta
config:

i2c_mcu: mcu
i2c_bus: i2c3_PA8_PC9

I turned on the test PROBE_ACCURACY and everything works!!!

probe accuracy results: maximum 0.699613, minimum 0.692887, range 0.006725, average 0.696340, median 0.696603, standard deviation 0.002284

So everything is fine with Eddy! I’m connecting everything back according to our plan!
using PB6/PB7 on SB2240

i2c_mcu: sb2240 # MCU name of the actual board connected to Eddy Coil
i2c_bus: i2c1_PB6_PB7 # I2C bus actually connected to Eddy Coil

And so this config doesn’t work

What do you mean, “this config doesn’t work”? Are you scoping the lines?

Could you please share your printer.cfg with me?

I was asking that you continue with the the SB2240 but use your original configuration information that was in the Manta M8P V2 but didn’t have the “calibration” information.

Please be as descriptive as possible and include as much information as possible, even if it seems redundant.

continue with the the SB2240

  1. I use original configuration that was in the Manta M8P V2 when i connected to eddy directly
  2. the “calibration” information - I can go in printer.cfg and try to delete it!
    but then after deleting the sensor i need to calibrate it! and I won’t be able to do it because we have problems with i2c