Hello. I'm trying to install the Repetier firmware on the Einsy Rambo board. I have solved the problem with the LCD. Now I'm trying to set up a current of motors that is controlled digitally. There is a very low current flowing into the motors. I set the current value via SPI. When I set 1800mA, the current in the motor is 210mA. I used the example code for the TMC2130 drivers to check the pins. In the example, the current in the motor was good. Can you please advise how to solve the problem?
This is my TMC2130 configuration.h:
// TRINAMIC
#define DRV_TMC2130
// M914 X<sg_value> Y<sg_value> Z<sg_value> Stall detection sensitivity for Trinamic stepper drivers.
//
// M915 X<0/1> Y<0/1> Z<0/1> Turn StealthChop mode ON or OFF on Trinamic stepper drivers.
// Uncomment if you use the stall guard for homing. Only for cartesian printers and xy direction
//#define SENSORLESS_HOMING
// The drivers with set CS pin will be used, all others are normal step/dir/enable drivers
#define TMC2130_X_CS_PIN 41
#define TMC2130_Y_CS_PIN 39
#define TMC2130_Z_CS_PIN 67
#define TMC2130_EXT0_CS_PIN 66
#define TMC2130_EXT1_CS_PIN -1
#define TMC2130_EXT2_CS_PIN -1
// Per-axis current setting in mA { X, Y, Z, E0, E1, E2}
#define MOTOR_CURRENT { 1800,1800,1000,1000,1000,1000 }
/ Global settings - these apply to all configured drivers
Per-axis values will override these
/
#define TMC2130_STEALTHCHOP 1 // Enable extremely quiet stepping
#define TMC2130_INTERPOLATE_256 1 // Enable internal driver microstep interpolation
#define TMC2130_STALLGUARD 0 // Sensorless homing sensitivity (between -63 and +64)
/** PWM values for chopper tuning
only change if you know what you're doing
*/
#define TMC2130_PWM_AMPL 255
#define TMC2130_PWM_GRAD 1
#define TMC2130_PWM_AUTOSCALE 1
#define TMC2130_PWM_FREQ 2
/ Per-axis parameters
To define different values for certain parameters on each axis,
append either _X, _Y, _Z, _EXT0, _EXT1 or _EXT2
to the name of the global parameter.
Examples for the X axis:
#define TMC2130_STEALTHCHOP_X 1
#define TMC2130_INTERPOLATE_256_X true
/
/** Minimum speeds for stall detection.
These values may need to be adjusted if SENSORLESS_HOMING is enabled,
but endstops trigger prematurely or don't trigger at all.
The exact value is dependent on the duration of one microstep,
but good approximations can be determined by experimentation.
*/
#define TMC2130_TCOOLTHRS_X 300
#define TMC2130_TCOOLTHRS_Y 300
#define TMC2130_TCOOLTHRS_Z 300
This is my pins.h:
//Einsy rambo
#if MOTHERBOARD == 310
#define KNOWN_BOARD
/**************************************************************
* RAMBo Pin Assignments
******************************************************************/
#ifndef AVR_ATmega2560
#error Oops! Make sure you have 'Arduino Mega 2560' selected from the 'Tools -> Boards' menu.
#endif
//#define TMC2130_X_CS_PIN 41 //PG0
//#define TMC2130_Y_CS_PIN 39 //PG2
//#define TMC2130_Z_CS_PIN 67 //PK5 A13 67
//#define TMC2130_EXT0_CS_PIN 66 //PK4 A12 66
//#define STEPPER_CURRENT_CONTROL CURRENT_CONTROL_MANUAL
#define ORIG_X_STEP_PIN 37
// PC0
#define ORIG_X_DIR_PIN 48
// PL0
#define ORIG_X_MIN_PIN 12
// 12 PB6
#define ORIG_X_MAX_PIN 24
// 24 NC
#define ORIG_X_ENABLE_PIN 29
//
#define X_MS1_PIN -1
#define X_MS2_PIN -1
#define ORIG_Y_STEP_PIN 36
// PC1
#define ORIG_Y_DIR_PIN 49
// PL1
#define ORIG_Y_MIN_PIN 11
// 11 PB6
#define ORIG_Y_MAX_PIN 23
// 23 NC
#define ORIG_Y_ENABLE_PIN 28
// PA6
#define Y_MS1_PIN -1
#define Y_MS2_PIN -1
#define ORIG_Z_STEP_PIN 35
// PC2
#define ORIG_Z_DIR_PIN 47
// PL2
#define ORIG_Z_MIN_PIN 10
// 10
#define ORIG_Z_MAX_PIN 30
// 30
#define ORIG_Z_ENABLE_PIN 27
// PA5
#define Z_MS1_PIN -1
#define Z_MS2_PIN -1
#define HEATER_0_PIN 3
#define TEMP_0_PIN 0
#define HEATER_1_PIN 4
// This is T2 on the board!
#define TEMP_1_PIN 2
#define HEATER_2_PIN 4
// This is T1 on the board!
#define TEMP_2_PIN 1
// T3 on board
#define TEMP_3_PIN 7
#define ORIG_E0_STEP_PIN 34 // PC3
#define ORIG_E0_DIR_PIN 43 // PL6
#define ORIG_E0_ENABLE_PIN 26 // PA4
#define E0_MS1_PIN -1
#define E0_MS2_PIN -1
#define ORIG_E1_STEP_PIN -1
#define ORIG_E1_DIR_PIN -1
#define ORIG_E1_ENABLE_PIN -1
#define E1_MS1_PIN -1
#define E1_MS2_PIN -1
//#define DIGIPOTSS_PIN 38
//#define DIGIPOT_CHANNELS {4,5,3,0,1} // X Y Z E0 E1 digipot channels to stepper driver mapping
#define SDPOWER -1
#define SDSS 77
#define LED_PIN 13
#define ORIG_FAN_PIN 8
#define ORIG_FAN2_PIN 6
#define ORIG_FAN3_PIN 2
#define ORIG_PS_ON_PIN 4
#define SUICIDE_PIN -1 //PIN that has to be turned on right after start, to keep power flowing.
#define E0_PINS ORIG_E0_STEP_PIN,ORIG_E0_DIR_PIN,ORIG_E0_ENABLE_PIN,E0_MS1_PIN,E0_MS2_PIN,
#define E1_PINS
#define SCK_PIN 52
#define MISO_PIN 50
#define MOSI_PIN 51
//#define MAX6675_SS 53
//#define STEPPER_CURRENT_CONTROL CURRENT_CONTROL_DIGIPOT
//#ifndef STEPPER_CURRENT_CONTROL
//#define STEPPER_CURRENT_CONTROL CURRENT_CONTROL_TMC2130
//#endif
#endif