moggieuk / ERCF-Software-V3

New software driver for ERCF control under Klipper
GNU General Public License v3.0
296 stars 63 forks source link

Syncronized Gear Stepper with TMC2209 gear stepper and TMC2240 toolhead valid? #67

Closed Surion79 closed 1 year ago

Surion79 commented 1 year ago

I have a mellow fly ercf can board with tmc2209 and a toolhead (SB2240 of BTT) with a TMC2240. Does this combination works? the TMC2209 have UART configured, while the TMC2240 is via SPI connected. Are those two different things working with the new feature? When i look in the logs I see TMC driver not found for extruder, cannot use current increase for tip forming move

thisiscam commented 1 year ago

AFAIK, the syncing feature should work. Maybe you could try it and report back? Try to enable the sync feature, and without loading any filament do: ERCF_SYNC_GEAR_MOTOR sync=1 servo=1. Then extrude under your web UI, see if the gear moves at all?

The message TMC driver not found for extruder, cannot use current increase for tip forming move is a different error on changing the current during tip forming moves. It seems like ERCF doesn't support tmc2240 for some reason: https://github.com/moggieuk/ERCF-Software-V3/blob/6afa9929800aa645f5958d7f0240d17b0c94b86e/extras/ercf.py#L539 . @moggieuk any ideas?

moggieuk commented 1 year ago

I may have just left tmc2240 out of the list (I don't have any controllers other than 2209's to test so I did this from the Klipper doc).. I will add. Note the error message is only for the ability to reduce current on tooltip move, it will not effect the synchronized gear/extruder movement.

One slight concern. Klipper doc says: SET_TMC_CURRENT SET_TMC_CURRENT STEPPER= CURRENT= HOLDCURRENT=: This will adjust the run and hold currents of the TMC driver. HOLDCURRENT is not applicable to tmc2660 drivers. When used on a driver which has the globalscaler field (tmc5160 and tmc2240), if StealthChop2 is used, the stepper must be held at standstill for >130ms so that the driver executes the AT#1 calibration.

I don't ensure a delay of >130ms before changing current... I cannot test this...

moggieuk commented 1 year ago

Ok. tmc2240 support is pushed. Caveat about possible issue highlighted in previous comment. Open a new issue if you have problems.

Surion79 commented 1 year ago

I am currently waiting for a replacement board. then i can test this and report back to you :)