Fixed a problem in which setting via SPI failed when the I2S I/O expander was used to control the CS pins of the TMC2130.
– Reduce SPI clock to 100KHz
– Moved the start of I2S out execution to just after setup().
Before fix:
“`
[MSG:Grbl_ESP32 Ver 1.2a Date 20200605]
[MSG:Compiled with ESP32 SDK:v3.2.3-14-gd3e562907]
[MSG:Using machine:ESP32 SPI 6 Axis Driver Board (Trinamic)]
[MSG:Axis count 6]
[MSG:I2S Steps]
[MSG:TMCStepper Init using Library Ver 0x000602]
[MSG:X Trinamic driver test failed. Check motor power]
[MSG:Y Trinamic driver test failed. Check connection]
[MSG:Z Trinamic driver test failed. Check connection]
[MSG:A Trinamic driver test passed]
[MSG:B Trinamic driver test passed]
[MSG:C Trinamic driver test passed]
[MSG:Init Motors]
[MSG:X Axis standard stepper motor Step:I2SO2 Dir:I2SO1 Disable:I2SO_0]
[MSG:Y Axis standard stepper motor Step:I2SO5 Dir:I2SO4 Disable:I2SO_7]
[MSG:Z Axis standard stepper motor Step:I2SO10 Dir:I2SO9 Disable:I2SO_8]
[MSG:A Axis standard stepper motor Step:I2SO13 Dir:I2SO12 Disable:I2SO_15]
[MSG:B Axis standard stepper motor Step:I2SO18 Dir:I2SO17 Disable:I2SO_16]
[MSG:C Axis standard stepper motor Step:I2SO21 Dir:I2SO20 Disable:I2SO_23]
[MSG:PWM spindle Output:GPIO26, Enbl:GPIO4, Dir:GPIO_16, Freq:5000Hz, Res:13bits]
[MSG:Local access point GRBL_ESP started, 192.168.0.1]
[MSG:Captive Portal Started]
[MSG:HTTP Started]
[MSG:TELNET Started 23]
Grbl 1.2a ['$' for help]
After fix:
`“
[MSG:Grbl_ESP32 Ver 1.2a Date 20200605]
[MSG:Compiled with ESP32 SDK:v3.2.3-14-gd3e562907]
[MSG:Using machine:ESP32 SPI 6 Axis Driver Board (Trinamic)]
[MSG:Axis count 6]
[MSG:I2S Steps]
[MSG:TMCStepper Init using Library Ver 0x000602]
[MSG:X Trinamic driver test passed]
[MSG:Y Trinamic driver test passed]
[MSG:Z Trinamic driver test passed]
[MSG:A Trinamic driver test passed]
[MSG:B Trinamic driver test passed]
[MSG:C Trinamic driver test passed]
[MSG:Init Motors]
[MSG:X Axis standard stepper motor Step:I2SO2 Dir:I2SO1 Disable:I2SO_0]
[MSG:Y Axis standard stepper motor Step:I2SO5 Dir:I2SO4 Disable:I2SO_7]
[MSG:Z Axis standard stepper motor Step:I2SO10 Dir:I2SO9 Disable:I2SO_8]
[MSG:A Axis standard stepper motor Step:I2SO13 Dir:I2SO12 Disable:I2SO_15]
[MSG:B Axis standard stepper motor Step:I2SO18 Dir:I2SO17 Disable:I2SO_16]
[MSG:C Axis standard stepper motor Step:I2SO21 Dir:I2SO20 Disable:I2SO_23]
[MSG:PWM spindle Output:GPIO26, Enbl:GPIO4, Dir:GPIO_16, Freq:5000Hz, Res:13bits]
[MSG:Local access point GRBL_ESP started, 192.168.0.1]
[MSG:Captive Portal Started]
[MSG:HTTP Started]
[MSG:TELNET Started 23]
Grbl 1.2a ['$' for help]
#1 – MitchBradley 于 2020-06-09
I too am having to learn to think in C++.