Setting up DUET wifi + Duex5 - help needed



  • Hi

    I am at long last starting the setup of my custom build IDEX machine. I have two motors controlling the y axis (my plan is that the machine could one day also be used for lite wood machining so a motor at each end of the 'gantry' I though necessary. I have connected the DUET to my wireless network successfully and am now trying to make the motors move. This is where I need some help. Initially I used the standard drive numbers for the X, Y and Z and I was able to move X and Y. However I read somewhere that both Y motors should be connected to the same controller board so reconnected the Y axis motors to the Duex5. (at this stage I am not too worried about the second X axis, I will move onto that once the first axis etc is working! I also have PT100 sensors reading 2000 degrees but again, little steps)

    I have posted up a snippet from the first bit of the config file, but now nothing seems to work. The M115 shows the duex is connected though which is good

    ; Configuration file for Duet WiFi (firmware version 1.20 or newer)
    ; executed by the firmware on start-up
    ;
    ; generated by RepRapFirmware Configuration Tool on Mon Jan 01 2018 19:47:24 GMT+0000 (GMT Standard Time)

    ; General preferences
    M111 S0 ; Debugging off
    G21 ; Work in millimetres
    G90 ; Send absolute coordinates…
    M83 ; ...but relative extruder moves
    M555 P2 ; Set firmware compatibility to look like Marlin
    M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; Configure automatic saving on power loss
    M208 X0 Y0 Z0 S1 ; Set axis minima
    M208 X400 Y350 Z400 S0 ; Set axis maxima

    ; Endstops
    M574 X1 Y2 S1 ; Set active high endstops
    M574 Z1 S2 ; Set endstops controlled by probe
    M558 P1 H5 F120 T6000 ; Set Z probe type to unmodulated and the dive height + speeds
    G31 P500 X0 Y0 Z2.5 ; Set Z probe trigger value, offset and trigger height
    M557 X15:385 Y15:335 S20 ; Define mesh grid

    ; Drives
    M569 P0 S1 ; Drive 0 goes forwards
    M569 P2 S1 ; Drive 2 goes forwards
    M569 P3 S1 ; Drive 3 goes forwards
    M569 P4 S1 ; Drive 4 goes forwards
    M569 P5 S1 ; Drive 5 goes forwards
    M569 P6 S1 ; Drive 6 goes forwards

    M584 X0 Y5:6 Z2 E3:4 ; New drive mapping

    If someone could help me I would be most appreciative!


  • administrators

    The two Y motors don't have to be on the same board, but they must either both be TMC2660 drivers on the Duet and/or DueX, or both be external drivers.

    Yout config.g file looks OK, assuming that the M906 command and M350 command (if you have one) comes later in the file. What isn't working? Is the DueX receiving VIN power?

    I suggest you post your whole config.g file.



  • @CTRDevelopments:

    I also have PT100 sensors reading 2000 degrees but again, little steps)

    PT100 seems to not be getting a response… check wiring?



  • Thasnk for the help. I will double check the wiring on the PT100's this evening. I also have a bed thermistor reading 120 degrees when it is about 10 though? Is there a common between all of them that I perhaps have not set?

    config file below

    ; Configuration file for Duet WiFi (firmware version 1.20 or newer)
    ; executed by the firmware on start-up
    ;
    ; generated by RepRapFirmware Configuration Tool on Mon Jan 01 2018 19:47:24 GMT+0000 (GMT Standard Time)

    ; General preferences
    M111 S0 ; Debugging off
    G21 ; Work in millimetres
    G90 ; Send absolute coordinates…
    M83 ; ...but relative extruder moves
    M555 P2 ; Set firmware compatibility to look like Marlin
    M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; Configure automatic saving on power loss
    M208 X0 Y0 Z0 S1 ; Set axis minima
    M208 X400 Y350 Z400 S0 ; Set axis maxima

    ; Endstops
    M574 X1 Y2 S1 ; Set active high endstops
    M574 Z1 S2 ; Set endstops controlled by probe
    M558 P1 H5 F120 T6000 ; Set Z probe type to unmodulated and the dive height + speeds
    G31 P500 X0 Y0 Z2.5 ; Set Z probe trigger value, offset and trigger height
    M557 X15:385 Y15:335 S20 ; Define mesh grid

    ; Drives
    M569 P0 S1 ; Drive 0 goes forwards
    M569 P2 S1 ; Drive 2 goes forwards
    M569 P3 S1 ; Drive 3 goes forwards
    M569 P4 S1 ; Drive 4 goes forwards
    M569 P5 S1 ; Drive 5 goes forwards
    M569 P6 S1 ; Drive 6 goes forwards

    M584 X0 Y5:6 Z2 E3:4 ; New drive mapping

    M350 X16 Y16 Z16 E16 I1 ; Configure microstepping with interpolation
    M92 X320 Y320 Z3200 E420 ; Set steps per mm
    M566 X900 Y900 Z12 E120 ; Set maximum instantaneous speed changes (mm/min)
    M203 X6000 Y6000 Z180 E1200 ; Set maximum speeds (mm/min)
    M201 X500 Y20 Z250 E250 ; Set accelerations (mm/s^2)
    M906 X1000 Y1000 Z1000 E800 I30 ; Set motor currents (mA) and motor idle factor in per cent
    M84 S30 ; Set idle timeout

    ; Heaters
    M305 P0 T100000 B4138 C0 R4700 ; Set thermistor + ADC parameters for heater 0
    M143 H0 S120 ; Set temperature limit for heater 0 to 120C
    M305 P1 T100000 B4138 C0 R4700 X100 ; Set thermistor + ADC parameters for heater 1 and remap it to channel 100
    M143 H1 S280 ; Set temperature limit for heater 1 to 280C

    ; Tools
    M563 P0 D0 H1 ; 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

    ; Network
    M550 PCTR 3DPrintR ; Set machine name
    M552 S1 ; Enable network
    ;*** Access point is configured manually via M587
    M586 P0 S1 ; Enable HTTP
    M586 P1 S0 ; Disable FTP
    M586 P2 S0 ; Disable Telnet

    ; Fans
    M106 P0 S0.3 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
    M106 P2 S1 I0 F500 H1 T45 ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned on

    ; Custom settings are not configured

    Once again, many thanks


  • administrators

    Regarding the PT100, the X parameter in M305 P1 should be 200 for the first PT100. X100 is for a thermocouple.

    Regarding the bed temperature, what bed thermistor are you using?



  • 100k thermistor i think.

    How can i check the deux is getting power? it reports that it is there when i send the m115 command. thanks


  • administrators

    Run M122 and see what status it reports for the stepper drivers on the DueX.

    If you have a multimeter, I suggest you measure the resistance of your bed thermistor at room temperature, to check whether it really is a 100K thermistor.



  • OK, I had an issue with uploading the zip file and it was seemingly corrupting, hence nothing worked! I am using the editor in the web interface and have got axis movement 🙂 However I still have issues with the temps. The bed temp seems to read 124.8 (it wobbles a bit) when the temp should read say 10, and the PT100 still reads 2000. I have attched the ( I think) relevant bit of code

    ; Heaters
    M305 P0 T100000 B3950 C0 R4700 ; Set thermistor + ADC parameters for heater 0
    M143 H0 S120 ; Set temperature limit for heater 0 to 120C
    M305 P1 X200 ; Set thermistor + ADC parameters for heater 1 and remap it to channel 100
    M143 H1 S280 ; Set temperature limit for heater 1 to 280C

    Cheers


  • administrators

    1. Measure the bed thermistor resistance with a multimeter. Perhaps it isn't a 100k thermistor.

    For the PT100:

    2. Send the M305 P1 X200 from the command line and see if you get an error message back.

    3. Are you sure you have connected the PT100 to the first channel of the daughter board? If it is connected to the second channel, use X201 instead of X200 in the M305 command.

    4. If you are using a 2 wire connection to the PT100, do you have the 2 jumpers fitted on the daughter board?



  • OK, I have two working temps now. I had a bad connection on the PT100 daughterboard as well as the bed thermistor, both now sorted and working 🙂

    I have the IR bed level sensor from think3dprint3d. I was not sure of the sensor type on the config tool. What should this be? I dont want to crash the bed instantly!

    Presumably to add the second head I would add in

    M584 X0 U7 Y5:6 Z2 E3:4 ; New drive mapping
    M350 X16 U16 Y16 Z16 E16 I1 ; Configure microstepping with interpolation
    M92 X320 U320 Y320 Z3200 E420 ; Set steps per mm
    M566 X900 U900 Y900 Z12 E120 ; Set maximum instantaneous speed changes (mm/min)
    M203 X6000 U6000 Y6000 Z180 E1200 ; Set maximum speeds (mm/min)
    M201 X500 U500 Y20 Z250 E250 ; Set accelerations (mm/s^2)
    M906 X1000 U1000 Y1000 Z1000 E800 I30 ; Set motor currents (mA) and motor idle factor in per cent
    M569 P7 S0 ; Drive 6 goes backwards

    Can the U axis zero at the other end of the carriage (ie the X zero on the left and the U on the right)? I then presumably need to tell it the distance between the two to calibrate them together?

    At the moment I am using hall effect sensors for the end stops which seem to work but I think I read somewhere that you can do away with the sensors and wait for missed steps from the drivers? Is this now working?

    Cheers


  • administrators

    1. Select "Unmodulated or smart IR sensor" and set the trigger value to 500. See the commissioning instructions at https://miscsolutions.wordpress.com/mini-height-sensor-board/. Test the Z probe before you rely on it.

    2. You also need to declare the U endstop at the high end of the axis in M574, and the U axis limits in M208. Adjust the U upper limit to get the X and U nozzles to print at the same X position.

    3. Homing using motor stalling isn't very precise. Often this doesn't matter, but on an IDEX machine you need the distance between the X and U homing positions to be highly reproducible. So I suggest you use endstop switches.



  • DC, many thanks for the help. I think I am getting there (slowly but steadily). It will be a bit of a long burm as I am sure I will keep tweaking!

    Quick question. My z axis motors are rated at 2.1A per phase.

    https://www.omc-stepperonline.com/hybrid-stepper-motor/nema-17-bipolar-18deg-65ncm-92ozin-21a-336v-42x42x60mm-4-wires-17hs24-2104s.html?search=17hs24-2104s

    Do I therefore set M906 Z 2100 ? Just wanted to check before I blew them up!

    Also, when I zero the y axis it is actually 25mm off the front of the build plate. (If I move y to +25 it is actually at '0' on the build plate) How can I set this up as to be the zero point? I also have the same issue on the x axis?


  • administrators

    @CTRDevelopments:

    Quick question. My z axis motors are rated at 2.1A per phase.

    Do I therefore set M906 Z 2100 ? Just wanted to check before I blew them up!

    If you run them at full rated current, they will run very hot. 60% to 85% of rated current is usual.

    @CTRDevelopments:

    Also, when I zero the y axis it is actually 25mm off the front of the build plate. (If I move y to +25 it is actually at '0' on the build plate) How can I set this up as to be the zero point? I also have the same issue on the x axis?

    I am guessing that you have the Y endstop switch at the low end of the Y axis. In your M208 S1 command, change Y0 to Y-25. This command defines the lower axis limit, which is also the assumed position when a low-end endstop switch triggers during homing.



  • DC, yes, the y axis endstop is at the minimum - all working now 🙂

    I have set the current to 1750 and seems to work. Although I think I have a loose connection as sometimes one of the motors stops and then the platform jams up! I will chase it though

    Presumably to get the 'hardware' levelling using the z motors (https://www.duet3d.com/forum/thread.php?id=1203) I need to move the motors to be on independent motors drives rather than both on driver 2. I will have a crack tomorrow time permitting.

    Cheers



  • Yet more (sorry) question. I have a fan in the DUET housing to blow cold air at it when/if it gets hot. This is connected to fan 7 on the DUEX5. Is there a method of applying hysteresis to control it?

    on at 50degrees
    off at 40 degrees



  • If you put T40:50 in the M106 command, the firmware will try to control the fan with PWM between the range 40 and 50. So 39 will be off, 40 may start to turn slowly depending on how the fan reacts to PWM, 50 will be full on and 45 will be half on. This is how I have mine set and it works very well.

    Edit. Otherwise with a fixed temperate eg. T40, there is 1 degree of hysteresis. That is to say, the fan will start at 40 but the temperature must drop to 39 before he fan turns off.


  • administrators

    Not hysteresis, but you can set it to come on at e.g 30% at 40C rising to 100 at 50C:

    M106 P# L30 H100 T40:50

    where # is the fan number.



  • @dc42:

    Not hysteresis, but you can set it to come on at e.g 30% at 40C rising to 100 at 50C:

    M106 P# L30 H100 T40:50

    where # is the fan number.

    David,

    Unless things have changed, H is the heater number is it not? Just that your example in above, conjunction with the wording might indicate that H100 is the maximum speed.


  • administrators

    Yes H is the heater number. Heater 100 is the default virtual heater number for the CPU temperature.



  • Many thanks for the help. I have got most things working but have a mechanical issue on the z axis. I have redesigned and am printing (on a different print) the new parts and waiting for some others to arrive in the post! Cheers


Locked
 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.