1_75mm_MK2-EINY03-E3Dv6full.h 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445
  1. #ifndef CONFIGURATION_PRUSA_H
  2. #define CONFIGURATION_PRUSA_H
  3. /*------------------------------------
  4. GENERAL SETTINGS
  5. *------------------------------------*/
  6. // Printer revision
  7. #define FILAMENT_SIZE "1_75mm_MK3"
  8. #define NOZZLE_TYPE "E3Dv6full"
  9. // Developer flag
  10. #define DEVELOPER
  11. // Printer name
  12. #define CUSTOM_MENDEL_NAME "Prusa i3 MK3"
  13. // Electronics
  14. //#define MOTHERBOARD BOARD_EINY_0_4a
  15. #define MOTHERBOARD BOARD_EINY_0_3a
  16. // Uncomment the below for the E3D PT100 temperature sensor (with or without PT100 Amplifier)
  17. //#define E3D_PT100_EXTRUDER_WITH_AMP
  18. //#define E3D_PT100_EXTRUDER_NO_AMP
  19. //#define E3D_PT100_BED_WITH_AMP
  20. //#define E3D_PT100_BED_NO_AMP
  21. /*------------------------------------
  22. AXIS SETTINGS
  23. *------------------------------------*/
  24. // Steps per unit {X,Y,Z,E}
  25. //#define DEFAULT_AXIS_STEPS_PER_UNIT {100,100,3200/8,140}
  26. #define DEFAULT_AXIS_STEPS_PER_UNIT {100,100,3200/8,280}
  27. //#define DEFAULT_AXIS_STEPS_PER_UNIT {200,200,3200/4,560}
  28. // Endstop inverting
  29. const bool X_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
  30. const bool Y_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
  31. const bool Z_MIN_ENDSTOP_INVERTING = false; // set to true to invert the logic of the endstop.
  32. // Home position
  33. #define MANUAL_X_HOME_POS 0
  34. #define MANUAL_Y_HOME_POS -2.2
  35. #define MANUAL_Z_HOME_POS 0.2
  36. // Travel limits after homing
  37. #define X_MAX_POS 255
  38. #define X_MIN_POS 0
  39. #define Y_MAX_POS 210
  40. #define Y_MIN_POS -4
  41. #define Z_MAX_POS 210
  42. #define Z_MIN_POS 0.15
  43. // Canceled home position
  44. #define X_CANCEL_POS 50
  45. #define Y_CANCEL_POS 190
  46. //Pause print position
  47. #define X_PAUSE_POS 50
  48. #define Y_PAUSE_POS 190
  49. #define Z_PAUSE_LIFT 20
  50. #define NUM_AXIS 4 // The axis order in all axis related arrays is X, Y, Z, E
  51. #define HOMING_FEEDRATE {3000, 3000, 800, 0} // set the homing speeds (mm/min) // 3000 is also valid for stallGuard homing. Valid range: 2200 - 3000
  52. //#define DEFAULT_MAX_FEEDRATE {400, 400, 12, 120} // (mm/sec)
  53. #define DEFAULT_MAX_FEEDRATE {400, 400, 12, 120} // (mm/sec)
  54. #define DEFAULT_MAX_ACCELERATION {1000, 1000, 100, 5000} // X, Y, Z, E maximum start speed for accelerated moves. E default values are good for Skeinforge 40+, for older versions raise them a lot.
  55. #define DEFAULT_ACCELERATION 1250 // X, Y, Z and E max acceleration in mm/s^2 for printing moves
  56. #define DEFAULT_RETRACT_ACCELERATION 1250 // X, Y, Z and E max acceleration in mm/s^2 for retracts
  57. #define MANUAL_FEEDRATE {2700, 2700, 1000, 100} // set the speeds for manual moves (mm/min)
  58. #define MAX_SILENT_FEEDRATE 2700 //
  59. #define Z_AXIS_ALWAYS_ON 1
  60. /*------------------------------------
  61. TMC2130 default settings
  62. *------------------------------------*/
  63. // PWM register configuration
  64. //#define TMC2130_PWM_GRAD 0x08 // 0x0F - Sets gradient - (max 15 with PWM autoscale activated)
  65. //#define TMC2130_PWM_AMPL 0xC8 // 0xFF - Sets PWM amplitude to 200 (max is 255)
  66. #define TMC2130_PWM_GRAD 0x01 // 0x0F - Sets gradient - (max 15 with PWM autoscale activated)
  67. #define TMC2130_PWM_AMPL 0xc8 // 0xFF - Sets PWM amplitude to 200 (max is 255)
  68. #define TMC2130_PWM_AUTO 0x04 // 0x04 since writing in PWM_CONF (Activates PWM autoscaling)
  69. //#define TMC2130_PWM_FREQ 0x01 // 0x01 since writing in PWM_CONF (Sets PWM frequency to 2/683 fCLK) 35.1kHz
  70. #define TMC2130_PWM_FREQ 0x02 // 0x02 since writing in PWM_CONF (Sets PWM frequency to 2/683 fCLK) 46.9kHz
  71. #define TMC2130_USTEPS_XY 16
  72. #define TMC2130_USTEPS_Z 16
  73. #define TMC2130_USTEPS_E 16
  74. #define TMC2130_EXP256_XY 1
  75. #define TMC2130_EXP256_Z 1
  76. #define TMC2130_EXP256_E 1
  77. // Special configuration for XY axes for operation (during standstill, use same settings as for other axes) //todo
  78. // RP: this settings does not work (overtemp)
  79. //#define TMC2130_PWM_GRAD_XY 156 // 0x0F - Sets gradient - (max 15 with PWM autoscale activated)
  80. //#define TMC2130_PWM_AMPL_XY 63 // 0xFF - Sets PWM amplitude to 200 (max is 255)
  81. //#define TMC2130_PWM_AUTO_XY 0x00 // 0x04 since writing in PWM_CONF (Activates PWM autoscaling)
  82. //#define TMC2130_PWM_FREQ_XY 0x01 // 0x01 since writing in PWM_CONF (Sets PWM frequency to 2/683 fCLK)
  83. #define TMC2130_TPWMTHRS 0 // TPWMTHRS - Sets the switching speed threshold based on TSTEP from stealthChop to spreadCycle mode
  84. #define TMC2130_THIGH 0 // THIGH - unused
  85. #define TMC2130_TCOOLTHRS 239 // TCOOLTHRS - coolstep treshold
  86. #define TMC2130_SG_HOMING 1 // stallguard homing
  87. #define TMC2130_SG_HOMING_SW 1 // stallguard "software" homing
  88. #define TMC2130_SG_THRS_X 12 // stallguard sensitivity for X axis
  89. #define TMC2130_SG_THRS_Y 12 // stallguard sensitivity for Y axis
  90. #define TMC2130_CURRENTS_H {2, 2, 2, 4} // default holding currents for all axes
  91. #define TMC2130_CURRENTS_R {6, 6, 10, 8} // default running currents for all axes
  92. #define TMC2130_DEBUG
  93. //#define TMC2130_DEBUG_WR
  94. //#define TMC2130_DEBUG_RD
  95. /*------------------------------------
  96. EXTRUDER SETTINGS
  97. *------------------------------------*/
  98. // Mintemps
  99. #define HEATER_0_MINTEMP 15
  100. #define HEATER_1_MINTEMP 5
  101. #define HEATER_2_MINTEMP 5
  102. #define BED_MINTEMP 15
  103. // Maxtemps
  104. #if defined(E3D_PT100_EXTRUDER_WITH_AMP) || defined(E3D_PT100_EXTRUDER_NO_AMP)
  105. #define HEATER_0_MAXTEMP 410
  106. #else
  107. #define HEATER_0_MAXTEMP 305
  108. #endif
  109. #define HEATER_1_MAXTEMP 305
  110. #define HEATER_2_MAXTEMP 305
  111. #define BED_MAXTEMP 150
  112. #if defined(E3D_PT100_EXTRUDER_WITH_AMP) || defined(E3D_PT100_EXTRUDER_NO_AMP)
  113. // Define PID constants for extruder with PT100
  114. #define DEFAULT_Kp 21.70
  115. #define DEFAULT_Ki 1.60
  116. #define DEFAULT_Kd 73.76
  117. #else
  118. // Define PID constants for extruder
  119. #define DEFAULT_Kp 40.925
  120. #define DEFAULT_Ki 4.875
  121. #define DEFAULT_Kd 86.085
  122. #endif
  123. // Extrude mintemp
  124. #define EXTRUDE_MINTEMP 130
  125. // Extruder cooling fans
  126. #define EXTRUDER_0_AUTO_FAN_PIN 8
  127. #define EXTRUDER_1_AUTO_FAN_PIN -1
  128. #define EXTRUDER_2_AUTO_FAN_PIN -1
  129. #define EXTRUDER_AUTO_FAN_TEMPERATURE 50
  130. #define EXTRUDER_AUTO_FAN_SPEED 255 // == full speed
  131. /*------------------------------------
  132. LOAD/UNLOAD FILAMENT SETTINGS
  133. *------------------------------------*/
  134. // Load filament commands
  135. #define LOAD_FILAMENT_0 "M83"
  136. #define LOAD_FILAMENT_1 "G1 E70 F400"
  137. #define LOAD_FILAMENT_2 "G1 E40 F100"
  138. // Unload filament commands
  139. #define UNLOAD_FILAMENT_0 "M83"
  140. #define UNLOAD_FILAMENT_1 "G1 E-80 F7000"
  141. /*------------------------------------
  142. CHANGE FILAMENT SETTINGS
  143. *------------------------------------*/
  144. // Filament change configuration
  145. #define FILAMENTCHANGEENABLE
  146. #ifdef FILAMENTCHANGEENABLE
  147. #define FILAMENTCHANGE_XPOS 211
  148. #define FILAMENTCHANGE_YPOS 0
  149. #define FILAMENTCHANGE_ZADD 2
  150. #define FILAMENTCHANGE_FIRSTRETRACT -2
  151. #define FILAMENTCHANGE_FINALRETRACT -80
  152. #define FILAMENTCHANGE_FIRSTFEED 70
  153. #define FILAMENTCHANGE_FINALFEED 50
  154. #define FILAMENTCHANGE_RECFEED 5
  155. #define FILAMENTCHANGE_XYFEED 50
  156. #define FILAMENTCHANGE_EFEED 20
  157. #define FILAMENTCHANGE_RFEED 400
  158. #define FILAMENTCHANGE_EXFEED 2
  159. #define FILAMENTCHANGE_ZFEED 15
  160. #endif
  161. /*------------------------------------
  162. ADDITIONAL FEATURES SETTINGS
  163. *------------------------------------*/
  164. // Define Prusa filament runout sensor
  165. //#define FILAMENT_RUNOUT_SUPPORT
  166. #ifdef FILAMENT_RUNOUT_SUPPORT
  167. #define FILAMENT_RUNOUT_SENSOR 1
  168. #endif
  169. // temperature runaway
  170. //#define TEMP_RUNAWAY_BED_HYSTERESIS 5
  171. //#define TEMP_RUNAWAY_BED_TIMEOUT 360
  172. #define TEMP_RUNAWAY_EXTRUDER_HYSTERESIS 15
  173. #define TEMP_RUNAWAY_EXTRUDER_TIMEOUT 45
  174. /*------------------------------------
  175. MOTOR CURRENT SETTINGS
  176. *------------------------------------*/
  177. // Motor Current setting for BIG RAMBo
  178. #define DIGIPOT_MOTOR_CURRENT {135,135,135,135,135} // Values 0-255 (RAMBO 135 = ~0.75A, 185 = ~1A)
  179. #define DIGIPOT_MOTOR_CURRENT_LOUD {135,135,135,135,135}
  180. // Motor Current settings for RAMBo mini PWM value = MotorCurrentSetting * 255 / range
  181. #if MOTHERBOARD == 102 || MOTHERBOARD == 302 || MOTHERBOARD == 300 || MOTHERBOARD == 299
  182. #define MOTOR_CURRENT_PWM_RANGE 2000
  183. #define DEFAULT_PWM_MOTOR_CURRENT {400, 750, 750} // {XY,Z,E}
  184. #define DEFAULT_PWM_MOTOR_CURRENT_LOUD {400, 750, 750} // {XY,Z,E}
  185. #endif
  186. /*------------------------------------
  187. BED SETTINGS
  188. *------------------------------------*/
  189. // Define Mesh Bed Leveling system to enable it
  190. #define MESH_BED_LEVELING
  191. #ifdef MESH_BED_LEVELING
  192. #define MBL_Z_STEP 0.01
  193. // Mesh definitions
  194. #define MESH_MIN_X 35
  195. #define MESH_MAX_X 238
  196. #define MESH_MIN_Y 6
  197. #define MESH_MAX_Y 202
  198. // Mesh upsample definition
  199. #define MESH_NUM_X_POINTS 7
  200. #define MESH_NUM_Y_POINTS 7
  201. // Mesh measure definition
  202. #define MESH_MEAS_NUM_X_POINTS 3
  203. #define MESH_MEAS_NUM_Y_POINTS 3
  204. #define MESH_HOME_Z_CALIB 0.2
  205. #define MESH_HOME_Z_SEARCH 5 //Z lift for homing, mesh bed leveling etc.
  206. #define X_PROBE_OFFSET_FROM_EXTRUDER 23 // Z probe to nozzle X offset: -left +right
  207. #define Y_PROBE_OFFSET_FROM_EXTRUDER 9 // Z probe to nozzle Y offset: -front +behind
  208. #define Z_PROBE_OFFSET_FROM_EXTRUDER -0.4 // Z probe to nozzle Z offset: -below (always!)
  209. #endif
  210. // Bed Temperature Control
  211. // Select PID or bang-bang with PIDTEMPBED. If bang-bang, BED_LIMIT_SWITCHING will enable hysteresis
  212. //
  213. // Uncomment this to enable PID on the bed. It uses the same frequency PWM as the extruder.
  214. // If your PID_dT above is the default, and correct for your hardware/configuration, that means 7.689Hz,
  215. // which is fine for driving a square wave into a resistive load and does not significantly impact you FET heating.
  216. // This also works fine on a Fotek SSR-10DA Solid State Relay into a 250W heater.
  217. // If your configuration is significantly different than this and you don't understand the issues involved, you probably
  218. // shouldn't use bed PID until someone else verifies your hardware works.
  219. // If this is enabled, find your own PID constants below.
  220. #define PIDTEMPBED
  221. //
  222. //#define BED_LIMIT_SWITCHING
  223. // This sets the max power delivered to the bed, and replaces the HEATER_BED_DUTY_CYCLE_DIVIDER option.
  224. // all forms of bed control obey this (PID, bang-bang, bang-bang with hysteresis)
  225. // setting this to anything other than 255 enables a form of PWM to the bed just like HEATER_BED_DUTY_CYCLE_DIVIDER did,
  226. // so you shouldn't use it unless you are OK with PWM on your bed. (see the comment on enabling PIDTEMPBED)
  227. #define MAX_BED_POWER 255 // limits duty cycle to bed; 255=full current
  228. // Bed temperature compensation settings
  229. #define BED_OFFSET 10
  230. #define BED_OFFSET_START 40
  231. #define BED_OFFSET_CENTER 50
  232. #ifdef PIDTEMPBED
  233. //120v 250W silicone heater into 4mm borosilicate (MendelMax 1.5+)
  234. //from FOPDT model - kp=.39 Tp=405 Tdead=66, Tc set to 79.2, aggressive factor of .15 (vs .1, 1, 10)
  235. #if defined(E3D_PT100_BED_WITH_AMP) || defined(E3D_PT100_BED_NO_AMP)
  236. // Define PID constants for extruder with PT100
  237. #define DEFAULT_bedKp 21.70
  238. #define DEFAULT_bedKi 1.60
  239. #define DEFAULT_bedKd 73.76
  240. #else
  241. #define DEFAULT_bedKp 126.13
  242. #define DEFAULT_bedKi 4.30
  243. #define DEFAULT_bedKd 924.76
  244. #endif
  245. //120v 250W silicone heater into 4mm borosilicate (MendelMax 1.5+)
  246. //from pidautotune
  247. // #define DEFAULT_bedKp 97.1
  248. // #define DEFAULT_bedKi 1.41
  249. // #define DEFAULT_bedKd 1675.16
  250. // FIND YOUR OWN: "M303 E-1 C8 S90" to run autotune on the bed at 90 degreesC for 8 cycles.
  251. #endif // PIDTEMPBED
  252. /*-----------------------------------
  253. PREHEAT SETTINGS
  254. *------------------------------------*/
  255. #define PLA_PREHEAT_HOTEND_TEMP 215
  256. #define PLA_PREHEAT_HPB_TEMP 55
  257. #define PLA_PREHEAT_FAN_SPEED 0
  258. #define ABS_PREHEAT_HOTEND_TEMP 255
  259. #define ABS_PREHEAT_HPB_TEMP 100
  260. #define ABS_PREHEAT_FAN_SPEED 0
  261. #define HIPS_PREHEAT_HOTEND_TEMP 220
  262. #define HIPS_PREHEAT_HPB_TEMP 100
  263. #define HIPS_PREHEAT_FAN_SPEED 0
  264. #define PP_PREHEAT_HOTEND_TEMP 254
  265. #define PP_PREHEAT_HPB_TEMP 100
  266. #define PP_PREHEAT_FAN_SPEED 0
  267. #define PET_PREHEAT_HOTEND_TEMP 240
  268. #define PET_PREHEAT_HPB_TEMP 90
  269. #define PET_PREHEAT_FAN_SPEED 0
  270. #define FLEX_PREHEAT_HOTEND_TEMP 230
  271. #define FLEX_PREHEAT_HPB_TEMP 50
  272. #define FLEX_PREHEAT_FAN_SPEED 0
  273. /*------------------------------------
  274. THERMISTORS SETTINGS
  275. *------------------------------------*/
  276. //
  277. //--NORMAL IS 4.7kohm PULLUP!-- 1kohm pullup can be used on hotend sensor, using correct resistor and table
  278. //
  279. //// Temperature sensor settings:
  280. // -2 is thermocouple with MAX6675 (only for sensor 0)
  281. // -1 is thermocouple with AD595
  282. // 0 is not used
  283. // 1 is 100k thermistor - best choice for EPCOS 100k (4.7k pullup)
  284. // 2 is 200k thermistor - ATC Semitec 204GT-2 (4.7k pullup)
  285. // 3 is Mendel-parts thermistor (4.7k pullup)
  286. // 4 is 10k thermistor !! do not use it for a hotend. It gives bad resolution at high temp. !!
  287. // 5 is 100K thermistor - ATC Semitec 104GT-2 (Used in ParCan & J-Head) (4.7k pullup)
  288. // 6 is 100k EPCOS - Not as accurate as table 1 (created using a fluke thermocouple) (4.7k pullup)
  289. // 7 is 100k Honeywell thermistor 135-104LAG-J01 (4.7k pullup)
  290. // 71 is 100k Honeywell thermistor 135-104LAF-J01 (4.7k pullup)
  291. // 8 is 100k 0603 SMD Vishay NTCS0603E3104FXT (4.7k pullup)
  292. // 9 is 100k GE Sensing AL03006-58.2K-97-G1 (4.7k pullup)
  293. // 10 is 100k RS thermistor 198-961 (4.7k pullup)
  294. // 11 is 100k beta 3950 1% thermistor (4.7k pullup)
  295. // 12 is 100k 0603 SMD Vishay NTCS0603E3104FXT (4.7k pullup) (calibrated for Makibox hot bed)
  296. // 13 is 100k Hisens 3950 1% up to 300°C for hotend "Simple ONE " & "Hotend "All In ONE"
  297. // 20 is the PT100 circuit found in the Ultimainboard V2.x
  298. // 60 is 100k Maker's Tool Works Kapton Bed Thermistor beta=3950
  299. //
  300. // 1k ohm pullup tables - This is not normal, you would have to have changed out your 4.7k for 1k
  301. // (but gives greater accuracy and more stable PID)
  302. // 51 is 100k thermistor - EPCOS (1k pullup)
  303. // 52 is 200k thermistor - ATC Semitec 204GT-2 (1k pullup)
  304. // 55 is 100k thermistor - ATC Semitec 104GT-2 (Used in ParCan & J-Head) (1k pullup)
  305. //
  306. // 1047 is Pt1000 with 4k7 pullup
  307. // 1010 is Pt1000 with 1k pullup (non standard)
  308. // 147 is Pt100 with 4k7 pullup
  309. // 148 is E3D Pt100 with 4k7 pullup and no PT100 Amplifier on a MiniRambo 1.3a
  310. // 247 is Pt100 with 4k7 pullup and PT100 Amplifier
  311. // 110 is Pt100 with 1k pullup (non standard)
  312. #if defined(E3D_PT100_EXTRUDER_WITH_AMP)
  313. #define TEMP_SENSOR_0 247
  314. #elif defined(E3D_PT100_EXTRUDER_NO_AMP)
  315. #define TEMP_SENSOR_0 148
  316. #else
  317. #define TEMP_SENSOR_0 5
  318. #endif
  319. #define TEMP_SENSOR_1 0
  320. #define TEMP_SENSOR_2 0
  321. #if defined(E3D_PT100_BED_WITH_AMP)
  322. #define TEMP_SENSOR_BED 247
  323. #elif defined(E3D_PT100_BED_NO_AMP)
  324. #define TEMP_SENSOR_BED 148
  325. #else
  326. #define TEMP_SENSOR_BED 1
  327. #endif
  328. #define STACK_GUARD_TEST_VALUE 0xA2A2
  329. #define MAX_BED_TEMP_CALIBRATION 50
  330. #define MAX_HOTEND_TEMP_CALIBRATION 50
  331. #define MAX_E_STEPS_PER_UNIT 250
  332. #define MIN_E_STEPS_PER_UNIT 100
  333. #define Z_BABYSTEP_MIN -3999
  334. #define Z_BABYSTEP_MAX 0
  335. #define PINDA_PREHEAT_X 70
  336. #define PINDA_PREHEAT_Y -3
  337. #define PINDA_PREHEAT_Z 1
  338. #define PINDA_HEAT_T 120 //time in s
  339. #define PINDA_MIN_T 50
  340. #define PINDA_STEP_T 10
  341. #define PINDA_MAX_T 100
  342. #define PING_TIME 60 //time in s
  343. #define PING_TIME_LONG 600 //10 min; used when length of commands buffer > 0 to avoid false triggering when dealing with long gcodes
  344. #define PING_ALLERT_PERIOD 60 //time in s
  345. #define LONG_PRESS_TIME 1000 //time in ms for button long press
  346. #define BUTTON_BLANKING_TIME 200 //time in ms for blanking after button release
  347. #define DEFAULT_PID_TEMP 210
  348. #define MIN_PRINT_FAN_SPEED 50
  349. #ifdef SNMM
  350. #define DEFAULT_RETRACTION 4 //used for PINDA temp calibration and pause print
  351. #else
  352. #define DEFAULT_RETRACTION 1 //used for PINDA temp calibration and pause print
  353. #endif
  354. #endif //__CONFIGURATION_PRUSA_H