Crying stepper motors
-
@Rushmere3D
; General preferences
G90 ; send absolute coordinates...
M83 ; ...but relative extruder moves
M550 P"My Printer" ; set printer name; Network
M552 P169.254.179.25 S1 ; enable network and set IP address
M553 P255.255.0.0 ; set netmask
M554 P192.168.150.1 ; set gateway
M586 P0 S1 ; enable HTTP
M586 P1 S0 ; disable FTP
M586 P2 S0 ; disable Telnet; Drives
M569 P0.0 S1 ; physical drive 0.0 goes forwards
M569 P0.1 S1 ; physical drive 0.1 goes forwards
M569 P0.2 S1 ; physical drive 0.2 goes forwards
M569 P0.3 S1 ; physical drive 0.3 goes forwards
M584 X0.0 Y0.1 Z0.2 E0.3 ; set drive mapping
M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation
M92 X80.00 Y80.00 Z400.00 E420.00 ; set steps per mm
M566 X900.00 Y900.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min)
M203 X1000.00 Y1000.00 Z180.00 E1200.00 ; set maximum speeds (mm/min)
M201 X200.00 Y200.00 Z20.00 E250.00 ; set accelerations (mm/s^2)
M906 X800 Y800 Z800 E800 I60 ; 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 X1 S1 P"io1.in" ; configure switch-type (e.g. microswitch) endstop for low end on X via pin io1.in
M574 Y2 S1 P"io2.in" ; configure switch-type (e.g. microswitch) endstop for high end on Y via pin io2.in
M574 Z1 S2 ; configure Z-probe endstop for low end on Z; Z-Probe
;M950 S0 C"io3.out" ; create servo pin 0 for BLTouch
;M558 P9 C"temp2" H5 F120 T6000 ; set Z probe type to bltouch and the dive height + speeds
;G31 P500 X25 Y0 Z2.5 ; set Z probe trigger value, offset and trigger height
;M557 X15:215 Y15:195 S20 ; define mesh grid; Heaters
M308 S0 P"spi.cs1" Y"thermocouple-max31856" A"Thermocouple" K"K" F50 ; configure sensor 0 as typ k thermocouple on pin spi.cs1 (TC0)
M950 H0 C"out1" T0 ; create bed heater output on out1 and map it to sensor 0
M307 H0 B1 S1.00 ; enable bang-bang mode for the bed heater and set PWM limit
M140 H0 ; map heated bed to heater 0
M143 H0 S280 ; set temperature limit for heater 0 to 280C
;M308 S1 P"1.spi.cs1" Y"thermocouple-max31856" K"S"; define temperature sensor number 1 as a Type thermocouple on the first port of a temperature daughter board plugged into the expansion board with CAN bus address 3.
;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;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
M501 ; load saved parameters from non-volatile memory
M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
T0 ; select first tool; Configuring steps and speeds
;M584 X0 Y1 Z2:3 E4:5 ; set drive mapping;M350 X16 Y16 Z16 E16:16 I1 ; configure microstepping with interpolation
;M92 X80.00 Y80.00 Z400.00 E420.00:420.00 ; set steps per mm;Setting motor speeds and accelerations
;M584 X0 Y1 Z2:3 E4:5 ; set drive mapping;M566 X900.00 Y900.00 Z60.00 E120.00:120.00 ; set maximum instantaneous speed changes (mm/min)
;M203 X500.00 Y500.00 Z180.00 E1200.00:1200.00 ; set maximum speeds (mm/min)
;M201 X69000.00 Y69000.00 Z20.00 E250.00:250 ; set accelerations (mm/s^2);Setting motor currents
;M584 X0 Y1 Z2:3 E4:5 ; set drive mapping
;M906 X400 Y800 Z800 E800:800 I30 ; set motor currents (mA) and motor idle factor in per cent -
@jason0607 Yeah better, you will need to maybe adjust some of your settings but that should work.
You have commented out you Tool settings.
-
@Rushmere3D
Now the motor is just as loud but moves slower -
@jason0607 Are the phases of the stepper motors connected correctly?
Is this a new build?
Your config has multiple M584 commands make sure you have the correct one in use. -
@jason0607 Yes they are connected correctly
-
@jason0607 I would say these settings need, tweaking.
M566 X900.00 Y900.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X1000.00 Y1000.00 Z180.00 E1200.00 ; set maximum speeds (mm/min) M201 X200.00 Y200.00 Z20.00 E250.00 ; set accelerations (mm/s^2)
Something like this maybe? BUT you need to adjust based on your machine, these are based on one of my printers.
M566 X300.00 Y300.00 Z60.00 E420.00 ; set maximum instantaneous speed changes (mm/min) M203 X18000.00 Y18000.00 Z360.00 E1500.00 ; set maximum speeds (mm/min) M201 X3000.00 Y3000.00 Z300.00 E10000.00 ; set accelerations (mm/s^2)
-
Would also be a good idea to share the results of m122 and M98 P"config.g" please?
-
@rushmere3d
=== Diagnostics ===
RepRapFirmware for Duet 3 Mini 5+ version 3.4.1 (2022-06-01 21:06:56) running on Duet 3 Mini5plus Ethernet (standalone mode)
Board ID: 0KSJD-0296U-D65J0-40KMS-K803Z-H4BUF
Used output buffers: 3 of 40 (14 max)
=== RTOS ===
Static ram: 103684
Dynamic ram: 104352 of which 100 recycled
Never used RAM 33504, free system stack 182 words
Tasks: NETWORK(ready,25.6%,244) ETHERNET(notifyWait,0.2%,576) HEAT(notifyWait,0.0%,374) Move(notifyWait,0.0%,290) CanReceiv(notifyWait,0.0%,942) CanSender(notifyWait,0.0%,372) CanClock(delaying,0.0%,339) TMC(notifyWait,0.7%,81) MAIN(running,71.8%,510) IDLE(ready,1.0%,29) AIN(delaying,0.8%,264), total 100.0%
Owned mutexes:
=== Platform ===
Last reset 00:00:56 ago, cause: software
Last software reset at 2022-08-16 09:30, reason: User, GCodes spinning, available RAM 33520, slot 1
Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x00000000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a
Error status: 0x00
MCU revision 3, ADC conversions started 56285, completed 56285, timed out 0, errs 0
Step timer max interval 1487
MCU temperature: min 23.9, current 24.8, max 24.8
Supply voltage: min 24.0, current 24.0, max 24.0, under voltage events: 0, over voltage events: 0, power good: yes
Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0
Events: 2 queued, 2 completed
Driver 0: standstill, SG min 0, read errors 0, write errors 1, ifcnt 21, reads 2937, writes 11, timeouts 0, DMA errors 0, CC errors 0
Driver 1: standstill, SG min 0, read errors 0, write errors 1, ifcnt 27, reads 2935, writes 13, timeouts 0, DMA errors 0, CC errors 0
Driver 2: standstill, SG min 0, read errors 0, write errors 1, ifcnt 27, reads 2934, writes 13, timeouts 0, DMA errors 0, CC errors 0
Driver 3: standstill, SG min 0, read errors 0, write errors 1, ifcnt 21, reads 2936, writes 11, timeouts 0, DMA errors 0, CC errors 0
Driver 4: standstill, SG min 0, read errors 0, write errors 1, ifcnt 19, reads 2939, writes 9, timeouts 0, DMA errors 0, CC errors 0
Driver 5: not present
Driver 6: not present
Date/time: 2022-08-16 09:31:34
Cache data hit count 97077235
Slowest loop: 299.88ms; fastest: 0.13ms
=== Storage ===
Free file entries: 10
SD card 0 detected, interface speed: 22.5MBytes/sec
SD card longest read time 3.4ms, write time 11.7ms, max retries 0
=== Move ===
DMs created 83, segments created 3, maxWait 40644ms, bed compensation in use: none, comp offset 0.000
=== MainDDARing ===
Scheduled moves 6, completed 6, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 1], CDDA state -1
=== AuxDDARing ===
Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1
=== Heat ===
Bed heaters 0 -1 -1 -1, chamber heaters -1 -1 -1 -1, ordering errs 0
=== GCodes ===
Segments left: 0
Movement lock held by null
HTTP is idle in state(s) 0
Telnet is idle in state(s) 0
File is idle in state(s) 0
USB is idle in state(s) 0
Aux is idle in state(s) 0
Trigger is idle in state(s) 0
Queue is idle in state(s) 0
LCD is idle in state(s) 0
SBC is idle in state(s) 0
Daemon is idle in state(s) 0
Aux2 is idle in state(s) 0
Autopause is idle in state(s) 0
Code queue is empty
=== CAN ===
Messages queued 282, received 0, lost 0, boc 0
Longest wait 0ms for reply type 0, peak Tx sync delay 0, free buffers 18 (min 18), ts 282/0/0
Tx timeouts 0,0,281,0,0,0 last cancelled message type 30 dest 127
=== Network ===
Slowest loop: 101.62ms; fastest: 0.03ms
Responder states: HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) Telnet(0), 0 sessions
HTTP sessions: 1 of 8- Ethernet -
State: active
Error counts: 0 0 0 0 0
Socket states: 5 2 2 2 2 0 0 0
- Ethernet -
-
@rushmere3d Error: M98: control character in string
-
M98 P"config.g"
Didn't work?
I'm out of ideas if your still having issues I'm sorry to say.
-
@Rushmere3D What would be the settings for my motor?
-
@rushmere3d M98 P"config.g"
HTTP is enabled on port 80
FTP is disabled
TELNET is disabled
Error: Failed to initialise thermocouple: bad response from sensor
Warning: Sensor number 0 has not been defined -
@jason0607 You mean in relation to the settings I posted? It's totally dependent on your setup, what printer is it?
-
@rushmere3d I only have a Duet3Mini5+ Ethernet Board and the steppermotor 103-H5210-4240 / NEMA17 / Flansch 42mm / 1A / 51 Ncm
-
@jason0607 So are you saying this is just setup on a bench? It's not an actual printer?
-
@rushmere3d Yes
-
@jason0607 I can't really help then, I'm not sure I understand what issue you are having.
What are you trying to achieve? What command are you sending to make the motor move?
-
@jason0607 Your motors are quite high resistance at 4.8ohms and high inductance at 9.5mH. It may not be possible to drive them very fast, though they should have a good amount of torque. See https://docs.duet3d.com/User_manual/Connecting_hardware/Motors_choosing#inductance
The high resistance/inductance may be contributing to 'coil whine', which is what I expect you mean by your motor 'crying'. Do they do this all the time, when moving and when stationary, once powered up? Does the movement seem smooth when it moves? Are you just testing one axis, if so which, or are they all doing it?
The drivers on the Mini 5+ can run in stealthChop mode, as opposed to spreadCycle. stealthChop is a quiet mode of operation for stepper motors at standstill and at low velocities, while spreadCycle will give better performance in medium to high velocity range for motors. Send
M569 P0.0
to show how the X axis is set. To run in stealthchop all the time, change the M569 commands in config.g to:M569 P0.0 S1 D3 V0 ; physical drive 0.0 goes forwards M569 P0.1 S1 D3 V0 ; physical drive 0.1 goes forwards M569 P0.2 S1 D3 V0 ; physical drive 0.2 goes forwards M569 P0.3 S1 D3 V0 ; physical drive 0.3 goes forwards
Ian
-
@droftarts
What are normal values? I can only move my stepper motor up to about 15mm/s. -
@jason0607 In the config.g you posted earlier, you have:
M203 X1000.00 Y1000.00 Z180.00 E1200.00 ; set maximum speeds (mm/min)
1000mm/min = 16.666mm/s. Try increasing the M203 values of X and Y. 6000mm/min = 100mm/s, 12000mm/min = 200mm/s etc.
Did you manage to resolve the stepper motor whine/crying?
Ian