Advertisement
lutzmor

klipper.cfg

Mar 4th, 2021
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 12.44 KB | None | 0 0
  1. ####################################
  2. ### HevORT SKR 1.4 Klipper setup ###
  3. ####################################
  4. ## Setup firmware
  5. # cd ~/klipper
  6. # make menuconfig
  7. #
  8. # - Micro-controller -- LPC176x (Smoothieboard )
  9. # - Processor model -- lpc1768 for a SKR 1.4 / lpc1769 for a SKR 1.4 turbo
  10. # - Target board uses Smootieware bootloader -- activated
  11. # - Use USB for communication (instead of serial ) -- activated
  12. ## Compile firmware
  13. # make
  14. ## Flash Firmware
  15. # You need to copy the firmware with scp/winscp or similar tools to the sd card, flashing
  16. # over make flash FLASH_DEVICE=/dev/serial/by-id/xxxxx isn't supported at the moment, i
  17. # currently work on a solution for this by modifying/exchanging the bootloader but not
  18. # working right now so the sd card solution is the only working one.
  19. ## Side note
  20. # -- I use an additional toolbard on the carriage so some pins might differ to a pure SKR setup
  21. # i will note the pin to use in a comment when no toolboard is connected.
  22. # -- And i don't use any kind of hotend fans, and my watercooling is controlled seperatly so nothing
  23. # in the setup around that. I only connect the berdAir pump to the main SKR and let it control
  24. # the part cooling with it.
  25.  
  26. ###########################################
  27. ### First SKR 1.4 board for x/y and bed ###
  28. ###########################################
  29. # Further documentation ( https://www.klipper3d.org/Config_Reference.html#mcu )
  30. [mcu]
  31. serial: /dev/serial/by-id/usb-Klipper_lpc1769_0D40FF01C0846AAFA0A3555EC72000F5-if00
  32.  
  33. ########################################################
  34. ### Second SKR 1.4 board for z / z1 / z2 and bltouch ###
  35. ### To get the proper id disconnect the main mcu ###
  36. ### and do a ls -l /dev/serial/by-id/ ###
  37. ########################################################
  38. # Further documentation ( https://www.klipper3d.org/Config_Reference.html#mcu-my_extra_mcu )
  39. [mcu z]
  40. serial: /dev/serial/by-id/usb-Klipper_lpc1769_1680FF0AC0846AAF7DCA555EC02000F5-if00
  41.  
  42. ########################################
  43. ### Toolhead setup ####
  44. #######################
  45. ## Necessary parts
  46. # CAN USB converter ( https://www.tindie.com/products/lll7/can-usb-converter-uccb/ )
  47. # Toolboard ( https://github.com/bondus/KlipperToolboard )
  48. ## Setup
  49. ### Setup firmware
  50. # cd ~/klipper
  51. # make menuconfig
  52. # - Micro-controller Architecture -- STMicroelectronis STM32
  53. # - Processor model -- STM32F103
  54. # - Bootloader offset -- 2KiB bootloader (HIDBootloader
  55. # - Use USB for communication - disabled
  56. # - Use CAN for communication ( instead of serial ) - activated
  57. # - CAN pins -- Pins PB8(rx) and PB9(tx)
  58. ### Flash firmware ( the toolboard needs to be connected to the pi via usb )
  59. # - First off connect BOOT1 pin of the board to a 3.3v pin ( SWD the pin closest to the Stepper drivers ) and power the toolboard up
  60. # -- When the board is in bootloader mode the green LED will flash quickly
  61. # - make flash FLASH_DEVICE=1209:beba
  62. ## Setup CanSerial
  63. # - cd ~/CanSerial
  64. # - sudo cp canserial.service /lib/systemd/system/canserial.service
  65. # - sudo systemctl daemon-reload
  66. # - sudo systemctl enable canserial.service
  67. # - sudo systemctl start canserial.service
  68. #[mcu head]
  69. #serial: /tmp/ttyCAN0_5aa658bb599a # Change to your ID
  70. #restart_method = command
  71.  
  72. ########################################
  73. ### Raspberry Pi connection for adxl ###
  74. ########################################
  75. # Further documentation ( https://www.klipper3d.org/RPi_microcontroller.html )
  76. # All necessary config is done in klipper/resonance.cfg
  77. [mcu rpi]
  78. serial: /tmp/klipper_host_mcu
  79.  
  80. ##############################
  81. ### Basic Printer settings ###
  82. ##############################
  83. # Further documentation ( https://www.klipper3d.org/Config_Reference.html#printer )
  84. [printer]
  85. kinematics: corexy
  86. max_velocity: 400
  87. max_accel: 500
  88. max_z_velocity: 10
  89. max_z_accel: 100
  90.  
  91. #############################
  92. ### Stepper configuration ###
  93. #############################
  94. # Further Documentation ( https://www.klipper3d.org/Config_Reference.html#stepper )
  95. # Further documentation ( https://www.klipper3d.org/Config_Reference.html#tmc2209 )
  96.  
  97. #####################################################
  98. ### Stepper motor for x connected to the main mcu ###
  99. #####################################################
  100. [stepper_x]
  101. step_pin: P2.2
  102. dir_pin: P2.6
  103. enable_pin: !P2.1
  104. microsteps: 16
  105. rotation_distance: 40 # belt pitch * pulley tooth
  106. full_steps_per_rotation: 400 # 360 * motor degree
  107. endstop_pin: P1.29
  108. position_endstop: 0
  109. position_max: 345 # max position in y
  110. homing_speed: 50 # homeing speed 0 - 100
  111. homing_retract_dist: 20 # how far the toolhead should move back before slow homing
  112.  
  113. [tmc2209 stepper_x]
  114. uart_pin: P1.10
  115. interpolate: True # enable step interpolation (the driver will internally step at a rate of 256 micro-steps)
  116. run_current: 1.344 # set "vref" due to uart mode - value something about 80% of max amp of the motor
  117. sense_resistor: 0.110
  118. stealthchop_threshold: 0 # turn stealthchop off
  119.  
  120. #####################################################
  121. ### Stepper motor for y connected to the main mcu ###
  122. #####################################################
  123. [stepper_y]
  124. step_pin: P0.19
  125. dir_pin: P0.20
  126. enable_pin: !P2.8
  127. microsteps: 16
  128. rotation_distance: 40 # belt pitch * pulley tooth
  129. full_steps_per_rotation: 400 # 360 * motor degree
  130. endstop_pin: P1.28 # Endstop pin on the skr 1.4
  131. #endstop_pin: head:PA1 # Endstop pin on the toolhead
  132. position_endstop: 0
  133. position_max: 345 # max position in y
  134. homing_speed: 50 # homeing speed 0 - 100
  135. homing_retract_dist: 20 # how far the toolhead should move back before slow homing
  136.  
  137. [tmc2209 stepper_y]
  138. uart_pin: P1.9
  139. interpolate: True # enable step interpolation (the driver will internally step at a rate of 256 micro-steps)
  140. run_current: 1.344 # set "vref" due to uart mode - value something about 80% of max amp of the motor
  141. sense_resistor: 0.110
  142. stealthchop_threshold: 0 # turn stealthchop off
  143.  
  144. ##################################################
  145. ### Stepper motor for z connected to the z mcu ###
  146. ##################################################
  147. [stepper_z]
  148. step_pin: z:P0.22
  149. dir_pin: z:P2.11
  150. enable_pin: !z:P0.21
  151. microsteps: 16
  152. rotation_distance: 4 # screw pitch * number of seperate threads ( sfu1204 4 * 1 )
  153. full_steps_per_rotation: 200 # 360 * motor degree
  154. endstop_pin: !z:P1.27
  155. position_endstop: 0.0
  156. position_max: 355 # max height of Z
  157. ;endstop_pin: probe:z_virtual_endstop # use bltouch as endstop
  158.  
  159. [tmc2209 stepper_z]
  160. uart_pin: z:P1.8
  161. interpolate: True # enable step interpolation (the driver will internally step at a rate of 256 micro-steps)
  162. run_current: 1.200 # set "vref" due to uart mode - value something about 80% of max amp of the motor
  163. sense_resistor: 0.110
  164. stealthchop_threshold: 0 # turn stealthchop off
  165.  
  166. ###################################################
  167. ### Stepper motor for z1 connected to the z mcu ###
  168. ###################################################
  169. [stepper_z1]
  170. step_pin: z:P2.2
  171. dir_pin: z:P2.6
  172. enable_pin: !z:P2.1
  173. microsteps: 16
  174. rotation_distance: 4 # screw pitch * number of seperate threads ( sfu1204 4 * 1 )
  175. full_steps_per_rotation: 200 # 360 * motor degree
  176.  
  177. [tmc2209 stepper_z1]
  178. uart_pin: z:P1.10
  179. interpolate: True # enable step interpolation (the driver will internally step at a rate of 256 micro-steps)
  180. run_current: 1.200 # set "vref" due to uart mode - value something about 80% of max amp of the motor
  181. sense_resistor: 0.110
  182. stealthchop_threshold: 0 # turn stealthchop off
  183.  
  184. ###################################################
  185. ### Stepper motor for z1 connected to the z mcu ###
  186. ###################################################
  187. [stepper_z2]
  188. step_pin: z:P0.19
  189. dir_pin: z:P0.20
  190. enable_pin: !z:P2.8
  191. microsteps: 16
  192. rotation_distance: 4 # screw pitch * number of seperate threads ( sfu1204 4 * 1 )
  193. full_steps_per_rotation: 200 # 360 * motor degree
  194.  
  195. [tmc2209 stepper_z2]
  196. uart_pin: z:P1.9
  197. interpolate: True # enable step interpolation (the driver will internally step at a rate of 256 micro-steps)
  198. run_current: 1.200 # set "vref" due to uart mode - value something about 80% of max amp of the motor
  199. sense_resistor: 0.110
  200. stealthchop_threshold: 0 # turn stealthchop off
  201.  
  202. ##########################
  203. ### Extruder Settings ####
  204. ##########################
  205. [extruder]
  206. step_pin: P2.13 # Step pin if extruder is connected to the SKR
  207. dir_pin: !P0.11 # Dir pin if extruder is connected to the SKR
  208. enable_pin: !P2.12 # Enable pin if extruder is connected to the SKR
  209. heater_pin: P2.7 # heater pin if Hotend is connected to the SKR
  210. sensor_pin: P0.24 # sensor pin if Thermistor is connected to the SKR
  211.  
  212. #step_pin: head0:PB3 # Step pin if extruder is connected to the toolhead
  213. #dir_pin: head0:PB4 # Dir pin if extruder is connected to the toolhead
  214. #enable_pin: !head0:PB6 # Enable pin if extruder is connected to the toolhead
  215. #heater_pin: head0:PA6 # heater pin if Hotend is connected to the toolhead
  216. #sensor_pin: head0:PA0 # sensor pin if Thermistor is connected to the toolhead
  217.  
  218. microsteps: 16
  219. rotation_distance: 33.500
  220. nozzle_diameter: 0.400
  221. filament_diameter: 1.750
  222. sensor_type: EPCOS 100K B57560G104F
  223. control: pid
  224. pid_Kp: 22.2
  225. pid_Ki: 1.08
  226. pid_Kd: 114
  227. min_temp: -273.15
  228. max_temp: 260
  229.  
  230. [tmc2209 extruder]
  231. uart_pin: P1.4 # uart pin if extruder is connected to the SKR
  232. #uart_pin: head0:PA10 # uart pin if extruder is connected to the toolhead
  233. #tx_pin: head0:PA9 # tx pin if extruder is connected to the toolhead
  234. interpolate: false
  235. run_current: 0.5
  236. sense_resistor: 0.110
  237. stealthchop_threshold: 0
  238.  
  239. ########################################
  240. ### Configuration for the heated bed ###
  241. ########################################
  242. # Further Documentation ( https://www.klipper3d.org/Config_Reference.html#heater_bed )
  243. [heater_bed]
  244. heater_pin: P2.5
  245. sensor_type: EPCOS 100K B57560G104F
  246. sensor_pin: P0.25
  247. control: pid
  248. pid_Kp: 54.027
  249. pid_Ki: 0.770
  250. pid_Kd: 948.182
  251. min_temp: -273.15
  252. max_temp: 130
  253.  
  254. #####################################
  255. ### Configuration for the bltouch ###
  256. #####################################
  257. # Further Documentation ( https://www.klipper3d.org/Config_Reference.html#bltouch )
  258. [bltouch]
  259. sensor_pin: ^z:P0.10
  260. control_pin: z:P2.0
  261. x_offset: 37.449
  262. y_offset: 26.253
  263. z_offset: 3
  264. speed: 5
  265. samples: 1
  266. #sample_retract_dist: 5
  267. #samples_tolerance: 0.010
  268.  
  269. #########################################
  270. ### Configuration for the Safe z home ###
  271. #########################################
  272. # Further Documentation ( https://www.klipper3d.org/Config_Reference.html#safe_z_home )
  273. [safe_z_home]
  274. home_xy_position: 20,20
  275. speed: 50
  276. z_hop: 10 # Move up 10mm
  277. z_hop_speed: 5
  278.  
  279. ################################
  280. ### Configuration for Z tilt ###
  281. ################################
  282. # Further Documentation ( https://www.klipper3d.org/Config_Reference.html#z_tilt )
  283. #[z_tilt]
  284. #z_positions:
  285. # -15,2
  286. # 173,355
  287. # 362,2
  288. #points:
  289. # 40,60
  290. # 180,370
  291. # 345,60
  292. #speed: 50
  293. #horizontal_move_z: 10
  294. #retries: 3
  295. #retry_tolerance: 0.001
  296.  
  297. #########################
  298. ### Fan configuration ###
  299. #########################
  300. # Further documentation:
  301. # Fans - https://www.klipper3d.org/Config_Reference.html#fans
  302. # Fan - https://www.klipper3d.org/Config_Reference.html#fan
  303. # Heater fan - https://www.klipper3d.org/Config_Reference.html#heater_fan
  304. # Controller fan - https://www.klipper3d.org/Config_Reference.html#controller_fan
  305. # Temperature fan - https://www.klipper3d.org/Config_Reference.html#temperature_fan
  306. # Fan generic - https://www.klipper3d.org/Config_Reference.html#fan_generic
  307. [fan]
  308. pin: P2.3
  309.  
  310. # Resonance tuning
  311. [include klipper/resonance.cfg]
  312.  
  313. # Fluidd specific stuff
  314. [include klipper/fluidd.cfg]
  315. [include macros.cfg]
  316.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement