Homing issues



  • Hello.

    I’m in the middle of a process updating my Replicator 1 clone to Duet Wifi electronics. I was able to make everything working according to wiki instructions but now I in struggling with one problem I’m not really understand That problem a printer homing I did set all settings according to wiki but somehow it not working. I have relatively good success to homing my Z axis using microswitch Z probe I made. Problem are X and Y axis instead of going 240mm set in gcode they move to about 2.4 mm and set home there. Only solution to home my printer at the moment is that I have to move my carriage very close to X and Y endstops and then it working. But is not acceptable solution for working conditions so I would like to ask for advice how I can solve this problem.

    This my homex.g and homez.g settings

    [[language]]
    ; X axis homing file for dc42 Duet firmware
    G91                ; relative mode
    G1 Z4 F200         ; raise head to avoid dragging nozzle over the bed
    G1 X-240 F3000 S1  ; move up to 240mm in the -X direction, stopping if the homing switch is triggered
    G1 X4 F600         ; move slowly 4mm in the +X direction
    G1 X-10 S1         ; move slowly 10mm in the -X direction, stopping at the homing switch
    G1 Z-4 F200        ; lower the head again
    G90                ; back to absolute mode
    
    
    [[language]]
    G91                ; relative mode
    G1 Z4 F200         ; raise head 4mm to ensure it is above the Z probe trigger height
    G90                ; back to absolute mode
    G1 X-100 Y-100 F2000 ; put head over the centre of the bed, or wherever you want to probe
    G30                ; lower head, stop when probe triggered and set Z to trigger height
    G1 Z4 F200         ; lower the head again
    
    

  • administrators

    My guess is that the way you have the X and Y microswitches configured combined with the M574 command in config.g means that the microswitches are showing as triggered when they should not b, and voice versa. Use M119 or the Settings page in DuetWebControl to check. Are you using the normally-open or normally-closed contacts (normally closed is best), and what is your M574 line in config.g?

    The endstop LEDs on the Duet light when the microswitches are closed. So if you use the NC conrtacts, they will be on when the endstop switch is not triggered.



  • Thank you for replay. Here is output from M119 command

    [[language]]
    M119
    Endstops - X: at min stop, Y: at min stop, Z: not stopped, Z probe: not stopped
    
    ```I’m using Makerbot Mechanical Endstop v1.2\. I swapped two outer most pins to make them work. When I connected them at first time they didn’t worked as intended as they caused duet board to reset when I activated them.
    As I see from my experience they activated properly when I move X and Y carriage close to then and home them.
    I guess they work as normally-open switches because led not go on on duet board until I press them. On the other side z probe switch acts opposite and have led light on all the time until I press it so I guess it normally closed swtch
    I’m a bit puzzled in what going wrong so I post all my config.g file to be sure
    
    

    [[language]]
    ; R1 Custom (Ormerod 2 as base) config file for dc42 Duet firmware

    ; General preferences - Prologue and communications section
    M111 S0 ; Debug off
    M550 PR1 Custom ; Machine name (can be anything you like)
    M555 P2 ; Set output to look like Marlin

    ; Network
    M551 Preprap ; Machine password (currently not used)
    M552 S1 ; Enable WiFi
    M552 P0.0.0.0 S1 ; Enable network and acquire dynamic address via DHCP

    ; Drives - Movement section
    M569 P0 S1 ; Drive 0 goes forwards
    M569 P1 S1 ; Drive 1 goes forwards
    M569 P2 S1 ; Drive 2 goes forwards
    M569 P3 S0 ; Drive 3 goes backwards
    M350 X16 X16 X16 X16 I0 ; Configure microstepping without interpolation
    ;M350 X32 X32 X32 X32 I0 ; Configure microstepping without interpolation
    ;M92 X96.275 Y96.275 Z400 E96.275 ; Set steps per mm
    M92 X80.00 Y80.00 Z400 E80.00 ; Set steps per mm
    M906 X800 Y800 Z800 E800 I30 ; Set motor currents (mA) and motor idle factor in per cent
    M201 X500 Y20 Z250 E250 ; Set accelerations (mm/s^2)
    M203 X15000 Y15000 Z100 E3600 ; Maximum speeds (mm/min)
    M566 X600 Y600 Z30 E20 ; Maximum jerk speeds mm/minute
    M208 X200 Y200 Z200 S0 ; set axis maxima and high homing switch positions (adjust to suit your machine)
    M208 X-8 Y0 Z-0.5 S1 ; set axis minima and low homing switch positions (adjust to make X=0 and Y=0 the edges of the bed)
    G21 ; Work in millimetres
    G90 ; Send absolute coordinates...
    M83 ; ...but relative extruder moves

    ; Endstops
    M574 X1 Y1 Z0 S1 ; Define active high microswitches

    ; Z probe section
    M558 P4 X0 Y0 Z1 H5 F120 T6000 ; Z probe microswitch (normally-closed by default) connected to the E0 endstop connector on Z axes + travel speeds
    G31 P500 X80 Y0 Z0.1 ; Set Z probe trigger value, offset and trigger height

    ; Heaters - Heater and thermistor section
    M305 P1 X100 ; tells the firmware that for heater 1 it should sense the temperature using the thermocouple board whose CS pin is connected to NPCS0
    M305 P0 R4700 T100000 B3950 ; set HBP thermistor parameters
    M307 H1 A542.7 C169.6 D7.9 B0 ; E3D 40W heater PID
    M307 H0 A118.9 C528.3 D7.3 B0 ; HBP heater PID
    M143 S290 ; Set maximum heater temperature to 290C
    M570 S150 ; Set maximum heating time to 150s

    ; Tools - Tool definition section
    M563 P0 D0 H1 ; tool 0 uses extruder drive 0 and heater 1
    G10 P0 S0 R0 X0 Y0 ; set tool 0 temperatures and offsets

    ; 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 T45 H1 ; This sets fan 1 to run any time the temperature of heater 1 is above 45 Celsius

    ; Epilogue
    M556 S100 X0 Y0 Z0 ; Put your axis compensation here
    T0 ; select first hot end


  • administrators

    Yes those endsop boards have active low outputs. Replace your M574 line in config.g by these two lines:

    M574 X1 Y1 S0
    M574 Z0 S1



  • Yes that S0 parameter on M574 solved it. I were able to successfully home all axis now. On duet wiki itw been stated that I have to use S2 argument for M574 for active low inputs though. https://duet3d.com/wiki/Configuring_RepRapFirmware_for_a_Cartesian_printer#Movement_section
    So I checked G-code page on reprap wiki and found that I have to use S0 argument
    http://reprap.org/wiki/G-code#M574:_Set_endstop_configuration
    Perhaps something not very clear with wiki I don’t know.
    Thank you for assistance I was able to solve this problem.


  • administrators

    I've corrected the entry in the Duet WiFi wiki page - thanks for pointing out the error.



  • You’re welcome I’m glad I was able to help.


Locked
 

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