Unable to write tmc spi 'stepper_x' register GLOBALSCALER

Basic Information:

Printer Model: Custom
MCU / Printerboard: Duet 3d 6hc
klippy.log (816.2 KB)

The printer was working fine, and suddenly it began displaying this error message. There doesn’t appear to be any damage to the board. I’m unable to connect any of the 6 motor drivers. I haven’t made any changes to the code, and I’ve checked my motor connections. Even when I attempt to connect the driver without the motors attached, it displays ‘DRV_STATUS: 00000000’ for every driver. Apart from this issue, the board appears to be functioning normally.

Thanks in advance

https://klipper.discourse.group/search?q=GLOBALSCALER%20order%3Alatest

Hi, thank you for your response, however that doesn’t really help me.

You only have four motors defined in your config. How do you drive 6 then?
Did you maybe updated Klipper or other parts?

DaisyChaining drivers should be avoided.
And one of the search results is a bad board even if the Duet hardware is quite robust.
How did you connect the TMC5160 drivers physically?
Can you break the DaisyChain and directly access the drivers or at least swap first and last driver and then perform a TMC dumb and upload the results here?

1 Like

I was going to add 5th and 6th steppers eventually. But still tried them out to see if they were working and they don’t.

I did update klipper but in the hope of that might solve the problem after the fact.

The drivers as soldiered in the board by the manufacturer.

I couldn’t break the DaisyChainnot sure how to. But here is a TMC dumb nonetheless.

TSTEP: 00000009 tstep=9
PWM_AUTO: 00000009 pwm_ofs_auto=9
PWM_SCALE: 00000009 pwm_scale_sum=9
OTP_READ: 00000009 otp_fclktrim=9
MSCURACT: 00000009 cur_a=9
MSCNT: 00000009 mscnt=9
LOST_STEPS: 00000009 lost_steps=9
IOIN: 00000009 refl_step=1 enca_dcin_cfg5=1 version=0x0
FACTORY_CONF: 00000009 factory_conf=9
DRV_STATUS: 00000009 sg_result=9
GSTAT: 00000009 reset=1(Reset)
CHOPCONF: 00000009 toff=9 mres=0(256usteps)
GCONF: 00000009 recalibrate=1 multistep_filt=1
========== Queried registers ==========
TPOWERDOWN: 0000000a tpowerdown=10
PWMCONF: c40c001e pwm_ofs=30 pwm_autoscale=1 pwm_autograd=1 pwm_reg=4 pwm_lim=12
DRV_CONF: 00000400 bbmclks=4
COOLCONF: 00000000
TPWMTHRS: 000fffff tpwmthrs=1048575
MSLUTSTART: 00f70000 start_sin90=247
MSLUTSEL: ffff8056 w0=2 w1=1 w2=1 w3=1 x1=128 x2=255 x3=255
MSLUT7: 00404222 mslut7=4211234
MSLUT6: 49295556 mslut6=1227445590
MSLUT5: b5bb777d mslut5=3048961917
MSLUT4: fbffffff mslut4=4227858431
MSLUT3: 10104222 mslut3=269500962
MSLUT2: 24492929 mslut2=608774441
MSLUT1: 4a9554aa mslut1=1251300522
MSLUT0: aaaab554 mslut0=2863314260
IHOLD_IRUN: 00061b1b ihold=27 irun=27 iholddelay=6
GLOBALSCALER: 00000020 globalscaler=32
========== Write-only registers ==========

Did you check all your supply voltages? GitHub - Duet3D/Duet3-Mainboard-6HC: Hardware information for the Duet 3 Mainboard 6HC. Which version are you using? There are also LEDs on board indicating the presence of those voltages. I guess, something blew. Does the board smell “funny”?

Good luck, hcet14

Git version: 'v0.11.0-303-g67499853'

Please update to latest git. v303 is buggy, but I’d be not aware that it causes the mentioned error here.

I am using the V1.02. All LED are active as before and the supply voltages are 24V.

Well, I would measure the 24V. If ok, I would follow with Sineos hint regarding v303.

Measured the 24V. Also updated. Still the same issue.

I noticed the following things:

[tmc5160 stepper_x]
cs_pin = PD17
spi_bus = usart1
chain_position = 1
chain_length = 6
interpolate = False
run_current = 1
sense_resistor = 0.05

You have 4 chain positions, but you setup the length to 6.

I assume BUS_PINS_usart1=PA21,PB4,PA23 is still correct.
cs_pin is set to PD17. That belongs to BUS_PINS_usart2=PD15,PD16,PD17

Does that fit?

Yeah, i was just about to add more steppers, that’s when it stopped working.

I also did try to change the cd_pin
image

I did manage to use the cs_pin=PA21 with spi_bus = uart2. Though it didn’t solve the original problem

1 Like

I would try this config https://github.com/Klipper3d/klipper/blob/master/config/generic-duet3-6hc.cfg

I did use that one :smiley:

Could you post a fresh klippy.log?

Hi, i had this problem on a faulty board where the power supply on the driver ramp only was dead so the board could not communicate with the TMC drivers. Everything worked fine but everytime i tried to make any movement i had this error and a klippy shutdown. I would recommend you to check directly on the driver’s pins that you have a correct voltage.

3 Likes

Good input @Aurescalia
Typically, (and as highlighted in many threads here) this type of error is due to some malfunctioning hardware or wrong hardware configuration, e.g. wrongly set jumpers on the printer board.

According to what Aurescalia posted. I have another question. Did you put a big load to the 24V power supply, when measuring?

So… It wasn’t a faulty board. I switched back to the original RepRapFirmware, and it worked just fine. Then switched back to Klipper got the same error.

So you installed the latest Klipper version, flashed the MCU with the firmware built from that latest version?
When exactly does this error happen?
Do you use (special) macros?