Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pin Mapping for Klipper #239

Open
cmoneyspruce opened this issue Sep 6, 2024 · 1 comment
Open

Pin Mapping for Klipper #239

cmoneyspruce opened this issue Sep 6, 2024 · 1 comment

Comments

@cmoneyspruce
Copy link

cmoneyspruce commented Sep 6, 2024

I have been trying to write a klipper config for the Sigma R19 and got this working partially.

Some things I need to know are sensor types etc. so that I can run a calibration and get this up and running on klip.

`
[include mainsail.cfg]
[pause_resume]
[display_status]
[virtual_sdcard]
path: ~/printer_data/gcodes
[respond]
default_type: echo

[board_pins arduino-mega]
aliases:
ar0=PE0, ar1=PE1, ar2=PE4, ar3=PE5, ar4=PG5,
ar5=PE3, ar6=PH3, ar7=PH4, ar8=PH5, ar9=PH6,
ar10=PB4, ar11=PB5, ar12=PB6, ar13=PB7, ar14=PJ1,
ar15=PJ0, ar16=PH1, ar17=PH0, ar18=PD3, ar19=PD2,
ar20=PD1, ar21=PD0, ar22=PA0, ar23=PA1, ar24=PA2,
ar25=PA3, ar26=PA4, ar27=PA5, ar28=PA6, ar29=PA7,
ar30=PC7, ar31=PC6, ar32=PC5, ar33=PC4, ar34=PC3,
ar35=PC2, ar36=PC1, ar37=PC0, ar38=PD7, ar39=PG2,
ar40=PG1, ar41=PG0, ar42=PL7, ar43=PL6, ar44=PL5,
ar45=PL4, ar46=PL3, ar47=PL2, ar48=PL1, ar49=PL0,
ar50=PB3, ar51=PB2, ar52=PB1, ar53=PB0, ar54=PF0,
ar55=PF1, ar56=PF2, ar57=PF3, ar58=PF4, ar59=PF5,
ar60=PF6, ar61=PF7, ar62=PK0, ar63=PK1, ar64=PK2,
ar65=PK3, ar66=PK4, ar67=PK5, ar68=PK6, ar69=PK7,
analog0=PF0, analog1=PF1, analog2=PF2, analog3=PF3, analog4=PF4,
analog5=PF5, analog6=PF6, analog7=PF7, analog8=PK0, analog9=PK1,
analog10=PK2, analog11=PK3, analog12=PK4, analog13=PK5, analog14=PK6,
analog15=PK7,
ml70=PG4, ml71=PG3, ml72=PJ2, ml73=PJ3, ml74=PJ7,
ml75=PJ4, ml76=PJ5, ml77=PJ6, ml78=PE2, ml79=PE6,
ml80=PE7, ml81=PD4, ml82=PD5, ml83=PD6, ml84=PH2,
ml85=PH7

[mcu]
serial: /dev/serial/by-id/usb-FTDI_FT232R_USB_UART_AL0224HE-if00-port0
baud: 250000

[printer]
kinematics: cartesian
max_velocity: 300
max_accel: 2900
max_z_velocity: 20
max_z_accel: 50

[stepper_x]
step_pin: ml73 # PJ3
dir_pin: !ml76 # PJ5
enable_pin: !ml75 # PJ4
microsteps: 16
rotation_distance: 40
endstop_pin: !ml77 # PJ6
position_min: 0 # X_MIN_POS = 0
position_max: 305.6
position_endstop: 0 # Add this to specify the position of the endstop
homing_positive_dir: false
homing_speed: 10
homing_retract_dist: 10 # Slight retract after hitting endstop

[extruder]
step_pin: ar29 # PA7
dir_pin: ar27 # PA5
enable_pin: ar28 # PA6
microsteps: 16
rotation_distance: 32.500
nozzle_diameter: 0.400
filament_diameter: 2.85
pressure_advance: 0.1
heater_pin: ar44 # PL5
sensor_type: EPCOS 100K B57560G104F
sensor_pin: ar63 #PK1
control: pid
pid_kp: 15.16
pid_ki: 1.16
pid_kd: 49.38
min_temp: 10
max_temp: 315

[fan_generic extruder0_partfan]
#controls left extruder part cooling fan
pin: ar45 # PL4 mapped to ar45 (Fan 1 for Toolhead 1)
kick_start_time: 1.0 # Start fan at full speed for 1 second to ensure it spins
off_below: 0.1 # Fan will turn off when the speed is below 10%
max_power: 1.0 # Maximum fan power at 100%

[dual_carriage]
axis: x
step_pin: ar5 # PE3
dir_pin: !ar3 # PE5
enable_pin: !ar2 # PE4
microsteps: 16
rotation_distance: 40
full_steps_per_rotation: 200
endstop_pin: !ml79 # PE6
position_endstop: 210
position_max: 210
homing_positive_dir: true
homing_speed: 10

[extruder1]
step_pin: ar57 # PF3
dir_pin: ar55 # PF1 Consider reversing pin with !
enable_pin: ar56 # PF2
microsteps: 16
rotation_distance: 32.500
nozzle_diameter: 0.400
filament_diameter: 2.85
pressure_advance: 0.1
heater_pin: ar7 # PH4
sensor_type: EPCOS 100K B57560G104F
sensor_pin: ar62 #PK0
control: pid
pid_kp: 15.16
pid_ki: 1.16
pid_kd: 49.38
min_temp: 10
max_temp: 315

[fan_generic extruder1_partfan]
#controls left extruder part cooling fan
pin: ar6 # PH3 mapped to ar6 (Fan 2 for Toolhead 2)
kick_start_time: 1.0 # Start fan at full speed for 1 second to ensure it spins
off_below: 0.1 # Fan will turn off when the speed is below 10%
max_power: 1.0 # Maximum fan power at 100%

[stepper_y]
step_pin: ar30 # PC7
dir_pin: !ar32 # PC5
enable_pin: !ar31 # PC6
microsteps: 16
rotation_distance: 40
full_steps_per_rotation: 200
endstop_pin: !ar33 # PC4
position_endstop: 0 # The position where the endstop is triggered
position_max: 295 # Max Y-axis travel distance
homing_speed: 10
homing_retract_dist: 5 # Distance to retract after homing

[stepper_z]
step_pin: ar25 # PA3
dir_pin: !ar23 # PA1
enable_pin: !ar24 # PA6
microsteps: 16
rotation_distance: 4
full_steps_per_rotation: 200
endstop_pin: !ar34 # PC3
position_min: 0 # Z_MIN_POS = 0
position_max: 210 # Z_MAX_POS = 210
position_endstop: 0 # Set this to the minimum position where the endstop is located
homing_speed: 15 # Increasing this might lead to missing steps
homing_retract_dist: 10 # Slight retract after hitting endstop

[heater_bed]
heater_pin: ar46 #PL3
sensor_type: EPCOS 100K B57560G104F
sensor_pin: ar69 #PK7
min_temp: 10
max_temp: 110
control: pid
pid_kp: 218.76
pid_ki: 38.70
pid_kd: 321.59

[output_pin rgb_red]
pin: ar12 # Pin PB6 mapped to R (Red)
pwm: True
scale: 255
shutdown_value: 0

[output_pin rgb_green]
pin: ar11 # Pin PB5 mapped to G (Green)
pwm: True
scale: 255
shutdown_value: 0

[output_pin rgb_blue]
pin: ar13 # Pin PB7 mapped to B (Blue)
pwm: True
scale: 255
shutdown_value: 0

[gcode_macro SET_RGB]
gcode:
SET_PIN PIN=rgb_red VALUE={params.R|default(0.0)}
SET_PIN PIN=rgb_green VALUE={params.G|default(0.0)}
SET_PIN PIN=rgb_blue VALUE={params.B|default(0.0)}

[gcode_macro RGB_OFF]
gcode:
SET_RGB R=0.0 G=0.0 B=0.0

[homing_override]
gcode:
G90 # Absolute positioning
G1 Z10 F600 # Raise Z to avoid collision
G28 X Y # Home X and Y
G1 X58 Y150 F6000 # Move to Z homing point (58, 150 as per Z_SIGMA_HOME_X_POINT and Z_SIGMA_HOME_Y_POINT)
G28 Z # Home Z
G1 Z5 F600 # Retract slightly after homing Z
set_position_z: 0.0

[stepper_z]
step_pin: ar25 # PA3
dir_pin: !ar23 # PA1
enable_pin: ar28 # PA6
microsteps: 16
rotation_distance: 4
endstop_pin: ^!ar34 # PC3
position_min: 0 # Z_MIN_POS = 0
position_max: 210 # Z_MAX_POS = 210
position_endstop: 0 # The minimum position where the endstop is located
homing_speed: 13000 # SIGMA_Z_HOME_TRAVEL_SPEED
homing_retract_dist: 5 # Z_SIGMA_RAISE_AFTER_HOMING

[bed_mesh]
speed: 4000 # XY_SIGMA_TRAVEL_SPEED (adjusted for the board type)
horizontal_move_z: 10 # Move Z up before probing
mesh_min: 55, 10 # Define minimum X and Y mesh point (X_SIGMA_PROBE points)
mesh_max: 254, 265 # Define maximum X and Y mesh point (X_SIGMA_PROBE points)
probe_count: 3, 3 # Number of points to probe along X and Y
mesh_pps: 2, 2 # Points per segment for mesh generation
fade_start: 1 # Start fading the mesh after Z=1mm
fade_end: 10 # Stop fading the mesh at Z=10mm

[probe]
pin: ar10 # Adjust depending on the actual probe pin
z_offset: 2.8 # Z_SIGMA_PROBE_OFFSET_FROM_EXTRUDER
speed: 5 # Probing speed
samples: 1 # Number of probe attempts

#[display]
#lcd_type: some_lcd_model # Replace with actual LCD model (e.g., st7920, hd44780, etc.)
#rs_pin: ar17 # TX pin (PH0)
#enable_pin: ar16 # RX pin (PH1)
#lcd_reset_pin: ar9 # PH6 mapped to ar47

#[sd_card]
#cs_pin: ar19 # SDSS pin 19
#sclk_pin: ar20 # SCLK pin 20
#mosi_pin: ar21 # MOSI pin 21
#miso_pin: ar22 # MISO pin 22

#????: ar10 (PB4)

[force_move]
enable_force_move: True
'

@toas11
Copy link

toas11 commented Nov 7, 2024

Hi, did you succced to run a full Klipper config on the arduino mega for the sigma R19? i'm really interesed to put Klipper on my old sigmaX.
Tks you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants