Further support for 6 extruders
This commit is contained in:
parent
8d95019442
commit
44571775bd
6 changed files with 53 additions and 7 deletions
|
@ -104,6 +104,12 @@ uint8_t adc_pins[] = {
|
||||||
#if HAS_TEMP_ADC_0
|
#if HAS_TEMP_ADC_0
|
||||||
TEMP_0_PIN,
|
TEMP_0_PIN,
|
||||||
#endif
|
#endif
|
||||||
|
#if HAS_HEATED_BED
|
||||||
|
TEMP_BED_PIN,
|
||||||
|
#endif
|
||||||
|
#if HAS_HEATED_CHAMBER
|
||||||
|
TEMP_CHAMBER_PIN,
|
||||||
|
#endif
|
||||||
#if HAS_TEMP_ADC_1
|
#if HAS_TEMP_ADC_1
|
||||||
TEMP_1_PIN,
|
TEMP_1_PIN,
|
||||||
#endif
|
#endif
|
||||||
|
@ -116,8 +122,8 @@ uint8_t adc_pins[] = {
|
||||||
#if HAS_TEMP_ADC_4
|
#if HAS_TEMP_ADC_4
|
||||||
TEMP_4_PIN,
|
TEMP_4_PIN,
|
||||||
#endif
|
#endif
|
||||||
#if HAS_HEATED_BED
|
#if HAS_TEMP_ADC_5
|
||||||
TEMP_BED_PIN,
|
TEMP_5_PIN,
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
||||||
FILWIDTH_PIN,
|
FILWIDTH_PIN,
|
||||||
|
@ -128,6 +134,12 @@ enum TEMP_PINS : char {
|
||||||
#if HAS_TEMP_ADC_0
|
#if HAS_TEMP_ADC_0
|
||||||
TEMP_0,
|
TEMP_0,
|
||||||
#endif
|
#endif
|
||||||
|
#if HAS_HEATED_BED
|
||||||
|
TEMP_BED,
|
||||||
|
#endif
|
||||||
|
#if HAS_HEATED_CHAMBER
|
||||||
|
TEMP_CHAMBER,
|
||||||
|
#endif
|
||||||
#if HAS_TEMP_ADC_1
|
#if HAS_TEMP_ADC_1
|
||||||
TEMP_1,
|
TEMP_1,
|
||||||
#endif
|
#endif
|
||||||
|
@ -140,8 +152,8 @@ enum TEMP_PINS : char {
|
||||||
#if HAS_TEMP_ADC_4
|
#if HAS_TEMP_ADC_4
|
||||||
TEMP_4,
|
TEMP_4,
|
||||||
#endif
|
#endif
|
||||||
#if HAS_HEATED_BED
|
#if HAS_TEMP_ADC_5
|
||||||
TEMP_BED,
|
TEMP_5,
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
||||||
FILWIDTH,
|
FILWIDTH,
|
||||||
|
@ -268,6 +280,12 @@ void HAL_adc_start_conversion(const uint8_t adc_pin) {
|
||||||
#if HAS_TEMP_ADC_0
|
#if HAS_TEMP_ADC_0
|
||||||
case TEMP_0_PIN: pin_index = TEMP_0; break;
|
case TEMP_0_PIN: pin_index = TEMP_0; break;
|
||||||
#endif
|
#endif
|
||||||
|
#if HAS_HEATED_BED
|
||||||
|
case TEMP_BED_PIN: pin_index = TEMP_BED; break;
|
||||||
|
#endif
|
||||||
|
#if HAS_HEATED_CHAMBER
|
||||||
|
case TEMP_CHAMBER_PIN: pin_index = TEMP_CHAMBER; break;
|
||||||
|
#endif
|
||||||
#if HAS_TEMP_ADC_1
|
#if HAS_TEMP_ADC_1
|
||||||
case TEMP_1_PIN: pin_index = TEMP_1; break;
|
case TEMP_1_PIN: pin_index = TEMP_1; break;
|
||||||
#endif
|
#endif
|
||||||
|
@ -280,8 +298,8 @@ void HAL_adc_start_conversion(const uint8_t adc_pin) {
|
||||||
#if HAS_TEMP_ADC_4
|
#if HAS_TEMP_ADC_4
|
||||||
case TEMP_4_PIN: pin_index = TEMP_4; break;
|
case TEMP_4_PIN: pin_index = TEMP_4; break;
|
||||||
#endif
|
#endif
|
||||||
#if HAS_HEATED_BED
|
#if HAS_TEMP_ADC_5
|
||||||
case TEMP_BED_PIN: pin_index = TEMP_BED; break;
|
case TEMP_5_PIN: pin_index = TEMP_5; break;
|
||||||
#endif
|
#endif
|
||||||
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
#if ENABLED(FILAMENT_WIDTH_SENSOR)
|
||||||
case FILWIDTH_PIN: pin_index = FILWIDTH; break;
|
case FILWIDTH_PIN: pin_index = FILWIDTH; break;
|
||||||
|
|
|
@ -914,6 +914,7 @@
|
||||||
#define HAS_TEMP_ADC_2 HAS_ADC_TEST(2)
|
#define HAS_TEMP_ADC_2 HAS_ADC_TEST(2)
|
||||||
#define HAS_TEMP_ADC_3 HAS_ADC_TEST(3)
|
#define HAS_TEMP_ADC_3 HAS_ADC_TEST(3)
|
||||||
#define HAS_TEMP_ADC_4 HAS_ADC_TEST(4)
|
#define HAS_TEMP_ADC_4 HAS_ADC_TEST(4)
|
||||||
|
#define HAS_TEMP_ADC_5 HAS_ADC_TEST(5)
|
||||||
#define HAS_TEMP_ADC_BED HAS_ADC_TEST(BED)
|
#define HAS_TEMP_ADC_BED HAS_ADC_TEST(BED)
|
||||||
#define HAS_TEMP_ADC_CHAMBER HAS_ADC_TEST(CHAMBER)
|
#define HAS_TEMP_ADC_CHAMBER HAS_ADC_TEST(CHAMBER)
|
||||||
|
|
||||||
|
@ -927,6 +928,7 @@
|
||||||
#define HAS_HEATER_2 (PIN_EXISTS(HEATER_2))
|
#define HAS_HEATER_2 (PIN_EXISTS(HEATER_2))
|
||||||
#define HAS_HEATER_3 (PIN_EXISTS(HEATER_3))
|
#define HAS_HEATER_3 (PIN_EXISTS(HEATER_3))
|
||||||
#define HAS_HEATER_4 (PIN_EXISTS(HEATER_4))
|
#define HAS_HEATER_4 (PIN_EXISTS(HEATER_4))
|
||||||
|
#define HAS_HEATER_5 (PIN_EXISTS(HEATER_5))
|
||||||
#define HAS_HEATER_BED (PIN_EXISTS(HEATER_BED))
|
#define HAS_HEATER_BED (PIN_EXISTS(HEATER_BED))
|
||||||
|
|
||||||
// Shorthand for common combinations
|
// Shorthand for common combinations
|
||||||
|
@ -1106,6 +1108,10 @@
|
||||||
#define HEATER_4_INVERTING false
|
#define HEATER_4_INVERTING false
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if HAS_HEATER_5 && !defined(HEATER_5_INVERTING)
|
||||||
|
#define HEATER_5_INVERTING false
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Helper Macros for heaters and extruder fan
|
* Helper Macros for heaters and extruder fan
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -143,6 +143,15 @@ void menu_info_thermistors() {
|
||||||
STATIC_ITEM(MSG_INFO_MAX_TEMP ": " STRINGIFY(HEATER_4_MAXTEMP), false);
|
STATIC_ITEM(MSG_INFO_MAX_TEMP ": " STRINGIFY(HEATER_4_MAXTEMP), false);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if TEMP_SENSOR_5 != 0
|
||||||
|
#undef THERMISTOR_ID
|
||||||
|
#define THERMISTOR_ID TEMP_SENSOR_5
|
||||||
|
#include "../thermistornames.h"
|
||||||
|
STATIC_ITEM("T5: " THERMISTOR_NAME, false, true);
|
||||||
|
STATIC_ITEM(MSG_INFO_MIN_TEMP ": " STRINGIFY(HEATER_5_MINTEMP), false);
|
||||||
|
STATIC_ITEM(MSG_INFO_MAX_TEMP ": " STRINGIFY(HEATER_5_MAXTEMP), false);
|
||||||
|
#endif
|
||||||
|
|
||||||
#if HAS_HEATED_BED
|
#if HAS_HEATED_BED
|
||||||
#undef THERMISTOR_ID
|
#undef THERMISTOR_ID
|
||||||
#define THERMISTOR_ID TEMP_SENSOR_BED
|
#define THERMISTOR_ID TEMP_SENSOR_BED
|
||||||
|
|
|
@ -422,7 +422,7 @@ void menu_temperature() {
|
||||||
//
|
//
|
||||||
// Preheat for Material 1 and 2
|
// Preheat for Material 1 and 2
|
||||||
//
|
//
|
||||||
#if TEMP_SENSOR_1 != 0 || TEMP_SENSOR_2 != 0 || TEMP_SENSOR_3 != 0 || TEMP_SENSOR_4 != 0 || HAS_HEATED_BED
|
#if TEMP_SENSOR_1 != 0 || TEMP_SENSOR_2 != 0 || TEMP_SENSOR_3 != 0 || TEMP_SENSOR_4 != 0 || TEMP_SENSOR_5 != 0 || HAS_HEATED_BED
|
||||||
MENU_ITEM(submenu, MSG_PREHEAT_1, menu_preheat_m1);
|
MENU_ITEM(submenu, MSG_PREHEAT_1, menu_preheat_m1);
|
||||||
MENU_ITEM(submenu, MSG_PREHEAT_2, menu_preheat_m2);
|
MENU_ITEM(submenu, MSG_PREHEAT_2, menu_preheat_m2);
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -191,6 +191,16 @@
|
||||||
#define HEATER_4_TEMPTABLE_LEN 0
|
#define HEATER_4_TEMPTABLE_LEN 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if THERMISTORHEATER_5
|
||||||
|
#define HEATER_5_TEMPTABLE TT_NAME(THERMISTORHEATER_5)
|
||||||
|
#define HEATER_5_TEMPTABLE_LEN COUNT(HEATER_5_TEMPTABLE)
|
||||||
|
#elif defined(HEATER_5_USES_THERMISTOR)
|
||||||
|
#error "No heater 5 thermistor table specified"
|
||||||
|
#else
|
||||||
|
#define HEATER_5_TEMPTABLE NULL
|
||||||
|
#define HEATER_5_TEMPTABLE_LEN 0
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef THERMISTORBED
|
#ifdef THERMISTORBED
|
||||||
#define BEDTEMPTABLE TT_NAME(THERMISTORBED)
|
#define BEDTEMPTABLE TT_NAME(THERMISTORBED)
|
||||||
#define BEDTEMPTABLE_LEN COUNT(BEDTEMPTABLE)
|
#define BEDTEMPTABLE_LEN COUNT(BEDTEMPTABLE)
|
||||||
|
|
|
@ -77,6 +77,9 @@
|
||||||
#if PIN_EXISTS(TEMP_4) && TEMP_4_PIN < NUM_ANALOG_INPUTS
|
#if PIN_EXISTS(TEMP_4) && TEMP_4_PIN < NUM_ANALOG_INPUTS
|
||||||
REPORT_NAME_ANALOG(__LINE__, TEMP_4_PIN)
|
REPORT_NAME_ANALOG(__LINE__, TEMP_4_PIN)
|
||||||
#endif
|
#endif
|
||||||
|
#if PIN_EXISTS(TEMP_5) && TEMP_5_PIN < NUM_ANALOG_INPUTS
|
||||||
|
REPORT_NAME_ANALOG(__LINE__, TEMP_5_PIN)
|
||||||
|
#endif
|
||||||
#if PIN_EXISTS(TEMP_BED) && TEMP_BED_PIN < NUM_ANALOG_INPUTS
|
#if PIN_EXISTS(TEMP_BED) && TEMP_BED_PIN < NUM_ANALOG_INPUTS
|
||||||
REPORT_NAME_ANALOG(__LINE__, TEMP_BED_PIN)
|
REPORT_NAME_ANALOG(__LINE__, TEMP_BED_PIN)
|
||||||
#endif
|
#endif
|
||||||
|
|
Reference in a new issue