Comments (21)
I now have added a board profile and tentative support for both ganged/auto squared axes and TMC5160 stepper drivers. Since I do not have the hardware to verify these changes with I'll have to ask you to do that.
Build configuration is in CMakeLists.txt.
Note that I have not added support for enabling SD Card and Trinamic drivers at the same time, try with Trinamic drivers first.
from esp32.
Thank so much i'll get this tested in the next few days
from esp32.
Got it compiled and flashed everything works except i cannot get the steppers to move. They seem to be recognized and i was able to change the amount of current going to them but I cannot get them to move at all. I've messed around with inverting the direction pins but that doesn't seem to be having an effect. Although i found if i enabled a pull-up on the reset button the steppers would move very slightly when i pressed the reset button. I could be missing some super obvious setting though. i've included the setting i have currently below
%
; grblHAL
; 1.1f.20211209
; [OPT:VNMSL2,35,1024,3,0]
; [NEWOPT:ENUMS,RT+,HOME,TC,SED,TMC=7]
; [MSG:Caution: Unlocked]
;
$N0=
$N1=
; 0 - Step pulse time
$0=10.0
; 1 - Step idle delay
$1=25
; 2 - Step pulse invert
$2=0
; 3 - Step direction invert
$3=0
; 4 - Invert stepper enable pin(s)
$4=4
; 5 - Invert limit pins
$5=7
; 6 - Invert probe pin
$6=1
; 7 - Disable spindle with zero speed
$7=0
; 8 - Ganged axes direction invert
$8=0
; 10 - Status report options
$10=4095
; 11 - Junction deviation
$11=0.010
; 12 - Arc tolerance
$12=0.002
; 13 - Report in inches
$13=0
; 14 - Invert control pins
$14=1
; 15 - Invert coolant pins
$15=0
; 16 - Invert spindle signals
$16=0
; 17 - Pullup disable control pins
$17=0
; 18 - Pullup disable limit pins
$18=7
; 19 - Pullup disable probe pin
$19=0
; 20 - Soft limits enable
$20=0
; 21 - Hard limits enable
$21=0
; 22 - Homing cycle
$22=1
; 23 - Homing direction invert
$23=0
; 24 - Homing locate feed rate
$24=25.0
; 25 - Homing search seek rate
$25=500.0
; 26 - Homing switch debounce delay
$26=250
; 27 - Homing switch pull-off distance
$27=1.000
; 28 - G73 Retract distance
$28=0.100
; 29 - Pulse delay
$29=0.0
; 30 - Maximum spindle speed
$30=1000.000
; 31 - Minimum spindle speed
$31=0.000
; 32 - Mode of operation
$32=0
; 33 - Spindle PWM frequency
$33=5000
; 34 - Spindle PWM off value
$34=0.0
; 35 - Spindle PWM min value
$35=0.0
; 36 - Spindle PWM max value
$36=100.0
; 37 - Steppers deenergize
$37=0
; 39 - Enable legacy RT commands
$39=1
; 40 - Limit jog commands
$40=0
; 43 - Homing passes
$43=1
; 44 - Axes homing, first pass
$44=4
; 45 - Axes homing, second pass
$45=3
; 46 - Axes homing, third pass
$46=0
; 62 - Sleep enable
$62=0
; 63 - Feed hold actions
$63=2
; 64 - Force init alarm
$64=0
; 65 - Probing feed override
$65=0
; 100 - X-axis travel resolution
$100=200.000
; 101 - Y-axis travel resolution
$101=200.000
; 102 - Z-axis travel resolution
$102=200.000
; 110 - X-axis maximum rate
$110=4000.000
; 111 - Y-axis maximum rate
$111=4000.000
; 112 - Z-axis maximum rate
$112=2500.000
; 120 - X-axis acceleration
$120=150.000
; 121 - Y-axis acceleration
$121=150.000
; 122 - Z-axis acceleration
$122=150.000
; 130 - X-axis maximum travel
$130=550.000
; 131 - Y-axis maximum travel
$131=720.000
; 132 - Z-axis maximum travel
$132=806.000
; 140 - X-axis motor current
$140=1950
; 141 - Y-axis motor current
$141=1950
; 142 - Z-axis motor current
$142=1950
; 150 - X-axis microsteps
$150=8
; 151 - Y-axis microsteps
$151=8
; 152 - Z-axis microsteps
$152=8
; 200 - X-axis StallGuard2 fast threshold
$200=22
; 201 - Y-axis StallGuard2 fast threshold
$201=22
; 202 - Z-axis StallGuard2 fast threshold
$202=23
; 210 - X-axis hold current
$210=60
; 211 - Y-axis hold current
$211=50
; 212 - Z-axis hold current
$212=60
; 220 - X-axis stallGuard2 slow threshold
$220=22
; 221 - Y-axis stallGuard2 slow threshold
$221=22
; 222 - Z-axis stallGuard2 slow threshold
$222=22
; 338 - Trinamic driver
$338=7
; 339 - Sensorless homing
$339=0
; 341 - Tool change mode
$341=0
; 342 - Tool change probing distance
$342=30.0
; 343 - Tool change locate feed rate
$343=25.0
; 344 - Tool change search seek rate
$344=200.0
; 345 - Tool change probe pull-off rate
$345=100.0
; 384 - Disable G92 persistence
$384=0
%
from esp32.
Try $4=7
from esp32.
That appears to have done it. What setting does that change?
from esp32.
Motor enable signals - opposite of legacy Grbl where it is motor disable.
Send $$=4
for info.
from esp32.
Okay so i it seems to all be working except the motor ganging Y2 will only move in one direction no matter which button is pressed it always moves the same way, Y1 behaves normally.
from esp32.
Is the pin definition for the Y2 motor direction correct?
#define M3_DIRECTION_PIN GPIO_NUM_32
from esp32.
Yep just double checked against the default firmware and the grblHAL pins and they're all correct should be 32 for direction and 33 for step.
from esp32.
Setting direction is done here:
Lines 761 to 788 in 0f64293
Can you copy line 782 to below line 766 and try again? If not working then the pin is likely not set as output at startup as it should.
from esp32.
Yeah no luck on copying the 786 to 766 had a shot at switching the driver pins to see if the issues move to the other driver it seems they always stay on that driver even if it's assigned to Y1. So yeah I guess it's likey the output pin is not set correctly at start up. Is there anything i can try to rectify that?
from esp32.
Went back to GRBL ESP32 and the direction pin is working there so i assume there is some weird software thing going on somewhere.
from esp32.
The pin is set as input due to an incorrectly sized variable, replace these lines with:
for(idx = 0; idx < (N_AXIS + N_ABC_MOTORS); idx++)
rmt_set_source_clk(idx, RMT_BASECLK_APB);
uint64_t mask = 0;
I guess I should make a "motherboard" for my Nucleo-64 BOB for testing...
from esp32.
Works thanks so much. The Y2/A driver, however, seems to not like resetting after a reset the other drivers all work but the Y2 fails to come back up and needs to reset the controller too. Not a huge issue but i thought I'd mention it. Also is there any way to disable stealth chop which seems to be on by default on ZY1Y2 but not X
from esp32.
the Y2 fails to come back up and needs to reset the controller too.
It does not turn anymore?
Also is there any way to disable stealth chop ...
Yes, basic configuration is in trinamic.h.
... which seems to be on by default on ZY1Y2 but not X
Did you see that in the Trinamic tuner tab in ioSender when querying the driver status? If so it disables StealthChop for the selected axis and reenables it when leaving the tab.
from esp32.
It does not turn anymore?
It fails to respond to commands after a reset either manual or caused by an alarm and requires a full power cycle to bring it back online
from esp32.
Ok, what happens if you send M122I
to reinitialize the drivers?
from esp32.
Yes, basic configuration is in trinamic.h.
Got it disabled but i had to go into the tmc5160.h file to do it
from esp32.
Ok, what happens if you send
M122I
to reinitialize the drivers?
hmmm that brings them back but they have extreme vibrations and run terribly until i do a full reset
from esp32.
I have fixed a number of bugs in the Trinamic code and just committed an update, hopefully this will fix your problems.
from esp32.
That seems to have resolved all outstanding issues. Thanks so much for the help is there anywhere i can donate to support this project?
from esp32.
Related Issues (20)
- Flashed xPRO V5 Only communicating with X axis driver HOT 2
- Compilation error HOT 9
- Build fails with error in uart_serial.c HOT 11
- Watchdog task when connecting to WiFi HOT 1
- flash firmware su mks dlc32 v.2.1 HOT 24
- Controller randomly stops HOT 4
- unable to compile latest version HOT 4
- Issues Web interface HOT 6
- Can't compile BOARD_MKS_TINYBEE_V1 .esp32 I get errors HOT 3
- Spindle minimum stop time 1 sec. and I have a laser. HOT 4
- typo in vscode ini files HOT 3
- How to use UART1? HOT 7
- Difficult to compile ESP32 Project! HOT 2
- "Task watchdog got triggered." when WEBSOCKET_ENABLE or TELNET_ENABLE HOT 6
- Web Builder - auto square HOT 3
- Build image not working HOT 21
- Changing pin mapping - MKS Tinybee HOT 4
- Limits override cannot save. HOT 1
- How to invert motor fault pin? HOT 2
- E-stop (Reset) no pullup? HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from esp32.