rvdr

Fysetc F6 Trident Klipper Config

Jan 13th, 2025
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.69 KB | Source Code | 0 0
  1.  
  2. [virtual_sdcard]
  3. path: /home/pi/printer_data/gcodes
  4. #path: ~/gcode_files
  5.  
  6.  
  7. [pause_resume]
  8. [display_status]
  9.  
  10. [mcu]
  11. ###Change to device found by "ls -l /dev/serial/by-id/*" with just one this MCU connected to OPi
  12. serial: /dev/serial/by-id/usb-1a86_USB2.0-Serial-if00-port0
  13.  
  14. #[mcu adxl]
  15. #serial: /dev/serial/by-id/usb-Klipper_rp2040_65CC9C960E566E53-if00
  16.  
  17. #[adxl345]
  18. #cs_pin: adxl:gpio1
  19. #spi_bus: spi0a
  20. #axes_map: x,z,y
  21.  
  22. #[resonance_tester]
  23. #accel_chip: adxl345
  24. #probe_points:
  25. # Somewhere slightly above the middle of your print bed
  26. # 155,145, 15
  27.  
  28. [bltouch]
  29. sensor_pin: ^PB6
  30. control_pin: PE4
  31. x_offset: -47
  32. y_offset: -4
  33. z_offset: 1.92
  34.  
  35.  
  36. [safe_z_home]
  37. home_xy_position: 145,155 # Change coordinates to the center of your print bed
  38. z_hop: 10
  39.  
  40. [printer]
  41. kinematics: corexy
  42. max_velocity: 300
  43. max_accel: 1500
  44. max_z_velocity: 5
  45. max_z_accel: 100
  46. square_corner_velocity: 5.0
  47.  
  48. #####################################################################
  49. # X/Y Stepper Settings
  50. #####################################################################\
  51.  
  52. ######
  53. #X motor slot on main board (B Motor)
  54. ###############
  55. [stepper_x]
  56. step_pin: PF0
  57. dir_pin: PF1
  58. enable_pin: !PD7
  59. microsteps: 16
  60. rotation_distance: 40
  61. full_steps_per_rotation: 200
  62. endstop_pin: !PK1 # PK2 for X-max / PK1=X+
  63. #position_min: 0
  64. position_endstop: 0
  65. position_max: 314
  66. homing_speed: 25 #Max 100
  67. homing_retract_dist: 5
  68. #homing_positive_dir: true
  69.  
  70.  
  71. ######
  72. #Y motor slot on main board (A Motor)
  73. ###############
  74. [stepper_y]
  75. step_pin: PF6
  76. dir_pin: PF7
  77. enable_pin: !PF2
  78. microsteps: 16
  79. rotation_distance: 40
  80. full_steps_per_rotation: 200
  81. endstop_pin: !PJ1 # PJ0 for Y-max / PJ1=Y-
  82. position_endstop: 23
  83. position_min:23
  84. position_max: 310 #noch nicht richtig
  85. homing_speed: 25 #Max 100
  86. homing_retract_dist: 5
  87. #homing_positive_dir: true
  88.  
  89.  
  90.  
  91. #####################################################################
  92. # Z Stepper Settings
  93. #####################################################################
  94.  
  95. ######
  96. # Z0 Stepper - Left Front
  97. # M1 motor slot on expander board
  98. ###############
  99. [stepper_z]
  100. step_pin: PL6
  101. dir_pin: !PL1
  102. enable_pin: !PF4
  103. microsteps: 16
  104. ##T8x4 Lead Screws. One rotation moves the bed 4mm
  105. ##Change according to integrated steppers purchased
  106. rotation_distance: 2
  107. full_steps_per_rotation: 200
  108. endstop_pin: probe:z_virtual_endstop # PE4 for Z-max
  109. # Z-position of nozzle (in mm) to z-endstop trigger point relative to print surface (Z0)
  110. # (+) value = endstop above Z0, (-) value = endstop below
  111. # Increasing position_endstop brings nozzle closer to the bed
  112. # After you run Z_ENDSTOP_CALIBRATE, position_endstop will be stored at the very end of your config
  113. #position_endstop: -0.5
  114. ## All builds use same Max Z
  115. position_max: 310
  116. position_min: -5
  117. homing_speed: 35.0
  118.  
  119.  
  120. ######
  121. #M2 motor slot on expander board (Rear Z)
  122. ###############
  123. [stepper_z1]
  124. step_pin: PA4 #Extuder Anschluss
  125. dir_pin: !PA6
  126. enable_pin: !PA2
  127. microsteps: 16
  128. rotation_distance: 2
  129. full_steps_per_rotation: 200
  130.  
  131.  
  132. ######
  133. #M3 motor slot on expander board (Right Front Z)
  134. ###############
  135. [stepper_z2]
  136. step_pin: PC1 #Extruder 1 Anschluss
  137. dir_pin: !PC3
  138. enable_pin: !PC7
  139. microsteps: 16
  140. rotation_distance: 2
  141. full_steps_per_rotation: 200
  142.  
  143. #E0 motor slot on main board
  144. [extruder]
  145. max_extrude_cross_section: 50
  146. max_extrude_only_distance: 700.00
  147. step_pin: PF5
  148. dir_pin: !PF3
  149. enable_pin: !PG1
  150. microsteps: 16
  151. rotation_distance: 7.865169315
  152. nozzle_diameter: 0.600
  153. filament_diameter: 1.750
  154. heater_pin: PE3
  155. sensor_type: EPCOS 100K B57560G104F
  156. sensor_pin: PK4
  157. min_extrude_temp: 170
  158. min_temp: 10
  159. max_temp: 275
  160. #control = pid
  161. #pid_kp = 26.213
  162. #pid_ki = 1.304
  163. #pid_kd = 131.721
  164. pressure_advance: 0.67
  165. pressure_advance_smooth_time: 0.040
  166.  
  167. #####################################################################
  168. # TMC UART Mode
  169. #####################################################################
  170.  
  171. [tmc2208 stepper_x]
  172. uart_pin: PG3
  173. tx_pin: PJ2
  174. hold_current: 0.25
  175. run_current: 0.6 #1A IMAX*0,707*0,85
  176. stealthchop_threshold: 999999
  177. #0,85 ist die safety margin
  178. [tmc2208 stepper_y]
  179. uart_pin: PJ3
  180. tx_pin: PJ4
  181. hold_current: 0.25
  182. run_current: 0.6
  183. stealthchop_threshold: 999999
  184.  
  185. [tmc2208 stepper_z]
  186. uart_pin: PE2
  187. tx_pin: PE6
  188. run_current: 0.5 #0,84A Imax
  189. stealthchop_threshold: 999999
  190.  
  191. [tmc2208 stepper_z1]
  192. uart_pin: PJ5
  193. tx_pin: PJ6
  194. run_current: 0.5
  195. stealthchop_threshold: 999999
  196.  
  197. [tmc2208 stepper_z2]
  198. uart_pin: PE7
  199. tx_pin: PD4
  200. run_current: 0.5
  201. stealthchop_threshold: 999999 #30 normal, 999999 für enabled
  202.  
  203. [tmc2208 extruder]
  204. uart_pin: PA1
  205. tx_pin: PD5
  206. run_current: 0.42 #0,7A Imax
  207. stealthchop_threshold: 999999
  208.  
  209.  
  210.  
  211.  
  212.  
  213. #####################################################################
  214. # Bed Heater
  215. #####################################################################
  216. [heater_bed]
  217. heater_pin: PH5
  218. sensor_type: EPCOS 100K B57560G104F
  219. sensor_pin: PK7
  220. ##Adjust Max Power so your heater doesn't warp your bed
  221. max_power: 0.6
  222. min_temp: 5
  223. max_temp: 140
  224. #control: pid
  225. #pid_kp: 58.437
  226. #pid_ki: 2.347
  227. #pid_kd: 363.769
  228.  
  229.  
  230. #####################################################################
  231. # Fan Control
  232. #####################################################################
  233.  
  234. ######
  235. #Part Cooling Fan
  236. #HE1 Connector on Main Board
  237. ###############
  238. [fan]
  239. pin: PL5
  240.  
  241. ######
  242. #Hotend Cooling Fan
  243. #Fan0 Connector on Main Board
  244. ###############
  245. [heater_fan hotend_fan]
  246. pin: PL4
  247. max_power: 1.0
  248. kick_start_time: 0.5
  249. heater: extruder
  250. heater_temp: 50.0
  251.  
  252. ## Any additional fans can be driven by Fan1/Fan3 slots
  253. ## at full power on the main board, or alternative solutions
  254. ## may be sought for MOSFET controlled ports.
  255.  
  256. #####################################################################
  257. # Homing and Gantry Adjustment Routines
  258. #####################################################################
  259. [idle_timeout]
  260. timeout: 1800
  261.  
  262.  
  263. #####################################################################
  264. # Displays
  265. #####################################################################
  266.  
  267. #Using the EXP-MOT Expander uses up standard Mini FYSETC Capable Display
  268. #Ports. Other solutions must be procured.
  269.  
  270. #####################################################################
  271. # Macros
  272. #####################################################################
  273.  
  274. [z_tilt]
  275. ## Use Z_TILT_ADJUST to level the bed .
  276. ## z_positions: Location of toolhead
  277.  
  278.  
  279. # Uncomment below for 300mm build
  280. #z_positions=positons screwrods
  281. z_positions:
  282. -45, 0
  283. 156, 353
  284. 353, 0
  285. #bltouch ist -47 in x und -4 in y
  286. points: #position toolhead
  287. 95, 30
  288. 205, 280
  289. 310, 30
  290.  
  291. ## Uncomment below for 350mm build
  292. #z_positions:
  293. # -50, 18
  294. # 175, 398
  295. # 400, 18
  296. #points:
  297. # 30, 5
  298. # 175, 295
  299. # 320, 5
  300.  
  301.  
  302. ##--------------------------------------------------------------------
  303.  
  304. speed: 200
  305. horizontal_move_z: 10
  306. retries: 5
  307. retry_tolerance: 0.0075
  308.  
  309. [gcode_macro PRINT_START]
  310. # Use PRINT_START for the slicer starting script - PLEASE CUSTOMISE THE SCRIPT
  311. gcode:
  312. M117 Homing... ; display message
  313. G28 Y0 X0 Z0
  314. Z_TILT_ADJUST
  315. G28 Y0 X0 Z0
  316.  
  317. ##Purge Line Gcode
  318. #G92 E0;
  319. #G90
  320. #G0 X5 Y5 F6000
  321. #G0 Z0.4
  322. #G91
  323. #G1 X120 E30 F1200;
  324. #G1 Y1
  325. #G1 X-120 E30 F1200;
  326. #G92 E0;
  327. #G90
  328.  
  329. G1 Z15.0 F600 ;move the platform down 15mm
  330. G1 X125 Y125 F3000
  331. G92 E0 ;zero the extruded length again
  332. G1 F9000
  333. M117 Printing...
  334.  
  335. [gcode_macro PRINT_END]
  336. # Use PRINT_END for the slicer ending script
  337. gcode:
  338. # Get Boundaries
  339. {% set max_x = printer.configfile.config["stepper_x"]["position_max"]|float %}
  340. {% set max_y = printer.configfile.config["stepper_y"]["position_max"]|float %}
  341. {% set max_z = printer.configfile.config["stepper_z"]["position_max"]|float %}
  342.  
  343. # Check end position to determine safe directions to move
  344. {% if printer.toolhead.position.x < (max_x - 20) %}
  345. {% set x_safe = 20.0 %}
  346. {% else %}
  347. {% set x_safe = -20.0 %}
  348. {% endif %}
  349.  
  350. {% if printer.toolhead.position.y < (max_y - 20) %}
  351. {% set y_safe = 20.0 %}
  352. {% else %}
  353. {% set y_safe = -20.0 %}
  354. {% endif %}
  355.  
  356. {% if printer.toolhead.position.z < (max_z - 2) %}
  357. {% set z_safe = 2.0 %}
  358. {% else %}
  359. {% set z_safe = max_z - printer.toolhead.position.z %}
  360. {% endif %}
  361.  
  362. # Commence PRINT_END
  363. M400 ; wait for buffer to clear
  364. G92 E0 ; zero the extruder
  365. G1 E-4.0 F3600 ; retract
  366. G91 ; relative positioning
  367. G0 Z{z_safe} F3600 ; move nozzle up
  368. G0 X{x_safe} Y{y_safe} F20000 ; move nozzle to remove stringing
  369.  
  370. M104 S0 ; turn off hotend
  371. M140 S0 ; turn off bed
  372. M106 S0 ; turn off fan
  373. G90 ; absolute positioning
  374. G0 X{max_x / 2} Y{max_y} F3600 ; park nozzle at rear
  375. M117 Finished!
  376.  
  377. [gcode_macro UNSAFE_LOWER_BED]
  378. description: Lower the bed 10mm without homing
  379. gcode:
  380. G90
  381. SET_KINEMATIC_POSITION Z=0
  382. G0 Z10 F600
  383. M84
  384.  
  385. [gcode_macro UNSAFE_HIGHER_BED]
  386. description: Higher the bed 10mm without homing
  387. gcode:
  388. G90
  389. SET_KINEMATIC_POSITION Z=0
  390. G0 Z-10 F600
  391. M84
  392.  
  393. [gcode_macro CANCEL_PRINT]
  394. rename_existing: BASE_CANCEL_PRINT
  395. gcode:
  396. M220 S100 ; Reset Speed factor override percentage to default (100%)
  397. M221 S100 ; Reset Extrude factor override percentage to default (100%)
  398. G91 ; Set coordinates to relative
  399. {% if printer.extruder.temperature >= 170 %}
  400. G1 F1800 E-1 ; Retract filament 3 mm to prevent oozing
  401. {% endif %}
  402. ;if all axis are homed, lift the hotend to leave room for hot filament to ooze and to keep it clear of the bed.
  403. {% if printer.toolhead.homed_axes == "xyz" %}
  404. G1 F6000 Z10 ; Move Z Axis up 10 mm to allow filament ooze freely
  405. G90 ; Set coordinates to absolute
  406. G1 X10 Y221 F1000 ; Move Printer Head Out of Way
  407. ; M84 ; Disable stepper motors - don't so the gantry stays aligned
  408. {% endif %}
  409. ;set part fan speed to zero.
  410. M106 S0
  411. ;bed and hotend are left at the print temps in case I want to restart.
  412. CLEAR_PAUSE
  413. BASE_CANCEL_PRINT
  414.  
  415. #*# <---------------------- SAVE_CONFIG ---------------------->
  416. #*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
  417. #*#
  418. #*# [heater_bed]
  419. #*# control = pid
  420. #*# pid_kp = 45.307
  421. #*# pid_ki = 0.677
  422. #*# pid_kd = 757.767
  423. #*#
  424. #*# [extruder]
  425. #*# control = pid
  426. #*# pid_kp = 28.100
  427. #*# pid_ki = 1.801
  428. #*# pid_kd = 109.591
  429. #*#
  430. #*# [input_shaper]
  431. #*# shaper_type_x = 3hump_ei
  432. #*# shaper_freq_x = 56.0
  433. #*# shaper_type_y = 2hump_ei
  434. #*# shaper_freq_y = 54.4
  435.  
Add Comment
Please, Sign In to add comment