TMCStepper
|
#include <TMCStepper.h>
Public Member Functions | |
TMC2160Stepper (uint16_t pinCS, float RS=default_RS, int8_t link_index=-1) | |
TMC2160Stepper (uint16_t pinCS, uint16_t pinMOSI, uint16_t pinMISO, uint16_t pinSCK, int8_t link_index=-1) | |
TMC2160Stepper (uint16_t pinCS, float RS, uint16_t pinMOSI, uint16_t pinMISO, uint16_t pinSCK, int8_t link_index=-1) | |
void | begin () |
void | defaults () |
void | push () |
uint16_t | cs2rms (uint8_t CS) |
void | rms_current (uint16_t mA) |
void | rms_current (uint16_t mA, float mult) |
uint16_t | rms_current () |
uint32_t | IOIN () |
bool | refl_step () |
bool | refr_dir () |
bool | encb_dcen_cfg4 () |
bool | enca_dcin_cfg5 () |
bool | drv_enn () |
bool | dco_cfg6 () |
uint8_t | version () |
void | SHORT_CONF (uint32_t) |
void | s2vs_level (uint8_t) |
void | s2g_level (uint8_t) |
void | shortfilter (uint8_t) |
void | shortdelay (bool) |
uint32_t | SHORT_CONF () |
uint8_t | s2vs_level () |
uint8_t | s2g_level () |
uint8_t | shortfilter () |
bool | shortdelay () |
void | DRV_CONF (uint32_t) |
void | bbmtime (uint8_t) |
void | bbmclks (uint8_t) |
void | otselect (uint8_t) |
void | drvstrength (uint8_t) |
void | filt_isense (uint8_t) |
uint32_t | DRV_CONF () |
uint8_t | bbmtime () |
uint8_t | bbmclks () |
uint8_t | otselect () |
uint8_t | drvstrength () |
uint8_t | filt_isense () |
void | GLOBAL_SCALER (uint8_t) |
uint8_t | GLOBAL_SCALER () |
uint16_t | OFFSET_READ () |
void | PWMCONF (uint32_t input) |
void | pwm_ofs (uint8_t B) |
void | pwm_grad (uint8_t B) |
void | pwm_freq (uint8_t B) |
void | pwm_autoscale (bool B) |
void | pwm_autograd (bool B) |
void | freewheel (uint8_t B) |
void | pwm_reg (uint8_t B) |
void | pwm_lim (uint8_t B) |
uint32_t | PWMCONF () |
uint8_t | pwm_ofs () |
uint8_t | pwm_grad () |
uint8_t | pwm_freq () |
bool | pwm_autoscale () |
bool | pwm_autograd () |
uint8_t | freewheel () |
uint8_t | pwm_reg () |
uint8_t | pwm_lim () |
uint32_t | PWM_SCALE () |
uint8_t | pwm_scale_sum () |
uint16_t | pwm_scale_auto () |
Public Member Functions inherited from TMC2130Stepper | |
TMC2130Stepper (uint16_t pinCS, float RS=default_RS, int8_t link_index=-1) | |
TMC2130Stepper (uint16_t pinCS, uint16_t pinMOSI, uint16_t pinMISO, uint16_t pinSCK, int8_t link_index=-1) | |
TMC2130Stepper (uint16_t pinCS, float RS, uint16_t pinMOSI, uint16_t pinMISO, uint16_t pinSCK, int8_t link_index=-1) | |
void | begin () |
void | defaults () |
void | setSPISpeed (uint32_t speed) |
void | switchCSpin (bool state) |
bool | isEnabled () |
void | push () |
void | sg_current_decrease (uint8_t value) |
uint8_t | sg_current_decrease () |
uint32_t | GCONF () |
void | GCONF (uint32_t value) |
void | I_scale_analog (bool B) |
void | internal_Rsense (bool B) |
void | en_pwm_mode (bool B) |
void | enc_commutation (bool B) |
void | shaft (bool B) |
void | diag0_error (bool B) |
void | diag0_otpw (bool B) |
void | diag0_stall (bool B) |
void | diag1_stall (bool B) |
void | diag1_index (bool B) |
void | diag1_onstate (bool B) |
void | diag1_steps_skipped (bool B) |
void | diag0_int_pushpull (bool B) |
void | diag1_pushpull (bool B) |
void | small_hysteresis (bool B) |
void | stop_enable (bool B) |
void | direct_mode (bool B) |
bool | I_scale_analog () |
bool | internal_Rsense () |
bool | en_pwm_mode () |
bool | enc_commutation () |
bool | shaft () |
bool | diag0_error () |
bool | diag0_otpw () |
bool | diag0_stall () |
bool | diag1_stall () |
bool | diag1_index () |
bool | diag1_onstate () |
bool | diag1_steps_skipped () |
bool | diag0_int_pushpull () |
bool | diag1_pushpull () |
bool | small_hysteresis () |
bool | stop_enable () |
bool | direct_mode () |
uint32_t | IOIN () |
bool | step () |
bool | dir () |
bool | dcen_cfg4 () |
bool | dcin_cfg5 () |
bool | drv_enn_cfg6 () |
bool | dco () |
uint8_t | version () |
uint32_t | TCOOLTHRS () |
void | TCOOLTHRS (uint32_t input) |
uint32_t | THIGH () |
void | THIGH (uint32_t input) |
uint32_t | XDIRECT () |
void | XDIRECT (uint32_t input) |
void | coil_A (int16_t B) |
void | coil_B (int16_t B) |
int16_t | coil_A () |
int16_t | coil_B () |
uint32_t | VDCMIN () |
void | VDCMIN (uint32_t input) |
uint32_t | CHOPCONF () |
void | CHOPCONF (uint32_t value) |
void | toff (uint8_t B) |
void | hstrt (uint8_t B) |
void | hend (uint8_t B) |
void | disfdcc (bool B) |
void | rndtf (bool B) |
void | chm (bool B) |
void | tbl (uint8_t B) |
void | vsense (bool B) |
void | vhighfs (bool B) |
void | vhighchm (bool B) |
void | sync (uint8_t B) |
void | mres (uint8_t B) |
void | intpol (bool B) |
void | dedge (bool B) |
void | diss2g (bool B) |
uint8_t | toff () |
uint8_t | hstrt () |
uint8_t | hend () |
bool | disfdcc () |
bool | rndtf () |
bool | chm () |
uint8_t | tbl () |
bool | vsense () |
bool | vhighfs () |
bool | vhighchm () |
uint8_t | sync () |
uint8_t | mres () |
bool | intpol () |
bool | dedge () |
bool | diss2g () |
void | COOLCONF (uint32_t value) |
uint32_t | COOLCONF () |
void | semin (uint8_t B) |
void | seup (uint8_t B) |
void | semax (uint8_t B) |
void | sedn (uint8_t B) |
void | seimin (bool B) |
void | sgt (int8_t B) |
void | sfilt (bool B) |
uint8_t | semin () |
uint8_t | seup () |
uint8_t | semax () |
uint8_t | sedn () |
bool | seimin () |
int8_t | sgt () |
bool | sfilt () |
void | DCCTRL (uint32_t input) |
void | dc_time (uint16_t input) |
void | dc_sg (uint8_t input) |
uint32_t | DCCTRL () |
uint16_t | dc_time () |
uint8_t | dc_sg () |
uint32_t | DRV_STATUS () |
uint16_t | sg_result () |
bool | fsactive () |
uint8_t | cs_actual () |
bool | stallguard () |
bool | ot () |
bool | otpw () |
bool | s2ga () |
bool | s2gb () |
bool | ola () |
bool | olb () |
bool | stst () |
void | PWMCONF (uint32_t value) |
uint32_t | PWMCONF () |
void | pwm_ampl (uint8_t B) |
void | pwm_grad (uint8_t B) |
void | pwm_freq (uint8_t B) |
void | pwm_autoscale (bool B) |
void | pwm_symmetric (bool B) |
void | freewheel (uint8_t B) |
uint8_t | pwm_ampl () |
uint8_t | pwm_grad () |
uint8_t | pwm_freq () |
bool | pwm_autoscale () |
bool | pwm_symmetric () |
uint8_t | freewheel () |
uint8_t | PWM_SCALE () |
uint8_t | ENCM_CTRL () |
void | ENCM_CTRL (uint8_t input) |
void | inv (bool B) |
void | maxspeed (bool B) |
bool | inv () |
bool | maxspeed () |
uint32_t | LOST_STEPS () |
Public Member Functions inherited from TMCStepper | |
uint16_t | cs2rms (uint8_t CS) |
void | rms_current (uint16_t mA) |
void | rms_current (uint16_t mA, float mult) |
uint16_t | rms_current () |
void | hold_multiplier (float val) |
float | hold_multiplier () |
uint8_t | test_connection () |
void | microsteps (uint16_t ms) |
uint16_t | microsteps () |
void | blank_time (uint8_t value) |
uint8_t | blank_time () |
void | hysteresis_end (int8_t value) |
int8_t | hysteresis_end () |
void | hysteresis_start (uint8_t value) |
uint8_t | hysteresis_start () |
void | GSTAT (uint8_t input) |
uint8_t | GSTAT () |
bool | reset () |
bool | drv_err () |
bool | uv_cp () |
void | IHOLD_IRUN (uint32_t input) |
uint32_t | IHOLD_IRUN () |
void | ihold (uint8_t B) |
void | irun (uint8_t B) |
void | iholddelay (uint8_t B) |
uint8_t | ihold () |
uint8_t | irun () |
uint8_t | iholddelay () |
uint8_t | TPOWERDOWN () |
void | TPOWERDOWN (uint8_t input) |
uint32_t | TSTEP () |
uint32_t | TPWMTHRS () |
void | TPWMTHRS (uint32_t input) |
uint16_t | MSCNT () |
uint32_t | MSCURACT () |
int16_t | cur_a () |
int16_t | cur_b () |
Protected Member Functions | |
INIT_REGISTER (SHORT_CONF) | |
INIT_REGISTER (DRV_CONF) | |
INIT_REGISTER (GLOBAL_SCALER) | |
INIT2160_REGISTER (PWMCONF) | |
uint8_t | ENCM_CTRL () |
void | ENCM_CTRL (uint8_t input) |
void | pwm_ampl (uint8_t B) |
uint8_t | pwm_ampl () |
void | pwm_symmetric (bool B) |
bool | pwm_symmetric () |
Protected Member Functions inherited from TMC2130Stepper | |
void | write (uint8_t addressByte, uint32_t config) |
uint32_t | read (uint8_t addressByte) |
INIT_REGISTER (GCONF) | |
INIT_REGISTER (TCOOLTHRS) | |
INIT_REGISTER (THIGH) | |
INIT_REGISTER (XDIRECT) | |
INIT_REGISTER (VDCMIN) | |
INIT_REGISTER (CHOPCONF) | |
INIT_REGISTER (COOLCONF) | |
INIT_REGISTER (DCCTRL) | |
INIT_REGISTER (PWMCONF) | |
INIT_REGISTER (ENCM_CTRL) | |
Protected Member Functions inherited from TMCStepper | |
TMCStepper (float RS) | |
INIT_REGISTER (IHOLD_IRUN) | |
INIT_REGISTER (TPOWERDOWN) | |
INIT_REGISTER (TPWMTHRS) | |
Static Protected Attributes | |
static constexpr float | default_RS = 0.075 |
Static Protected Attributes inherited from TMC2130Stepper | |
static uint32_t | spi_speed = 16000000/8 |
static constexpr float | default_RS = 0.11 |
static int8_t | chain_length = 0 |
Static Protected Attributes inherited from TMCStepper | |
static constexpr uint8_t | TMC_READ = 0x00 |
static constexpr uint8_t | TMC_WRITE = 0x80 |
Additional Inherited Members | |
Public Attributes inherited from TMC2130Stepper | |
uint8_t | status_response |
Protected Attributes inherited from TMC2130Stepper | |
const uint16_t | _pinCS |
SW_SPIClass * | TMC_SW_SPI = nullptr |
int8_t | link_index |
Protected Attributes inherited from TMCStepper | |
const float | Rsense |
float | holdMultiplier = 0.5 |
Definition at line 360 of file TMCStepper.h.
TMC2160Stepper::TMC2160Stepper | ( | uint16_t | pinCS, |
float | RS = default_RS , |
||
int8_t | link_index = -1 |
||
) |
TMC2160Stepper::TMC2160Stepper | ( | uint16_t | pinCS, |
uint16_t | pinMOSI, | ||
uint16_t | pinMISO, | ||
uint16_t | pinSCK, | ||
int8_t | link_index = -1 |
||
) |
TMC2160Stepper::TMC2160Stepper | ( | uint16_t | pinCS, |
float | RS, | ||
uint16_t | pinMOSI, | ||
uint16_t | pinMISO, | ||
uint16_t | pinSCK, | ||
int8_t | link_index = -1 |
||
) |
uint8_t TMC2160Stepper::bbmclks | ( | ) |
void TMC2160Stepper::bbmclks | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::bbmtime | ( | ) |
void TMC2160Stepper::bbmtime | ( | uint8_t | B | ) |
void TMC2160Stepper::begin | ( | ) |
Definition at line 13 of file TMC2160Stepper.cpp.
uint16_t TMC2160Stepper::cs2rms | ( | uint8_t | CS | ) |
Definition at line 99 of file TMC2160Stepper.cpp.
bool TMC2160Stepper::dco_cfg6 | ( | ) |
void TMC2160Stepper::defaults | ( | ) |
uint32_t TMC2160Stepper::DRV_CONF | ( | ) |
void TMC2160Stepper::DRV_CONF | ( | uint32_t | input | ) |
bool TMC2160Stepper::drv_enn | ( | ) |
uint8_t TMC2160Stepper::drvstrength | ( | ) |
void TMC2160Stepper::drvstrength | ( | uint8_t | B | ) |
bool TMC2160Stepper::enca_dcin_cfg5 | ( | ) |
bool TMC2160Stepper::encb_dcen_cfg4 | ( | ) |
|
protected |
Definition at line 302 of file TMC2130Stepper.cpp.
|
protected |
Definition at line 303 of file TMC2130Stepper.cpp.
uint8_t TMC2160Stepper::filt_isense | ( | ) |
void TMC2160Stepper::filt_isense | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::freewheel | ( | ) |
Definition at line 50 of file PWMCONF.cpp.
void TMC2160Stepper::freewheel | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::GLOBAL_SCALER | ( | ) |
void TMC2160Stepper::GLOBAL_SCALER | ( | uint8_t | input | ) |
|
inlineprotected |
Definition at line 454 of file TMCStepper.h.
|
inlineprotected |
Definition at line 452 of file TMCStepper.h.
|
inlineprotected |
Definition at line 453 of file TMCStepper.h.
|
inlineprotected |
Definition at line 451 of file TMCStepper.h.
uint32_t TMC2160Stepper::IOIN | ( | ) |
Definition at line 133 of file TMC2160Stepper.cpp.
uint16_t TMC2160Stepper::OFFSET_READ | ( | ) |
uint8_t TMC2160Stepper::otselect | ( | ) |
void TMC2160Stepper::otselect | ( | uint8_t | B | ) |
void TMC2160Stepper::push | ( | ) |
|
protected |
Definition at line 21 of file PWMCONF.cpp.
|
protected |
Definition at line 14 of file PWMCONF.cpp.
bool TMC2160Stepper::pwm_autograd | ( | ) |
Definition at line 49 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_autograd | ( | bool | B | ) |
bool TMC2160Stepper::pwm_autoscale | ( | ) |
Definition at line 48 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_autoscale | ( | bool | B | ) |
uint8_t TMC2160Stepper::pwm_freq | ( | ) |
Definition at line 47 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_freq | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::pwm_grad | ( | ) |
Definition at line 46 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_grad | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::pwm_lim | ( | ) |
Definition at line 52 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_lim | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::pwm_ofs | ( | ) |
Definition at line 45 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_ofs | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::pwm_reg | ( | ) |
Definition at line 51 of file PWMCONF.cpp.
void TMC2160Stepper::pwm_reg | ( | uint8_t | B | ) |
uint32_t TMC2160Stepper::PWM_SCALE | ( | ) |
Definition at line 155 of file TMC2160Stepper.cpp.
uint16_t TMC2160Stepper::pwm_scale_auto | ( | ) |
uint8_t TMC2160Stepper::pwm_scale_sum | ( | ) |
|
protected |
Definition at line 25 of file PWMCONF.cpp.
|
protected |
Definition at line 18 of file PWMCONF.cpp.
uint32_t TMC2160Stepper::PWMCONF | ( | ) |
void TMC2160Stepper::PWMCONF | ( | uint32_t | input | ) |
bool TMC2160Stepper::refl_step | ( | ) |
bool TMC2160Stepper::refr_dir | ( | ) |
uint16_t TMC2160Stepper::rms_current | ( | ) |
Definition at line 111 of file TMC2160Stepper.cpp.
void TMC2160Stepper::rms_current | ( | uint16_t | mA | ) |
void TMC2160Stepper::rms_current | ( | uint16_t | mA, |
float | mult | ||
) |
uint8_t TMC2160Stepper::s2g_level | ( | ) |
void TMC2160Stepper::s2g_level | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::s2vs_level | ( | ) |
void TMC2160Stepper::s2vs_level | ( | uint8_t | B | ) |
uint32_t TMC2160Stepper::SHORT_CONF | ( | ) |
void TMC2160Stepper::SHORT_CONF | ( | uint32_t | input | ) |
bool TMC2160Stepper::shortdelay | ( | ) |
void TMC2160Stepper::shortdelay | ( | bool | B | ) |
uint8_t TMC2160Stepper::shortfilter | ( | ) |
void TMC2160Stepper::shortfilter | ( | uint8_t | B | ) |
uint8_t TMC2160Stepper::version | ( | ) |
|
staticconstexprprotected |
Definition at line 456 of file TMCStepper.h.