From 02566cc007ed8d460e34226c9542282c3e260605 Mon Sep 17 00:00:00 2001 From: kliment Date: Tue, 12 Jul 2011 15:24:09 +0200 Subject: Add 10k thermistor --- Sprinter/Configuration.h | 1 + Sprinter/thermistortables.h | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) (limited to 'Sprinter') diff --git a/Sprinter/Configuration.h b/Sprinter/Configuration.h index 319c839..a9cb67f 100644 --- a/Sprinter/Configuration.h +++ b/Sprinter/Configuration.h @@ -15,6 +15,7 @@ // 1 is 100k thermistor // 2 is 200k thermistor // 3 is mendel-parts thermistor +// 4 is 10k thermistor #define THERMISTORHEATER 1 #define THERMISTORBED 1 diff --git a/Sprinter/thermistortables.h b/Sprinter/thermistortables.h index 6c583af..de9aee6 100644 --- a/Sprinter/thermistortables.h +++ b/Sprinter/thermistortables.h @@ -130,6 +130,32 @@ const short temptable_3[NUMTEMPS_3][2] = { }; #endif +#if (THERMISTORHEATER == 4) || (THERMISTORBED == 4) //10k thermistor + +#define NUMTEMPS_4 20 +short temptable_4[NUMTEMPS_4][2] = { + {1, 430}, + {54, 137}, + {107, 107}, + {160, 91}, + {213, 80}, + {266, 71}, + {319, 64}, + {372, 57}, + {425, 51}, + {478, 46}, + {531, 41}, + {584, 35}, + {637, 30}, + {690, 25}, + {743, 20}, + {796, 14}, + {849, 7}, + {902, 0}, + {955, -11}, + {1008, -35} +}; +#endif #if THERMISTORHEATER == 1 #define NUMTEMPS NUMTEMPS_1 @@ -140,6 +166,9 @@ const short temptable_3[NUMTEMPS_3][2] = { #elif THERMISTORHEATER == 3 #define NUMTEMPS NUMTEMPS_3 #define temptable temptable_3 +#elif THERMISTORHEATER == 4 +#define NUMTEMPS NUMTEMPS_4 +#define temptable temptable_4 #elif defined HEATER_USES_THERMISTOR #error No heater thermistor table specified #endif @@ -152,6 +181,9 @@ const short temptable_3[NUMTEMPS_3][2] = { #elif THERMISTORBED == 3 #define BNUMTEMPS NUMTEMPS_3 #define bedtemptable temptable_3 +#elif THERMISTORBED == 4 +#define BNUMTEMPS NUMTEMPS_4 +#define bedtemptable temptable_4 #elif defined BED_USES_THERMISTOR #error No bed thermistor table specified #endif -- cgit v1.2.1 From f51df6f18497ff51e5848125d3588b05a94005f0 Mon Sep 17 00:00:00 2001 From: kliment Date: Fri, 15 Jul 2011 17:14:06 +0200 Subject: Extended pindefs for mega 1280/2560 (analog pins) --- Sprinter/fastio.h | 190 +++++++++++++++++++++++++++--------------------------- 1 file changed, 95 insertions(+), 95 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/fastio.h b/Sprinter/fastio.h index aa5ad0e..1e83d31 100644 --- a/Sprinter/fastio.h +++ b/Sprinter/fastio.h @@ -1265,101 +1265,101 @@ pins #define DIO53_DDR DDRB #define DIO53_PWM NULL -#define AIO0_PIN PINF0 -#define AIO0_RPORT PINF -#define AIO0_WPORT PORTF -#define AIO0_DDR DDRF -#define AIO0_PWM NULL - -#define AIO1_PIN PINF1 -#define AIO1_RPORT PINF -#define AIO1_WPORT PORTF -#define AIO1_DDR DDRF -#define AIO1_PWM NULL - -#define AIO2_PIN PINF2 -#define AIO2_RPORT PINF -#define AIO2_WPORT PORTF -#define AIO2_DDR DDRF -#define AIO2_PWM NULL - -#define AIO3_PIN PINF3 -#define AIO3_RPORT PINF -#define AIO3_WPORT PORTF -#define AIO3_DDR DDRF -#define AIO3_PWM NULL - -#define AIO4_PIN PINF4 -#define AIO4_RPORT PINF -#define AIO4_WPORT PORTF -#define AIO4_DDR DDRF -#define AIO4_PWM NULL - -#define AIO5_PIN PINF5 -#define AIO5_RPORT PINF -#define AIO5_WPORT PORTF -#define AIO5_DDR DDRF -#define AIO5_PWM NULL - -#define AIO6_PIN PINF6 -#define AIO6_RPORT PINF -#define AIO6_WPORT PORTF -#define AIO6_DDR DDRF -#define AIO6_PWM NULL - -#define AIO7_PIN PINF7 -#define AIO7_RPORT PINF -#define AIO7_WPORT PORTF -#define AIO7_DDR DDRF -#define AIO7_PWM NULL - -#define AIO8_PIN PINK0 -#define AIO8_RPORT PINK -#define AIO8_WPORT PORTK -#define AIO8_DDR DDRK -#define AIO8_PWM NULL - -#define AIO9_PIN PINK1 -#define AIO9_RPORT PINK -#define AIO9_WPORT PORTK -#define AIO9_DDR DDRK -#define AIO9_PWM NULL - -#define AIO10_PIN PINK2 -#define AIO10_RPORT PINK -#define AIO10_WPORT PORTK -#define AIO10_DDR DDRK -#define AIO10_PWM NULL - -#define AIO11_PIN PINK3 -#define AIO11_RPORT PINK -#define AIO11_WPORT PORTK -#define AIO11_DDR DDRK -#define AIO11_PWM NULL - -#define AIO12_PIN PINK4 -#define AIO12_RPORT PINK -#define AIO12_WPORT PORTK -#define AIO12_DDR DDRK -#define AIO12_PWM NULL - -#define AIO13_PIN PINK5 -#define AIO13_RPORT PINK -#define AIO13_WPORT PORTK -#define AIO13_DDR DDRK -#define AIO13_PWM NULL - -#define AIO14_PIN PINK6 -#define AIO14_RPORT PINK -#define AIO14_WPORT PORTK -#define AIO14_DDR DDRK -#define AIO14_PWM NULL - -#define AIO15_PIN PINK7 -#define AIO15_RPORT PINK -#define AIO15_WPORT PORTK -#define AIO15_DDR DDRK -#define AIO15_PWM NULL +#define DIO54_PIN PINF0 +#define DIO54_RPORT PINF +#define DIO54_WPORT PORTF +#define DIO54_DDR DDRF +#define DIO54_PWM NULL + +#define DIO55_PIN PINF1 +#define DIO55_RPORT PINF +#define DIO55_WPORT PORTF +#define DIO55_DDR DDRF +#define DIO55_PWM NULL + +#define DIO56_PIN PINF2 +#define DIO56_RPORT PINF +#define DIO56_WPORT PORTF +#define DIO56_DDR DDRF +#define DIO56_PWM NULL + +#define DIO57_PIN PINF3 +#define DIO57_RPORT PINF +#define DIO57_WPORT PORTF +#define DIO57_DDR DDRF +#define DIO57_PWM NULL + +#define DIO58_PIN PINF4 +#define DIO58_RPORT PINF +#define DIO58_WPORT PORTF +#define DIO58_DDR DDRF +#define DIO58_PWM NULL + +#define DIO59_PIN PINF5 +#define DIO59_RPORT PINF +#define DIO59_WPORT PORTF +#define DIO59_DDR DDRF +#define DIO59_PWM NULL + +#define DIO60_PIN PINF6 +#define DIO60_RPORT PINF +#define DIO60_WPORT PORTF +#define DIO60_DDR DDRF +#define DIO60_PWM NULL + +#define DIO61_PIN PINF7 +#define DIO61_RPORT PINF +#define DIO61_WPORT PORTF +#define DIO61_DDR DDRF +#define DIO61_PWM NULL + +#define DIO62_PIN PINK0 +#define DIO62_RPORT PINK +#define DIO62_WPORT PORTK +#define DIO62_DDR DDRK +#define DIO62_PWM NULL + +#define DIO63_PIN PINK1 +#define DIO63_RPORT PINK +#define DIO63_WPORT PORTK +#define DIO63_DDR DDRK +#define DIO63_PWM NULL + +#define DIO64_PIN PINK2 +#define DIO64_RPORT PINK +#define DIO64_WPORT PORTK +#define DIO64_DDR DDRK +#define DIO64_PWM NULL + +#define DIO65_PIN PINK3 +#define DIO65_RPORT PINK +#define DIO65_WPORT PORTK +#define DIO65_DDR DDRK +#define DIO65_PWM NULL + +#define DIO66_PIN PINK4 +#define DIO66_RPORT PINK +#define DIO66_WPORT PORTK +#define DIO66_DDR DDRK +#define DIO66_PWM NULL + +#define DIO67_PIN PINK5 +#define DIO67_RPORT PINK +#define DIO67_WPORT PORTK +#define DIO67_DDR DDRK +#define DIO67_PWM NULL + +#define DIO68_PIN PINK6 +#define DIO68_RPORT PINK +#define DIO68_WPORT PORTK +#define DIO68_DDR DDRK +#define DIO68_PWM NULL + +#define DIO69_PIN PINK7 +#define DIO69_RPORT PINK +#define DIO69_WPORT PORTK +#define DIO69_DDR DDRK +#define DIO69_PWM NULL -- cgit v1.2.1 From b7b099bb0e0a8797b71abdf50e3da6880a86d967 Mon Sep 17 00:00:00 2001 From: kliment Date: Fri, 15 Jul 2011 17:28:09 +0200 Subject: Add extended pin definition for 168/328 to fastio (analog pins) --- Sprinter/fastio.h | 80 +++++++++++++++++++++++++++---------------------------- 1 file changed, 40 insertions(+), 40 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/fastio.h b/Sprinter/fastio.h index 1e83d31..1d28d05 100644 --- a/Sprinter/fastio.h +++ b/Sprinter/fastio.h @@ -179,53 +179,53 @@ pins #define DIO13_PWM NULL -#define AIO0_PIN PINC0 -#define AIO0_RPORT PINC -#define AIO0_WPORT PORTC -#define AIO0_DDR DDRC -#define AIO0_PWM NULL +#define DIO14_PIN PINC0 +#define DIO14_RPORT PINC +#define DIO14_WPORT PORTC +#define DIO14_DDR DDRC +#define DIO14_PWM NULL -#define AIO1_PIN PINC1 -#define AIO1_RPORT PINC -#define AIO1_WPORT PORTC -#define AIO1_DDR DDRC -#define AIO1_PWM NULL +#define DIO15_PIN PINC1 +#define DIO15_RPORT PINC +#define DIO15_WPORT PORTC +#define DIO15_DDR DDRC +#define DIO15_PWM NULL -#define AIO2_PIN PINC2 -#define AIO2_RPORT PINC -#define AIO2_WPORT PORTC -#define AIO2_DDR DDRC -#define AIO2_PWM NULL +#define DIO16_PIN PINC2 +#define DIO16_RPORT PINC +#define DIO16_WPORT PORTC +#define DIO16_DDR DDRC +#define DIO16_PWM NULL -#define AIO3_PIN PINC3 -#define AIO3_RPORT PINC -#define AIO3_WPORT PORTC -#define AIO3_DDR DDRC -#define AIO3_PWM NULL +#define DIO17_PIN PINC3 +#define DIO17_RPORT PINC +#define DIO17_WPORT PORTC +#define DIO17_DDR DDRC +#define DIO17_PWM NULL -#define AIO4_PIN PINC4 -#define AIO4_RPORT PINC -#define AIO4_WPORT PORTC -#define AIO4_DDR DDRC -#define AIO4_PWM NULL +#define DIO18_PIN PINC4 +#define DIO18_RPORT PINC +#define DIO18_WPORT PORTC +#define DIO18_DDR DDRC +#define DIO18_PWM NULL -#define AIO5_PIN PINC5 -#define AIO5_RPORT PINC -#define AIO5_WPORT PORTC -#define AIO5_DDR DDRC -#define AIO5_PWM NULL +#define DIO19_PIN PINC5 +#define DIO19_RPORT PINC +#define DIO19_WPORT PORTC +#define DIO19_DDR DDRC +#define DIO19_PWM NULL -#define AIO6_PIN PINC6 -#define AIO6_RPORT PINC -#define AIO6_WPORT PORTC -#define AIO6_DDR DDRC -#define AIO6_PWM NULL +#define DIO20_PIN PINC6 +#define DIO20_RPORT PINC +#define DIO20_WPORT PORTC +#define DIO20_DDR DDRC +#define DIO20_PWM NULL -#define AIO7_PIN PINC7 -#define AIO7_RPORT PINC -#define AIO7_WPORT PORTC -#define AIO7_DDR DDRC -#define AIO7_PWM NULL +#define DIO21_PIN PINC7 +#define DIO21_RPORT PINC +#define DIO21_WPORT PORTC +#define DIO21_DDR DDRC +#define DIO21_PWM NULL -- cgit v1.2.1 From b31c7a837ff5baff89043f3c06b1b2191ed9f79d Mon Sep 17 00:00:00 2001 From: kliment Date: Fri, 15 Jul 2011 20:40:43 +0200 Subject: Remove float conversions from step loop --- Sprinter/Sprinter.pde | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index 8bb68d7..4d7aa53 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -1170,8 +1170,10 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov #ifdef DEBUG_MOVE_TIME unsigned long startmove = micros(); #endif - - //move until no more steps remain + long long_steps_per_sqr_second=(long) steps_per_sqr_second; + long long_min_speed_steps_per_second=(long) min_speed_steps_per_second; + long long_max_speed_steps_per_second=(long) max_speed_steps_per_second; + //move until no more steps remain THERE SHOULD BE NO FLOAT CALCS INSIDE THIS LOOP while(axis_steps_remaining[0] + axis_steps_remaining[1] + axis_steps_remaining[2] + axis_steps_remaining[3] > 0) { #ifdef DISABLE_CHECK_DURING_ACC if(!accelerating && !decelerating) { @@ -1197,8 +1199,7 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov if (acceleration_enabled && steps_done == 0) { interval = max_interval; } else if (acceleration_enabled && steps_done <= plateau_steps) { - long current_speed = (long) ((((long) steps_per_sqr_second) / 10000) - * ((micros() - start_move_micros) / 100) + (long) min_speed_steps_per_second); + long current_speed = (long_steps_per_sqr_second / 10000)* ((micros() - start_move_micros) / 100) + long_min_speed_steps_per_second; interval = 100000000 / current_speed; if (interval < full_interval) { accelerating = false; @@ -1215,8 +1216,7 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov accelerating = true; decelerating = true; } - long current_speed = (long) ((long) max_speed_steps_per_second - ((((long) steps_per_sqr_second) / 10000) - * ((micros() - start_move_micros) / 100))); + long current_speed = long_max_speed_steps_per_second - (((long_steps_per_sqr_second / 10000) * ((micros() - start_move_micros) / 100))); interval = 100000000 / current_speed; if (interval > max_interval) interval = max_interval; -- cgit v1.2.1 From 57f4c09d1783569609c4116d260978f5e47eb049 Mon Sep 17 00:00:00 2001 From: kliment Date: Fri, 15 Jul 2011 21:06:45 +0200 Subject: Revert "Remove float conversions from step loop" This reverts commit b31c7a837ff5baff89043f3c06b1b2191ed9f79d. --- Sprinter/Sprinter.pde | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index 4d7aa53..8bb68d7 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -1170,10 +1170,8 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov #ifdef DEBUG_MOVE_TIME unsigned long startmove = micros(); #endif - long long_steps_per_sqr_second=(long) steps_per_sqr_second; - long long_min_speed_steps_per_second=(long) min_speed_steps_per_second; - long long_max_speed_steps_per_second=(long) max_speed_steps_per_second; - //move until no more steps remain THERE SHOULD BE NO FLOAT CALCS INSIDE THIS LOOP + + //move until no more steps remain while(axis_steps_remaining[0] + axis_steps_remaining[1] + axis_steps_remaining[2] + axis_steps_remaining[3] > 0) { #ifdef DISABLE_CHECK_DURING_ACC if(!accelerating && !decelerating) { @@ -1199,7 +1197,8 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov if (acceleration_enabled && steps_done == 0) { interval = max_interval; } else if (acceleration_enabled && steps_done <= plateau_steps) { - long current_speed = (long_steps_per_sqr_second / 10000)* ((micros() - start_move_micros) / 100) + long_min_speed_steps_per_second; + long current_speed = (long) ((((long) steps_per_sqr_second) / 10000) + * ((micros() - start_move_micros) / 100) + (long) min_speed_steps_per_second); interval = 100000000 / current_speed; if (interval < full_interval) { accelerating = false; @@ -1216,7 +1215,8 @@ inline void linear_move(unsigned long axis_steps_remaining[]) // make linear mov accelerating = true; decelerating = true; } - long current_speed = long_max_speed_steps_per_second - (((long_steps_per_sqr_second / 10000) * ((micros() - start_move_micros) / 100))); + long current_speed = (long) ((long) max_speed_steps_per_second - ((((long) steps_per_sqr_second) / 10000) + * ((micros() - start_move_micros) / 100))); interval = 100000000 / current_speed; if (interval > max_interval) interval = max_interval; -- cgit v1.2.1 From ef0ad69571bf9e8ebe134280b1d584919790f878 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Sat, 16 Jul 2011 11:57:42 +0200 Subject: Bugfix: smoothed temperature was initialized without respecting HEATER_USES_* --- Sprinter/Sprinter.pde | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Sprinter') diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index b31a629..79c66e6 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -133,7 +133,7 @@ float tt = 0, bt = 0; int temp_iState_max = 100 * PID_INTEGRAL_DRIVE_MAX / PID_IGAIN; #endif #ifdef SMOOTHING - uint32_t nma = SMOOTHFACTOR * analogRead(TEMP_0_PIN); + uint32_t nma = 0; #endif #ifdef WATCHPERIOD int watch_raw = -1000; @@ -1268,6 +1268,7 @@ inline void manage_heater() current_raw = read_max6675(); #endif #ifdef SMOOTHING + if (!nma) nma = SMOOTHFACTOR * current_raw; nma = (nma + current_raw) - (nma / SMOOTHFACTOR); current_raw = nma / SMOOTHFACTOR; #endif -- cgit v1.2.1 From 1b5dab70badff39191be9860f4515677d7670582 Mon Sep 17 00:00:00 2001 From: Alessandro Ranellucci Date: Sat, 16 Jul 2011 14:30:06 +0200 Subject: Bugfix: homing to max endstops didn't work because current_position was always reset to 0. --- Sprinter/Sprinter.pde | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index b31a629..d07feb5 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -471,8 +471,7 @@ inline void process_commands() case 28: //G28 Home all Axis one at a time saved_feedrate = feedrate; for(int i=0; i < NUM_AXIS; i++) { - destination[i] = 0; - current_position[i] = 0; + destination[i] = current_position[i]; } feedrate = 0; @@ -492,8 +491,8 @@ inline void process_commands() destination[0] = 10 * X_HOME_DIR; prepare_move(); - current_position[0] = 0; - destination[0] = 0; + current_position[0] = (X_HOME_DIR == -1) ? 0 : X_MAX_LENGTH; + destination[0] = current_position[0]; feedrate = 0; } } @@ -512,8 +511,8 @@ inline void process_commands() destination[1] = 10 * Y_HOME_DIR; prepare_move(); - current_position[1] = 0; - destination[1] = 0; + current_position[1] = (Y_HOME_DIR == -1) ? 0 : Y_MAX_LENGTH; + destination[1] = current_position[1]; feedrate = 0; } } @@ -532,8 +531,8 @@ inline void process_commands() destination[2] = 10 * Z_HOME_DIR; prepare_move(); - current_position[2] = 0; - destination[2] = 0; + current_position[2] = (Z_HOME_DIR == -1) ? 0 : Z_MAX_LENGTH; + destination[2] = current_position[2]; feedrate = 0; } -- cgit v1.2.1 From 3c44f0b3e3263e8c335b2f0c67743c60a4f4a9da Mon Sep 17 00:00:00 2001 From: kliment Date: Sat, 16 Jul 2011 21:58:17 +0200 Subject: Ignore bedtemp if no bed temp pin defined --- Sprinter/Sprinter.pde | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Sprinter') diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index 7e2a4fa..4be4788 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -663,7 +663,9 @@ inline void process_commands() #endif break; case 140: // M140 set bed temp - if (code_seen('S')) target_bed_raw = temp2analogBed(code_value()); + #if TEMP_1_PIN > -1 || defined BED_USES_AD595 + if (code_seen('S')) target_bed_raw = temp2analogBed(code_value()); + #endif break; case 105: // M105 #if (TEMP_0_PIN > -1) || defined (HEATER_USES_MAX6675)|| defined HEATER_USES_AD595 -- cgit v1.2.1 From b136a652c4a244038d0db40894e3558805d7c73a Mon Sep 17 00:00:00 2001 From: kliment Date: Sun, 17 Jul 2011 14:02:35 +0200 Subject: Add extra config for homing feedrate - fixes #28 --- Sprinter/Configuration.h | 1 + Sprinter/Sprinter.pde | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/Configuration.h b/Sprinter/Configuration.h index a9cb67f..5f1e1d4 100644 --- a/Sprinter/Configuration.h +++ b/Sprinter/Configuration.h @@ -84,6 +84,7 @@ bool axis_relative_modes[] = {false, false, false, false}; // If you enable this, make sure STEP_DELAY_MICROS is disabled. (except for Gen6: both need to be enabled.) //#define STEP_DELAY_RATIO 0.25 +float homing_feedrate[] = {1500,1500,120}; // Comment this to disable ramp acceleration #define RAMP_ACCELERATION 1 diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index 4be4788..429dcb7 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -481,7 +481,7 @@ inline void process_commands() if ((X_MIN_PIN > -1 && X_HOME_DIR==-1) || (X_MAX_PIN > -1 && X_HOME_DIR==1)){ current_position[0] = 0; destination[0] = 1.5 * X_MAX_LENGTH * X_HOME_DIR; - feedrate = max_start_speed_units_per_second[0] * 60; + feedrate = homing_feedrate[0]; prepare_move(); current_position[0] = 0; @@ -501,7 +501,7 @@ inline void process_commands() if ((Y_MIN_PIN > -1 && Y_HOME_DIR==-1) || (Y_MAX_PIN > -1 && Y_HOME_DIR==1)){ current_position[1] = 0; destination[1] = 1.5 * Y_MAX_LENGTH * Y_HOME_DIR; - feedrate = max_start_speed_units_per_second[1] * 60; + feedrate = homing_feedrate[1]; prepare_move(); current_position[1] = 0; @@ -521,7 +521,7 @@ inline void process_commands() if ((Z_MIN_PIN > -1 && Z_HOME_DIR==-1) || (Z_MAX_PIN > -1 && Z_HOME_DIR==1)){ current_position[2] = 0; destination[2] = 1.5 * Z_MAX_LENGTH * Z_HOME_DIR; - feedrate = max_feedrate[2]/2; + feedrate = homing_feedrate[2]; prepare_move(); current_position[2] = 0; -- cgit v1.2.1 From 0c376e76d1c19eb1f595123c8fb43ca6a6ae8f13 Mon Sep 17 00:00:00 2001 From: kliment Date: Sun, 17 Jul 2011 14:09:14 +0200 Subject: Add some explanations to config, change some variables to #defines. Fixes #36 --- Sprinter/Configuration.h | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'Sprinter') diff --git a/Sprinter/Configuration.h b/Sprinter/Configuration.h index 5f1e1d4..5d64c7b 100644 --- a/Sprinter/Configuration.h +++ b/Sprinter/Configuration.h @@ -29,6 +29,8 @@ float axis_steps_per_unit[] = {80, 80, 3200/1.25,700}; #define ENDSTOPPULLUPS 1 // Comment this out (using // at the start of the line) to disable the endstop pullup resistors // The pullups are needed if you directly connect a mechanical endswitch between the signal and ground pins. const bool ENDSTOPS_INVERTING = false; //set to true to invert the logic of the endstops +//If your axes are only moving in one direction, make sure the endstops are connected properly. +//If your axes move in one direction ONLY when the endstops are triggered, set ENDSTOPS_INVERTING to true here // This determines the communication speed of the printer #define BAUDRATE 115200 @@ -42,10 +44,10 @@ const bool ENDSTOPS_INVERTING = false; //set to true to invert the logic of the #include "thermistortables.h" // For Inverting Stepper Enable Pins (Active Low) use 0, Non Inverting (Active High) use 1 -const bool X_ENABLE_ON = 0; -const bool Y_ENABLE_ON = 0; -const bool Z_ENABLE_ON = 0; -const bool E_ENABLE_ON = 0; +#define X_ENABLE_ON 0 +#define Y_ENABLE_ON 0 +#define Z_ENABLE_ON 0 +#define E_ENABLE_ON 0 // Disables axis when it's not being used. const bool DISABLE_X = false; @@ -61,9 +63,9 @@ const bool INVERT_E_DIR = false; //// ENDSTOP SETTINGS: // Sets direction of endstops when homing; 1=MAX, -1=MIN -const int X_HOME_DIR = -1; -const int Y_HOME_DIR = -1; -const int Z_HOME_DIR = -1; +#define X_HOME_DIR -1 +#define Y_HOME_DIR -1 +#define Z_HOME_DIR -1 const bool min_software_endstops = false; //If true, axis won't move to coordinates less than zero. const bool max_software_endstops = true; //If true, axis won't move to coordinates greater than the defined lengths below. @@ -74,6 +76,7 @@ const int Z_MAX_LENGTH = 100; //// MOVEMENT SETTINGS const int NUM_AXIS = 4; // The axis order in all axis related arrays is X, Y, Z, E float max_feedrate[] = {200000, 200000, 240, 500000}; +float homing_feedrate[] = {1500,1500,120}; bool axis_relative_modes[] = {false, false, false, false}; // Min step delay in microseconds. If you are experiencing missing steps, try to raise the delay microseconds, but be aware this @@ -84,7 +87,6 @@ bool axis_relative_modes[] = {false, false, false, false}; // If you enable this, make sure STEP_DELAY_MICROS is disabled. (except for Gen6: both need to be enabled.) //#define STEP_DELAY_RATIO 0.25 -float homing_feedrate[] = {1500,1500,120}; // Comment this to disable ramp acceleration #define RAMP_ACCELERATION 1 -- cgit v1.2.1 From 73844d6e96fb85f1a5931a941d24bc85dcc4cec6 Mon Sep 17 00:00:00 2001 From: Emery Roth Date: Mon, 18 Jul 2011 00:44:08 -0400 Subject: Added Ramps 1.3 pin assignments for E1 (second extruder) stepper driver MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is my first commit…Please don't hurt me if i screw up! --- Sprinter/pins.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Sprinter') diff --git a/Sprinter/pins.h b/Sprinter/pins.h index 1bd6702..720f3a9 100644 --- a/Sprinter/pins.h +++ b/Sprinter/pins.h @@ -246,6 +246,10 @@ #define E_DIR_PIN 28 #define E_ENABLE_PIN 24 +#define E_1_STEP_PIN 36 +#define E_1_DIR_PIN 34 +#define E_1_ENABLE_PIN 30 + #define SDPOWER -1 #define SDSS 53 #define LED_PIN 13 -- cgit v1.2.1