Welcome! Log In Create A New Profile

Advanced

RepRap Firmware 1.19 - Custom Axis Homing

Posted by TheHackerArtist 
RepRap Firmware 1.19 - Custom Axis Homing
November 20, 2018 10:58AM
I am currently designing and building a multi-material extrusion system that uses a single nozzle and switches the filament automatically.

The system was inspired by the new MMU 2.0 by Joseph Prusa. My design goals were to make everything controlled from the same board that currently powers my 3D printer, the Duet WiFi and to reduce the part count as much as possible.

What I need help with at the moment is in homing an additional axis I setup, axis 'U' that I index to engage the right material to be extruded through a lead screw connected to a stepper. the U axis is actuated through the E1 stepper driver.

I can't figure out what G-Code command to issue in order to assign an endstop, say X max, in order to home. I don't think I'm using M208 properly. I only use Xmin, Ymin and a probe for the Z axis so there's a bunch of endstop sockets physically available on the board.

Thank you.

HERE IS THE FIRMWARE CONFIG.G

; General preferences
G90                                       ; Send absolute coordinates...
M83                                       ; ...but relative extruder moves

; Network
M550 PArmand                              ; 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

; Drives
M569 P0 S1                                ; Drive 0 goes forwards
M569 P1 S1                                ; Drive 1 goes forwards
M569 P2 S1                                ; Drive 2 goes forwards
M569 P3 S1 
M584 X0 Y1 Z2 E3 U4                               ; Drive 3 goes forwards
M350 Z64 I0                               ; Configure microstepping without interpolation
M350 X16 Y16 E16 U16 I1                     ; Configure microstepping with interpolation
M92 X115.4139 Y115.1649 Z458.3991835 E407 U1600 ; Set steps per mm
M566 X480 Y480 Z10 E240 U10          ; Set maximum instantaneous speed changes (mm/min)
M203 X9000 Y9000 Z600 E1500 U600      ; Set maximum speeds (mm/min)
M201 X2000 Y2000 Z100 E500 U100       ; Set accelerations (mm/s^2)
M906 X1900 Y1900 Z1900 E1000 U1200 I98  ; Set motor currents (mA) and motor idle factor in per cent
M84 S6000                                 ; Set idle timeout

; Axis Limits
M208 X0 Y0 Z0 U0 S1                  ; Set axis minima
M208 X380 Y260 Z325 U100 S0          ; Set axis maxima

; Endstops
M574 X1 Y1 U1 S0                          ; Set active low endstops

; Z-Probe
M558 P5 H0 F120 T6000                     ; Set Z probe type to switch and the dive height + speeds
G31 P600 X0 Y0 Z0                         ; Set Z probe trigger value, offset and trigger height
M556 S150 X1.4 Y0 Z0                      ; Set orthogonal axis compensation parameters
M557 X15:375 Y15:245 S20                  ; Define mesh grid

; Heaters
M305 P0 T100000 B4138 C0 R4700            ; Set thermistor + ADC parameters for heater 0
M143 H0 S155                              ; Set temperature limit for heater 0 to 155C
M305 P1 X150                              ; Configure thermocouple for heater 1
M143 H1 S280                              ; Set temperature limit for heater 1 to 280C
M141 H3							  ; Set heater channel for heated cahmber
M305 P3 X151						;Set thermocouple readout for chamber temperature

; Fans
M106 P0 S1 I0 F25000 H-1                  ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P1 S1 I0 F25000 H-1                  ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P2 S1 I0 F25000 H-1                  ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

; 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

; Custom settings are not configured

Edited 1 time(s). Last edit at 11/20/2018 10:59AM by TheHackerArtist.
Re: RepRap Firmware 1.19 - Custom Axis Homing
November 20, 2018 03:04PM
Currently the endstop-to-axis assignments are fixed. Endstop inputs 0,1,2 (labelled X,Y,Z on the Duet) are used for the X, Y and Z axes. Endstop input 3 (labelled E0) will be used for the next axis you create (e.g. your U axis), endstop input 4 (E1) for the axis after that, and so on.

Edited 1 time(s). Last edit at 11/20/2018 03:05PM by dc42.



Large delta printer [miscsolutions.wordpress.com], E3D tool changer, Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: RepRap Firmware 1.19 - Custom Axis Homing
November 20, 2018 10:28PM
Hi dc42,

Thank you for your response! I'll give it a try tomorrow and update you
Re: RepRap Firmware 1.19 - Custom Axis Homing
November 23, 2018 11:46AM
-------EDIT!!-------

PROBLEM FIXED

------------------------

It worked! thank you.

I've assembled everything mechanical-wise and it's working. Now just working out the software aspect.

I implemented 6 tools corresponding to 6 different filaments.

All of the tool use the same drive and the same heater because its the same extruder. tpre[0-5].g files execute a series of G code command controlling the U axis and the E axis in order to switch the filament.

The firmware seems to not like this and does let me set the tool head "active". The moment I issue a temperature command to T0, all tools are shut off, including T0.

Why could that be and what should be changed?


; Drives
M569 P0 S1                                ; Drive 0 goes forwards
M569 P1 S1                                ; Drive 1 goes forwards
M569 P2 S1                                ; Drive 2 goes forwards
M569 P3 S1								  ; Drive 3 goes forwards
M569 P4 S1 								  ; Drive 4 goes forwards
M584 X0 Y1 E2 Z3 U4                       ;        
M350 Z64 I0                               ; Configure microstepping without interpolation
M350 X16 Y16 E16 U16 I1                   ; Configure microstepping with interpolation
M92 X115.4139 Y115.1649 Z458.3991835 E407 U1600 ; Set steps per mm
M566 X480 Y480 Z10 E240 U10               ; Set maximum instantaneous speed changes (mm/min)
M203 X9000 Y9000 Z600 E1500 U600          ; Set maximum speeds (mm/min)
M201 X2000 Y2000 Z100 E500 U100           ; Set accelerations (mm/s^2)
M906 X1900 Y1900 Z1900 E1000 U1000 I98    ; Set motor currents (mA) and motor idle factor in per cent
M84 S6000                                 ; Set idle timeout

; Axis Limits
M208 X0 Y0 Z0 U0 S1                       ; Set axis minima
M208 X380 Y260 Z325 U100 S0               ; Set axis maxima

; Endstops
M574 X1 Y1 U1 S0                             ; Set active low endstops

; Z-Probe 
M558 P5 H0 F120 T6000                     ; Set Z probe type to switch and the dive height + speeds
G31 P600 X0 Y0 Z0                         ; Set Z probe trigger value, offset and trigger height
M556 S150 X1.4 Y0 Z0                      ; Set orthogonal axis compensation parameters
M557 X15:375 Y15:245 S20                  ; Define mesh grid

; Heaters
M305 P0 T100000 B4138 C0 R4700            ; Set thermistor + ADC parameters for heater 0
M143 H0 S155                              ; Set temperature limit for heater 0 to 155C
M305 P1 X150                              ; Configure thermocouple for heater 1
M143 H1 S280                              ; Set temperature limit for heater 1 to 280C
M141 H3							          ; Set heater channel for heated cahmber
M305 P3 X151						      ; Set thermocouple readout for chamber temperature

; Fans
M106 P0 S1 I0 F25000 H-1                  ; Set fan 0 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P1 S1 I0 F25000 H-1                  ; Set fan 1 value, PWM signal inversion and frequency. Thermostatic control is turned off
M106 P2 S1 I0 F25000 H-1                  ; Set fan 2 value, PWM signal inversion and frequency. Thermostatic control is turned off

; Tools
;;Tool 1
M563 P0 D0 H1 S"WHITE PLA"                            ; 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
;;Tool 2
M563 P1 D0 H1 S"BLACK PLA"                            ; Define tool 1
G10 P0 X0 Y0 Z0                           ; Set tool 1 axis offsets
G10 P0 R0 S0                              ; Set initial tool 1 active and standby temperatures to 0C
;;Tool 3	
M563 P2 D0 H1 S"WHITE PETG"                            ; Define tool 2
G10 P0 X0 Y0 Z0                           ; Set tool 2 axis offsets
G10 P0 R0 S0                              ; Set initial tool 2 active and standby temperatures to 0C
;;Tool 4
M563 P3 D0 H1 S"BLACK PETG"                           ; Define tool 3
G10 P0 X0 Y0 Z0                           ; Set tool 3 axis offsets
G10 P0 R0 S0                              ; Set initial tool 3 active and standby temperatures to 0C
;;Tool 5
M563 P4 D0 H1 S"PVA SUPPORT"                           ; Define tool 4
G10 P0 X0 Y0 Z0                           ; Set tool 4 axis offsets
G10 P0 R0 S0                              ; Set initial tool 4 active and standby temperatures to 0C
;;Tool 6
M563 P5 D0 H1 S"CUSTOM MATERIAL"                          ; Define tool 5
G10 P0 X0 Y0 Z0                           ; Set tool 5 axis offsets
G10 P0 R0 S0                              ; Set initial tool 5 active and standby temperatures to 0C






Edited 1 time(s). Last edit at 11/23/2018 12:37PM by TheHackerArtist.
Re: RepRap Firmware 1.19 - Custom Axis Homing
November 23, 2018 12:38PM
The issue was caused by the heater 1 wires shorting. This would trigger the board to reset every time I activated a tool. Will continue testing now that software is ready to go.
Sorry, only registered users may post in this forum.

Click here to login