Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

StallGuard can't seems to work while in TMCL-IDE the same config works #103

Open
jonnydman opened this issue Jun 20, 2022 · 1 comment
Open

Comments

@jonnydman
Copy link

jonnydman commented Jun 20, 2022

hi,

I have an ESP32 with SPI communication to TMC2130 (connected to their dev board).

I'm using the driver to run the motor, with FastAccelStepper for stepping abilities.
however, no matter what configuration I write, the following happens:

  1. when I try to read DRV_STATUS, the SG_Result is always 0.
  2. the StallGuard flag is always off.

it does however display the Actual CS correctly.

on the other, when I configure the same params at TMCL-IDE I have a dynamic value of SG_Result and the StallGuard flag detects the stall.

this is my setup:

        _driver.begin();
        _driver.shaft(1);
        _driver.microsteps(2);
        // setup from TMCL IDE
        _driver.ihold(3);
        _driver.irun(23);
        _driver.iholddelay(7);
        _driver.pwm_ampl(200);
        _driver.diag1_stall(1);
        _driver.diag1_active_high(1);
        _driver.coolstep_min_speed(300);
        _driver.stealthChop(false);
        _driver.semin(0);
        _driver.semax(0);
        _driver.sedn(0);
        _driver.tbl(2);
        _driver.hstrt(5);
        _driver.hend(3);
        _driver.toff(5);

do you have any ideas?

@jonnydman
Copy link
Author

oh man..
I just understood that DCEN_CFG4 leg must be tied to GND for not working with DcStep.

now I get SG_Result values

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant