New user: Rebuilding an older printer with Duet 3 mini 5+
-
I am in the process of rebuilding and updating an old Makerfarm prusa i3v 8" printer after the old ramps board died. I have been able to work through adding the second Z axis motor and getting all the microswitches to correctly register, however I am running into some other issues that have confused me.
The first issue is that I am unable to get the servo mounted z-probe to rotate (at all) into position for bed leveling. When the machine is first powered on you can hear and see the servo move (slightly) however I cannot get the M280 command to control it. I have the servo (a sg90 type hobby servo) with a microswitch (NO) plugged into IO_3 using in, out, ground and 5V.
The second issue I am having is that the motors are making a loud (buzzing/screeching?) noise. It is quite loud and as a temporary measure I set M84 to 10 seconds to keep the noise down while testing. Being new to Duet I am unsure what settings to change/adjust to reduce this noise. The model of the steppers is 42BHH48-050-24A. I tried turning Interpolation on/off and lowering the current to 400mA but that did not seem to have much of an effect. Setting the Z-axis to 500mA gives me an odd error of "Warning: Driver 0.4 warning: phase A may be disconnected, phase B may be disconnected Warning: Driver 0.3 warning: phase A may be disconnected, phase B may be disconnected" however this warning is not there when the steppers are set to 400mA.
Here it the code I have so far. Any help would be appreciated.
; Drives M569 P0.1 S0 ; physical drive 0.1 goes backwards X axis M569 P0.2 S0 ; physical drive 0.2 goes backwards Y axis M569 P0.3 S1 ; physical drive 0.3 goes backwards Z-Left axis M569 P0.4 S1 ; physical drive 0.3 goes backwards Z-Right axis M569 P0.0 S0 ; physical drive 0.0 goes backwards Extruder M584 X0.1 Y0.2 Z0.3:0.4 E0.0 ; set drive mapping M350 X16 Y16 Z16 E16 I0 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z2560.00 E420.00 ; set steps per mm M566 X900.00 Y900.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X6000.00 Y6000.00 Z180.00 E1200.00 ; set maximum speeds (mm/min) M201 X500.00 Y500.00 Z20.00 E250.00 ; set accelerations (mm/s^2) M906 X400 Y400 Z400 E400 I0 ; set motor currents (mA) and motor idle factor in per cent M84 S10 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X200 Y200 Z250 S0 ; set axis maxima ; Endstops M574 X1 S1 P"io0.in" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin io0.in M574 Y1 S1 P"io1.in" ; configure switch-type (e.g. microswitch) endstop for low end on Y via pin io1.in M574 Z1 S0 ; configure Z-probe endstop for low end on Z ; Z-Probe M950 S0 C"i03.out" ; Create Servo pin on i03 for Z-probe M558 P5 C"^!io3.in" H5 F120 T6000 ; set Z probe type to switch and the dive height + speeds G31 P500 X43 Y5 Z-0.6 ; set Z probe trigger value, offset and trigger height M557 X15:185 Y15:185 S20 ; define mesh grid ; Heaters M308 S0 P"temp0" Y"thermistor" T100000 B4138 ; configure sensor 0 as thermistor on pin temp0 M950 H0 C"out0" T0 ; create bed heater output on out0 and map it to sensor 0 M307 H0 B0 S1.00 ; disable bang-bang mode for the bed heater and set PWM limit M140 H0 ; map heated bed to heater 0 M143 H0 S120 ; set temperature limit for heater 0 to 120C M308 S1 P"temp1" Y"thermistor" T100000 B4138 ; configure sensor 1 as thermistor on pin temp1 M950 H1 C"out1" T1 ; create nozzle heater output on out1 and map it to sensor 1 M307 H1 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit M143 H1 S280 ; set temperature limit for heater 1 to 280C ; Fans M950 F0 C"out3" Q500 ; create fan 0 on pin out3 and set its frequency M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned off M950 F1 C"out4" Q500 ; create fan 1 on pin out4 and set its frequency M106 P1 S1 H1 T45 ; set fan 1 value. 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 ; Miscellaneous M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
-
@Q2101 this line looks wrong:
; Z-Probe
M950 S0 C"i03.out"Looks like you used i03.out as the servo pin name instead of io3.out. Tip: run M98 P"config.g" to check whether any of the commands in config.g provoke error messages.
Check that the phases of the stepper motors are connected correctly as described at https://docs.duet3d.com/User_manual/Connecting_hardware/Motors_connecting.
-
Opps, that fixed the servo control issue. Sometimes it is good to have another set of eyes looking at the commands. I'll try to remember M98 next time I make changes.
I used that guide to wireup the steppers before coming here and I did have 1 or 2 wired incorrectly at that time but they are correct now. What is odd, to me, is that I don't get the phase errors when driving them at 400mA vs the 500mA (which should be the max current rating for that motor).
-
@Q2101 detection of open circuit phases is unreliable at low currents, so RRF doesn't report them when the current is set to less than 500mA.
-
@dc42 After doing some testing it seem the noise is related to the idle, as the motors made the expected amount of noise while in motion. Turning on stealthchop within M569 seems to have eliminated the buzzing/screeching noise.
-
@Q2101 the buzzing/screeching noise is odd. Usually, the only reason motors screech is that you are trying to move them too fast, or with too high an acceleration, so that they stop moving and screech instead. The cure for that is to reduce speed or acceleration and/or increase motor current.
It is not unusual for motors to make slight hissing noise when at standstill.
If the motor are especially noisy when moving but not actually screeching, possible causes include:
- Microstepping not set correctly. For axis motors we recommend x16 microstepping with interpolation enabled. This is the default, but it can be changed using the M350 command.
- If they are noisy above a certain speed, it could mean that the back emf exceeds the driver supply voltage. We provide a calculator at https://www.reprapfirmware.org/emf.html to help you calculate this.
-
Was able to get the printer moving and without excess noise once the stealthchop was turned on.
Now I am running into an issue with the true bed leveling (G32) and the Mesh Compensation (G29) which is likely due to me not understanding how to configure it correctly. My z-probe is located (looking at it from the front of the machine) to the right of the nozzle along the x-axis and slightly in front of the nozzle along the y-axis. Going by the guide, this means that x and y should be negative when I set them in the config.g file using G31 correct? With this being a Pursa variant the two z motors are to the left and right of the bed, with the end stop (min) being on the right.
What happens is I will home the axis, which works fine. Then if I run the G32, it will home (as expected since G28 is in the bed.g file) then after home it will move to x=43.7(X0+43.7) and y=15.4 (Y10+5.4) to probe the bed, which is also my z offsets for the probe. It will then move to X=193.7, which will put this off of the bed. The same thing will occur with G29, it will start at X=43.7 and probe every 20mm until it is also off of the bed.
Thinking the z-probe offset might be reversed, I changed the sign, which sent the head crashing into the x endstop. Changing the 1st probe for the bed.g to X-43.7 got the first probe of G32 to probe in the right location, but it still goes off bed on the second probe. Im not sure what settings to change to get this working correctly.
Moving the head around manually, the positions I would expect it to probe(based on nozzle position) would be at X0 (the right side looking at the front of the printer) and X150 (the left side looking at the front of the printer), which keeps the probe over the bed.
config.g
; Configuration file for Duet 3 Mini 5+ (firmware version 3.3) ; executed by the firmware on start-up ; ; generated by RepRapFirmware Configuration Tool v3.3.13 on Sun Oct 09 2022 18:42:47 GMT-0400 (Eastern Daylight Time) ; General preferences G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"Q's Pursia i3" ; set printer name ; Network M552 S1 ; enable network M586 P0 S1 ; enable HTTP M586 P1 S0 ; disable FTP M586 P2 S0 ; disable Telnet ; Drives M569 P0.1 S0 D3 ; physical drive 0.1 goes backwards X axis M569 P0.2 S0 D3 ; physical drive 0.2 goes backwards Y axis M569 P0.3 S1 D3 ; physical drive 0.3 goes backwards Z-Left axis M569 P0.4 S1 D3 ; physical drive 0.3 goes backwards Z-Right axis M569 P0.0 S0 D3 ; physical drive 0.0 goes backwards Extruder M584 X0.1 Y0.2 Z0.3:0.4 E0.0 ; set drive mapping M671 X0:150 Y0:0 ; Defining Leadscrew postions M350 X16 Y16 Z16 E16 I0 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z1600.00 E850 ; set steps per mm M566 X900.00 Y900.00 Z120.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X6000.00 Y6000.00 Z360.00 E1200.00 ; set maximum speeds (mm/min) M201 X500.00 Y500.00 Z40.00 E250.00 ; set accelerations (mm/s^2) M906 X480 Y480 Z480 E480 I50 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0:200 Y0:200 Z0:250 ; set axis Min/Max ; Endstops M574 X1 S1 P"io0.in" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin io0.in M574 Y1 S1 P"io1.in" ; configure switch-type (e.g. microswitch) endstop for low end on Y via pin io1.in M574 Z1 S1 P"!io2.in" ; configure Z-probe endstop for low end on Z ; Z-Probe M950 S0 C"io3.out" ; Create Servo pin on i03 for Z-probe M558 P5 C"^!io3.in" H5 F120 T6000 ; set Z probe type to switch and the dive height + speeds G31 P500 X-43.7 Y-5.4 Z0.68 ; set Z probe trigger value, offset and trigger height M557 X15:185 Y15:185 S20 ; define mesh grid ; Heaters M308 S0 P"temp0" Y"thermistor" T100000 B3950 ; configure sensor 0 as thermistor on pin temp0 M950 H0 C"out0" T0 ; create bed heater output on out0 and map it to sensor 0 M307 H0 R0.301 K0.364:0.000 D3.49 E1.35 S1.00 B0 ; disable bang-bang mode for the bed heater and set PWM limit M140 H0 ; map heated bed to heater 0 M143 H0 S120 ; set temperature limit for heater 0 to 120C M308 S1 P"temp1" Y"thermistor" T100000 B4725 C7.06e-8 ; configure sensor 1 as Semitec 104NT thermistor on pin temp1 M950 H1 C"out1" T1 ; create nozzle heater output on out1 and map it to sensor 1 M307 H1 R1.085 K0.313:0.000 D4.94 E1.35 S1.00 B0 V10.0 ; disable bang-bang mode for heater and set PWM limit M143 H1 S300 ; set temperature limit for heater 1 to 300C ; Fans M950 F0 C"out3" Q500 ; create fan 0 on pin out3 and set its frequency M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned off M950 F1 C"out4" Q500 ; create fan 1 on pin out4 and set its frequency M106 P1 S1 H1 T45 ; set fan 1 value. 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 ; Miscellaneous M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
Bed.g
; bed.g ; called to perform automatic bed compensation via G32 ; ; generated by RepRapFirmware Configuration Tool v3.3.13 on Sun Oct 09 2022 18:42:46 GMT-0400 (Eastern Daylight Time) M561 ; clear any bed transform G28 ; home G30 P0 X-43.7 Y10 Z-99999 ; probe near a leadscrew, half way along Y axis G30 P1 X150 Y10 Z-99999 S2 ; probe near a leadscrew and calibrate 2 motors G29 ; probe the bed and enable compensation
homez.g
; homez.g ; called to home the Z axis ; ; generated by RepRapFirmware Configuration Tool v3.3.13 on Sun Oct 09 2022 18:42:47 GMT-0400 (Eastern Daylight Time) G91 ; relative positioning G1 H2 Z3 F6000 ; lift Z relative to current position G1 X0 Y10 F6000 ; go to first probe point M401 ; Deploy Probe G30 ; home Z by probing the bed M402 ; Retract Probe G90 ; absolute positioning ; Uncomment the following lines to lift Z after probing ;G91 ; relative positioning ;G1 Z5 F100 ; lift Z relative to current position ;G90 ; absolute positioning
-
@Q2101 said in New user: Rebuilding an older printer with Duet 3 mini 5+:
to the right of the nozzle along the x-axis and slightly in front of the nozzle along the y-axis.
To the right of the nozzle would make X positive. In front of the nozzle would make Y negative.
Typically -X to the left, + X to the right. -Y in front, +Y to the back.
If your setup is different than this, you may need to change the motor direction of rotation, and consequently the directions of movement in your homing files, and the definition of the endstop depending on which end of the axis the endstop is located.
This may explain the weirdness in movement you seem to be having.
Based on your config the endstops would be located on the left side for X and at the front for Y. Is that the case?
Please also post your homeall.g
It would also help if you post the results of M122 and M98 P"config.g".