LCD_PWM removed (will be solved other way)
This commit is contained in:
parent
bb6c8703e8
commit
3ddbac6056
4 changed files with 2 additions and 47 deletions
|
@ -274,10 +274,6 @@ extern void homeaxis(int axis);
|
|||
extern unsigned char fanSpeedSoftPwm;
|
||||
#endif
|
||||
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
extern unsigned char lcdSoftPwm;
|
||||
extern unsigned char lcdBlinkDelay;
|
||||
#endif
|
||||
|
||||
#ifdef FILAMENT_SENSOR
|
||||
extern float filament_width_nominal; //holds the theoretical filament diameter ie., 3.00 or 1.75
|
||||
|
|
|
@ -1008,9 +1008,6 @@ void setup()
|
|||
SET_OUTPUT(CONTROLLERFAN_PIN); //Set pin used for driver cooling fan
|
||||
#endif
|
||||
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
SET_OUTPUT(LCD_PWM_PIN); //Set pin used for driver cooling fan
|
||||
#endif
|
||||
|
||||
#ifdef DIGIPOT_I2C
|
||||
digipot_i2c_init();
|
||||
|
|
|
@ -103,8 +103,8 @@
|
|||
|
||||
#ifdef NEWPANEL
|
||||
|
||||
#define LCD_PWM_PIN -1//32 // lcd backlight brightnes pwm control pin
|
||||
#define LCD_PWM_MAX 0x0f // lcd pwm maximum value (0x07=64Hz, 0x0f=32Hz, 0x1f=16Hz)
|
||||
//#define LCD_PWM_PIN -1//32 // lcd backlight brightnes pwm control pin
|
||||
//#define LCD_PWM_MAX 0x0f // lcd pwm maximum value (0x07=64Hz, 0x0f=32Hz, 0x1f=16Hz)
|
||||
|
||||
#define BEEPER 84 // Beeper on AUX-4
|
||||
#define LCD_PINS_RS 82
|
||||
|
|
|
@ -97,10 +97,6 @@ float current_temperature_bed = 0.0;
|
|||
unsigned char fanSpeedSoftPwm;
|
||||
#endif
|
||||
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
unsigned char lcdSoftPwm = (LCD_PWM_MAX * 2 + 1); //set default value to maximum
|
||||
unsigned char lcdBlinkDelay = 0; //lcd blinking delay (0 = no blink)
|
||||
#endif
|
||||
|
||||
unsigned char soft_pwm_bed;
|
||||
|
||||
|
@ -156,11 +152,6 @@ static volatile bool temp_meas_ready = false;
|
|||
static unsigned long extruder_autofan_last_check;
|
||||
#endif
|
||||
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
static unsigned char soft_pwm_lcd = 0;
|
||||
static unsigned char lcd_blink_delay = 0;
|
||||
static bool lcd_blink_on = false;
|
||||
#endif
|
||||
|
||||
#if EXTRUDERS > 3
|
||||
# error Unsupported number of extruders
|
||||
|
@ -1056,11 +1047,6 @@ void tp_init()
|
|||
#endif
|
||||
#ifdef FAN_SOFT_PWM
|
||||
soft_pwm_fan = fanSpeedSoftPwm / 2;
|
||||
#endif
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
soft_pwm_lcd = lcdSoftPwm / 2;
|
||||
lcd_blink_delay = lcdBlinkDelay;
|
||||
lcd_blink_on = true;
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
@ -1631,27 +1617,6 @@ ISR(TIMER0_COMPB_vect)
|
|||
WRITE(HEATER_1_PIN,0);
|
||||
#endif
|
||||
}
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
if ((pwm_count & LCD_PWM_MAX) == 0)
|
||||
{
|
||||
if (lcd_blink_delay)
|
||||
{
|
||||
lcd_blink_delay--;
|
||||
if (lcd_blink_delay == 0)
|
||||
{
|
||||
lcd_blink_delay = lcdBlinkDelay;
|
||||
lcd_blink_on = !lcd_blink_on;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lcd_blink_delay = lcdBlinkDelay;
|
||||
lcd_blink_on = true;
|
||||
}
|
||||
soft_pwm_lcd = (lcd_blink_on) ? (lcdSoftPwm / 2) : 0;
|
||||
if (soft_pwm_lcd > 0) WRITE(LCD_PWM_PIN,1); else WRITE(LCD_PWM_PIN,0);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if EXTRUDERS > 1
|
||||
if(soft_pwm_1 < pwm_count) WRITE(HEATER_1_PIN,0);
|
||||
|
@ -1665,9 +1630,6 @@ ISR(TIMER0_COMPB_vect)
|
|||
#ifdef FAN_SOFT_PWM
|
||||
if(soft_pwm_fan < pwm_count) WRITE(FAN_PIN,0);
|
||||
#endif
|
||||
#if defined(LCD_PWM_PIN) && (LCD_PWM_PIN > -1)
|
||||
if (soft_pwm_lcd < (pwm_count & LCD_PWM_MAX)) WRITE(LCD_PWM_PIN,0);
|
||||
#endif
|
||||
|
||||
pwm_count += (1 << SOFT_PWM_SCALE);
|
||||
pwm_count &= 0x7f;
|
||||
|
|
Loading…
Reference in a new issue