Move heater macros from config.h to heater.h, as they're

not meant to be user configurable.
This commit is contained in:
Markus Hitter 2010-10-07 22:19:34 +02:00
parent 468b212077
commit 9839ac9fff
2 changed files with 9 additions and 12 deletions

View File

@ -180,18 +180,6 @@
// --------------------------------------------------------------------------
// you shouldn't need to edit anything below this line
/*
Heater
*/
#ifdef HEATER_PWM
#define enable_heater() do { TCCR0A |= MASK(COM0A1); } while (0)
#define disable_heater() do { TCCR0A &= ~MASK(COM0A1); } while (0)
#else
#define enable_heater() WRITE(HEATER_PIN, 1)
#define disable_heater() WRITE(HEATER_PIN, 0)
#endif
/*
fan
*/

View File

@ -1,8 +1,17 @@
#ifndef _HEATER_H
#define _HEATER_H
#include "config.h"
#include <stdint.h>
#ifdef HEATER_PWM
#define enable_heater() do { TCCR0A |= MASK(COM0A1); } while (0)
#define disable_heater() do { TCCR0A &= ~MASK(COM0A1); } while (0)
#else
#define enable_heater() WRITE(HEATER_PIN, 1)
#define disable_heater() WRITE(HEATER_PIN, 0)
#endif
// extruder heater PID factors
// google "PID without a PHD" if you don't understand this PID stuff
extern int32_t p_factor;