How to configure drivers 10 and 11 on CONN_LCD?
-
@catalin59 I'm a bit late coming to this thread or I might have been able to help. The extruder drive number thing has bitten my in ar#e twice - the second time I knew about it but it still caught me out. In a nutshell, for M563 the "D" parameter refers to the extruder drive, not the motor drive (but you know that now).
Ref the inability to move the extruder, it might just be that you need to make the tool active (even though it has no heater) so try sending a T0 first. Then M302 P1. Then G1 Enn
-
@deckingman I am doing both M302 P1 (allow cold extrusion) and T0 already and I can see the tool status change in the Web Interface accordingly. But the two Retract and Extrude buttons are always greyed out and the extruder motor never moves.
-
@catalin59 said in How to configure drivers 10 and 11 on CONN_LCD?:
@deckingman I am doing both M302 P1 (allow cold extrusion) and T0 already and I can see the tool status change in the Web Interface accordingly. But the two Retract and Extrude buttons are always greyed out and the extruder motor never moves.
Can you post your whole config.g?
Ian
-
@droftarts This is a work in progress (no endstops, no extruder heaters, no fans yet) but CoreXY, 3-motor axis Z and bed heater are working already:
; Configuration file for Duet WiFi (firmware version 2.03)
; executed by the firmware on start-up
;
; generated by RepRapFirmware Configuration Tool v2.0.4 on Fri Sep 20 2019 21:45:29 GMT-0400 (Eastern Daylight Time); General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"My Printer" ; set printer nameM667 S1 ; select CoreXY mode
; Network
M552 S1 ; enable network
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives
M569 P0 S0 ; physical drive 0 goes backwards
M569 P1 S0 ; physical drive 1 goes backwards
M569 P2 S1 ; physical drive 2 goes forwards
M569 P3 S1 ; physical drive 3 goes forwards
M569 P4 S1 ; physical drive 4 goes forwards
M569 P5 S1 ; physical drive 5 goes forwards
M569 P6 S1 ; physical drive 6 goes forwards
M569 P7 S1 ; physical drive 7 goes forwards
M569 P8 S1 ; physical drive 8 goes forwards
M569 P9 S1 ; physical drive 9 goes forwards
M584 X0 Y1 Z2:3:4 E10 ; set drive mapping
M563 P0 D0 ; set tool 0 to driver 10 (first extruder on CONN_LCD)
M350 X16 Y16 Z16 E16:16:16:16:16:16:16 I1 ; configure microstepping with interpolation
M92 X80.00 Y80.00 Z800.00 E800.00:800.00:420.00:420.00:420.00:420.00:420.00 ; set steps per mm
M566 X900.00 Y900.00 Z12.00 E12.00:12.00:120.00:12.00:12.00:12.00:12.00 ; set maximum instantaneous speed changes (mm/min)
M203 X60000.00 Y60000.00 Z1200.00 E1200.00:1200.00:1200.00:1200.00:1200.00:1200.00:1200.00 ; set maximum speeds (mm/min)
M201 X500.00 Y500.00 Z250.00 E250.00:250.00:250.00:250.00:250.00:250.00:250.00 ; set accelerations (mm/s^2)
M906 X1600 Y1600 Z1600 E1600:1600:1600:1600:1600:1600:1600 I30 ; set motor currents (mA) and motor idle factor in per cent
M84 S30 ; Set idle timeout; Axis Limits
M208 X0 Y0 Z0 S1 ; set axis minima
M208 X230 Y210 Z200 S0 ; set axis maxima; Endstops
M574 X0 Y0 Z0 S0 ; set active low and disabled endstops; Z-Probe
M558 P0 H5 F120 T6000 ; disable Z probe but set dive height, probe speed and travel speed
M557 X15:215 Y15:195 S20 ; define mesh grid; Heaters
M140 H0 ; enable heated bed
M305 P0 X500 R4700 ; set PT1000 for heater 0
M143 H0 S120 ; set temperature limit for heater 0 to 120C; Fans
M106 P0 S0 I0 F500 H-1 ; set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P1 S1 I0 F500 H1 T45 ; set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on; Tools
M563 P0 D0 H1 F0 ; define tool 0
G10 P0 X0 Y0 Z0 ; set tool 0 axis offsets
G10 P0 R0 S0 ; set initial tool 0 active and standby temperatures to 0C; Custom settings are not defined
After startup, on top of this I execute manually:
M302 P1
M564 S0 H0
M563 P0 D0
T0I can move on XYZ as expected, I can control the bed heating but I cannot move the extruder motor connected to driver 10 on CONN_LCD. I know that the extruder driver and motor are working because the STEP/DIR/ENABLE interface works when tested separately. The Extrude and Retract buttons on the Web Interface are greyed out.
Thanks a lot for the offer to help with this issue. It looks like I am the first one using all 5 onboard drivers for XYZ and the two CONN_LCD extra interfaces for extruders, I have found the documentation on how to connect this but nothing on the required G-Code comands to set this up.
-
M563 P0 D0 H1 F0 ; define tool 0
Your tool definition references a heater that doesn't exist. Perhaps it doesn't like that. Perhaps try adding a dummy heater definition for H1. Even if it doesn't actually exist, it shouldn't matter as long as you're allowing cold extrudes.
-
@catalin59 These are just some annotations to your config.g, perhaps you will give them a try?
• You define tool0 (M563) a bit too often: first in section "Drives“, then under "Tools“ where the M563 G-code belongs, and on top of that, you execute it manually. As you use different parameters with M563, I really can’t tell you which of them RRF applies. Please stay with the tool definition in the section "Heaters“.
• There, you should remove H1 from M563, as for now, you don’t have specified that heater yet. Also in that section, you should comment-out the line "G10 P0 R0 S0“. - No heater = no temperatures to be set.
• Then, I’m puzzled with your assignments in "Drives“: with M569, you tell the board to control 10 steppers (P0-P9)? Remove the lines who have no physical counterpart. On the other hand, there is no M569 entry for P10 - the drive you assign to the first extruder in M584 … E10. Maybe you should add this.
• To be safe, you should move the Entry M584 … from „Drives“ way up, according to the docu, it should come earlier than some other G-codes in the config.g. I’m not sure whether or not your extruder assignment is counted as a new axis, but it is better to take no risk:
M584 must come earlier in config.g than any M350 and M906 commands. If it creates new axes, it must also be earlier than any M92, M201, M203, M208, M350, M566, M574 , M667 and M669 commands.
-
@catalin59 I tend to agree with all of @infiniteloop suggestions above! You'll also want an M569 for each of drives 10 and 11, to define which way they turn.
To check that the motors on drivers 10 and 11 actually work, rather than go to the effort of defining heaters and tools, define these two motors as extra axes. Then you'll get simple jog controls in the DWC, rather than having to define the heater etc. Change your M584 to:
M584 X0 Y1 Z2:3:4 U10 V11 E5 ; set drive mapping
(The E5 is just a temporary mapping)
Add the U and V motor settings to M92, M566, M203, and M201. M350 and M906 are set by the stepper driver, the Duet cannot control these.
Depending on which external stepper driver you are using (what are you using?) you may need to change the length of the pulse that tells the stepper driver to move; see the T parameter of M569.
Finally, you won't be able to move the axes without homing. The easiest way to do this is to give the motors a position. Send
G92 U100 V100
, then you should be able to jog the axes.Ian
-
@infiniteloop All these are good suggestions. I tried to implement them and also cleaned up config.g which now looks like this:
; Configuration file for Duet WiFi (firmware version 2.03)
; executed by the firmware on start-up
;
; generated by RepRapFirmware Configuration Tool v2.0.4 on Fri Sep 20 2019 21:45:29 GMT-0400 (Eastern Daylight Time); General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"My Printer" ; set printer nameM667 S1 ; select CoreXY mode
; Network
M552 S1 ; enable network
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable TelnetM584 X0 Y1 Z2:3:4 E10 ; set drive mapping
; Drives
M569 P0 S0 ; physical drive 0 goes backwards
M569 P1 S0 ; physical drive 1 goes backwards
M569 P2 S1 ; physical drive 2 goes forwards
M569 P3 S1 ; physical drive 3 goes forwards
M569 P4 S1 ; physical drive 4 goes forwards
M569 P10 S1 ; physical drive 10 goes forwards
M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation
M92 X80.00 Y80.00 Z800.00 E800.00 ; set steps per mm
M566 X900.00 Y900.00 Z12.00 E12.00 ; set maximum instantaneous speed changes (mm/min)
M203 X60000.00 Y60000.00 Z1200.00 E1200.00 ; set maximum speeds (mm/min)
M201 X500.00 Y500.00 Z250.00 E250.00 ; set accelerations (mm/s^2)
M906 X1600 Y1600 Z1600 E1600 I30 ; set motor currents (mA) and motor idle factor in per cent
M84 S30 ; Set idle timeout; Axis Limits
M208 X0 Y0 Z0 S1 ; set axis minima
M208 X230 Y210 Z200 S0 ; set axis maxima; Endstops
M574 X0 Y0 Z0 S0 ; set active low and disabled endstops; Z-Probe
M558 P0 H5 F120 T6000 ; disable Z probe but set dive height, probe speed and travel speed
M557 X15:215 Y15:195 S20 ; define mesh grid; Heaters
M140 H0 ; enable heated bed
M305 P0 X500 R4700 ; set PT1000 for heater 0
M143 H0 S120 ; set temperature limit for heater 0 to 120C; Fans
M106 P0 S0 I0 F500 H-1 ; set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P1 S1 I0 F500 H1 T45 ; set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on; Tools
;M563 P0 D0 H1 F0 ; define tool 0
M563 P0 D0 ; define tool 0
G10 P0 X0 Y0 Z0 ; set tool 0 axis offsets
;G10 P0 R0 S0 ; set initial tool 0 active and standby temperatures to 0C; Custom settings are not defined
I execute manually T0 and M302 P1 but nothing has changed, the Extrude/Retract are still greyed out and G1 Ennn does nothing.
-
@catalin59 Well, when moving M584 upwards, you overlooked one command it should precede - hint: M667 in the “General“ section. After that, you should follow @droftarts’ advice… Forget Extrude/Retract in DWC for a moment, the primary objective is not to paint it black (hm, why does this remind me of one of my favourite tunes?), but to convince the stepper to do what he’s built for. With @droftarts’ proposal, it’s easy to test the drive mappings - first things first.
-
I moved M584 before M667 and changed it to M584 X0 Y1 Z2:3:4 U10 V11 E5. I see now two more axes U and V in the web interface. Movement commands on X, Y and Z work as expected. Movement comands on U are ignored and it takes a couple of seconds for something to time out before the next move command is processed. For example, if I move U and immediately X, nothing happens for about 3 seconds then the X move gets executed.
I have tested the STEP/DIR driver interface by manually creating STEP pulses with an external 3V/2mA source and the extruder motor does move so I am pretty sure this is not some connectivity problem but still a G-Code issue. Drivers 10 and 11 on CONN_LCD are special and something different must be done compared with the 5 onboard ones.
-
@droftarts said in How to configure drivers 10 and 11 on CONN_LCD?:
Depending on which external stepper driver you are using (what are you using?) you may need to change the length of the pulse that tells the stepper driver to move; see the T parameter of M569.
Like I said earlier, external drivers often need different step pulse length. Refer to documentation, or tell us what drivers they are so we can suggest settings.
Ian
-
@droftarts OK, I wish I knew which of the changes finally mattered but I don't. I probed the STEP output with an oscilloscope and the pulses are there and the pulse length is fine. I was able to move the extruder motor first as U axis and then as extruder 0, all is good now.
I want to thank all the people that made suggestions, it really did help a lot, I think we can close this thread now. For those with a similar configuration as mine (CoreXY, three Z motors and two extruders with external drivers on CONN_LCD here is my config.g - this is a work in progress and it's not complete but all the motors are working now as does the bed heater (with a PT1000 sensor):
; General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"My Printer" ; set printer nameM584 X0 Y1 Z2:3:4 E10:11 ; set drive mapping
;M584 X0 Y1 Z2:3:4 U10 V11 E5 ; set extruder drivers as U and V axes just for testing
M667 S1 ; select CoreXY mode; Network
M552 S1 ; enable network
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives
M569 P0 S0 ; physical drive 0 goes backwards
M569 P1 S0 ; physical drive 1 goes backwards
M569 P2 S1 ; physical drive 2 goes forwards
M569 P3 S1 ; physical drive 3 goes forwards
M569 P4 S1 ; physical drive 4 goes forwards
M569 P10 S1 ; physical drive 10 goes forwards
M569 P11 S1 ; physical drive 11 goes forwards
M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation
M92 X80.00 Y80.00 Z800.00 E800.00 ; set steps per mm
M566 X900.00 Y900.00 Z12.00 E12.00 ; set maximum instantaneous speed changes (mm/min)
M203 X60000.00 Y60000.00 Z1200.00 E1200.00 ; set maximum speeds (mm/min)
M201 X500.00 Y500.00 Z250.00 E250.00 ; set accelerations (mm/s^2)
M906 X1600 Y1600 Z1600 E1600 I30 ; set motor currents (mA) and motor idle factor in per cent
M84 S30 ; Set idle timeout; Axis Limits
M208 X0 Y0 Z0 S1 ; set axis minima
M208 X230 Y210 Z200 S0 ; set axis maxima; Endstops
M574 X0 Y0 Z0 S0 ; set active low and disabled endstops; Z-Probe
M558 P0 H5 F120 T6000 ; disable Z probe but set dive height, probe speed and travel speed
M557 X15:215 Y15:195 S20 ; define mesh grid; Heaters
M140 H0 ; enable heated bed
M305 P0 X500 R4700 ; set PT1000 for heater 0
M143 H0 S120 ; set temperature limit for heater 0 to 120C; Fans
M106 P0 S0 I0 F500 H-1 ; set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P1 S1 I0 F500 H1 T45 ; set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned on; Tools
M563 P0 D0 ; define tool 0 (motor driver 10)
M563 P1 D1 ; define tool 1 (motor driver 11) -
I forgot to mention that the Extrude/Retract Web Interface buttons are still greyed out and do not work, I can only move the extruder motor with G1 Ennn commands. No big deal.
-
@catalin59 So I understand you right: you can command your extruder stepper (physical drive 10, mapped to E10 and assigned to tool 0) with the external driver by G-codes? That was the biggest hurdle, congratulations!
Now, to get the web interface activated, you might proceed with your tool definition - adding heater, fan and thermistor, that is. If you still got no physical devices attached, follow @Phaedrux’s advice and try adding a dummy heater definition… I may be wrong, but IMHO, the DWC tool control interface is mainly there to control the temperatures of a tool, so it might need more than just a stepper to become functional.
With the extract/retract buttons in DWC, I'm not sure of the reason why they are still disabled - maybe someone else has an idea?
-
@catalin59 said in How to configure drivers 10 and 11 on CONN_LCD?:
I forgot to mention that the Extrude/Retract Web Interface buttons are still greyed out and do not work, I can only move the extruder motor with G1 Ennn commands. No big deal.
What version of DWC are you using? I just tried on my machine using 2.0.4 and the buttons are normally greyed out but if I send M302 P1 they become "non-greyed" and active. The same works on DWC 1.22.6. If you are using some other version of DWC, it might be worth trying one of the above.
-
@deckingman The Web Interface version is 1.22.6