fix error: lvalue required as unary '&' operand when heater pin is not a PWMable pin.
This commit is contained in:
parent
a35c304762
commit
dba60ba1eb
|
|
@ -51,55 +51,55 @@ pins
|
|||
#define DIO2_RPORT PINE
|
||||
#define DIO2_WPORT PORTE
|
||||
#define DIO2_DDR DDRE
|
||||
#define DIO2_PWM OCR3BL
|
||||
#define DIO2_PWM &OCR3BL
|
||||
|
||||
#define DIO3_PIN PINE5
|
||||
#define DIO3_RPORT PINE
|
||||
#define DIO3_WPORT PORTE
|
||||
#define DIO3_DDR DDRE
|
||||
#define DIO3_PWM OCR3CL
|
||||
#define DIO3_PWM &OCR3CL
|
||||
|
||||
#define DIO4_PIN PING5
|
||||
#define DIO4_RPORT PING
|
||||
#define DIO4_WPORT PORTG
|
||||
#define DIO4_DDR DDRG
|
||||
#define DIO4_PWM OCR0B
|
||||
#define DIO4_PWM &OCR0B
|
||||
|
||||
#define DIO5_PIN PINE3
|
||||
#define DIO5_RPORT PINE
|
||||
#define DIO5_WPORT PORTE
|
||||
#define DIO5_DDR DDRE
|
||||
#define DIO5_PWM OCR3AL
|
||||
#define DIO5_PWM &OCR3AL
|
||||
|
||||
#define DIO6_PIN PINH3
|
||||
#define DIO6_RPORT PINH
|
||||
#define DIO6_WPORT PORTH
|
||||
#define DIO6_DDR DDRH
|
||||
#define DIO6_PWM OCR4AL
|
||||
#define DIO6_PWM &OCR4AL
|
||||
|
||||
#define DIO7_PIN PINH4
|
||||
#define DIO7_RPORT PINH
|
||||
#define DIO7_WPORT PORTH
|
||||
#define DIO7_DDR DDRH
|
||||
#define DIO7_PWM OCR4BL
|
||||
#define DIO7_PWM &OCR4BL
|
||||
|
||||
#define DIO8_PIN PINH5
|
||||
#define DIO8_RPORT PINH
|
||||
#define DIO8_WPORT PORTH
|
||||
#define DIO8_DDR DDRH
|
||||
#define DIO8_PWM OCR4CL
|
||||
#define DIO8_PWM &OCR4CL
|
||||
|
||||
#define DIO9_PIN PINH6
|
||||
#define DIO9_RPORT PINH
|
||||
#define DIO9_WPORT PORTH
|
||||
#define DIO9_DDR DDRH
|
||||
#define DIO9_PWM OCR2B
|
||||
#define DIO9_PWM &OCR2B
|
||||
|
||||
#define DIO10_PIN PINB4
|
||||
#define DIO10_RPORT PINB
|
||||
#define DIO10_WPORT PORTB
|
||||
#define DIO10_DDR DDRB
|
||||
#define DIO10_PWM OCR2A
|
||||
#define DIO10_PWM &OCR2A
|
||||
|
||||
#define DIO11_PIN PINB5
|
||||
#define DIO11_RPORT PINB
|
||||
|
|
@ -117,7 +117,7 @@ pins
|
|||
#define DIO13_RPORT PINB
|
||||
#define DIO13_WPORT PORTB
|
||||
#define DIO13_DDR DDRB
|
||||
#define DIO13_PWM OCR0A
|
||||
#define DIO13_PWM &OCR0A
|
||||
|
||||
#define DIO14_PIN PINJ1
|
||||
#define DIO14_RPORT PINJ
|
||||
|
|
@ -303,19 +303,19 @@ pins
|
|||
#define DIO44_RPORT PINL
|
||||
#define DIO44_WPORT PORTL
|
||||
#define DIO44_DDR DDRL
|
||||
#define DIO44_PWM OCR5CL
|
||||
#define DIO44_PWM &OCR5CL
|
||||
|
||||
#define DIO45_PIN PINL4
|
||||
#define DIO45_RPORT PINL
|
||||
#define DIO45_WPORT PORTL
|
||||
#define DIO45_DDR DDRL
|
||||
#define DIO45_PWM OCR5BL
|
||||
#define DIO45_PWM &OCR5BL
|
||||
|
||||
#define DIO46_PIN PINL3
|
||||
#define DIO46_RPORT PINL
|
||||
#define DIO46_WPORT PORTL
|
||||
#define DIO46_DDR DDRL
|
||||
#define DIO46_PWM OCR5AL
|
||||
#define DIO46_PWM &OCR5AL
|
||||
|
||||
#define DIO47_PIN PINL2
|
||||
#define DIO47_RPORT PINL
|
||||
|
|
@ -522,7 +522,7 @@ pins
|
|||
#define PB4_RPORT PINB
|
||||
#define PB4_WPORT PORTB
|
||||
#define PB4_DDR DDRB
|
||||
#define PB4_PWM OCR2A
|
||||
#define PB4_PWM &OCR2A
|
||||
#define PB5_PIN PINB5
|
||||
#define PB5_RPORT PINB
|
||||
#define PB5_WPORT PORTB
|
||||
|
|
@ -537,7 +537,7 @@ pins
|
|||
#define PB7_RPORT PINB
|
||||
#define PB7_WPORT PORTB
|
||||
#define PB7_DDR DDRB
|
||||
#define PB7_PWM OCR0A
|
||||
#define PB7_PWM &OCR0A
|
||||
|
||||
#define PC0_PIN PINC0
|
||||
#define PC0_RPORT PINC
|
||||
|
|
@ -640,17 +640,17 @@ pins
|
|||
#define PE3_RPORT PINE
|
||||
#define PE3_WPORT PORTE
|
||||
#define PE3_DDR DDRE
|
||||
#define PE3_PWM OCR3AL
|
||||
#define PE3_PWM &OCR3AL
|
||||
#define PE4_PIN PINE4
|
||||
#define PE4_RPORT PINE
|
||||
#define PE4_WPORT PORTE
|
||||
#define PE4_DDR DDRE
|
||||
#define PE4_PWM OCR3BL
|
||||
#define PE4_PWM &OCR3BL
|
||||
#define PE5_PIN PINE5
|
||||
#define PE5_RPORT PINE
|
||||
#define PE5_WPORT PORTE
|
||||
#define PE5_DDR DDRE
|
||||
#define PE5_PWM OCR3CL
|
||||
#define PE5_PWM &OCR3CL
|
||||
#define PE6_PIN PINE6
|
||||
#define PE6_RPORT PINE
|
||||
#define PE6_WPORT PORTE
|
||||
|
|
@ -732,7 +732,7 @@ pins
|
|||
#define PG5_RPORT PING
|
||||
#define PG5_WPORT PORTG
|
||||
#define PG5_DDR DDRG
|
||||
#define PG5_PWM OCR0B
|
||||
#define PG5_PWM &OCR0B
|
||||
#define PG6_PIN PING6
|
||||
#define PG6_RPORT PING
|
||||
#define PG6_WPORT PORTG
|
||||
|
|
@ -763,22 +763,22 @@ pins
|
|||
#define PH3_RPORT PINH
|
||||
#define PH3_WPORT PORTH
|
||||
#define PH3_DDR DDRH
|
||||
#define PH3_PWM OCR4AL
|
||||
#define PH3_PWM &OCR4AL
|
||||
#define PH4_PIN PINH4
|
||||
#define PH4_RPORT PINH
|
||||
#define PH4_WPORT PORTH
|
||||
#define PH4_DDR DDRH
|
||||
#define PH4_PWM OCR4BL
|
||||
#define PH4_PWM &OCR4BL
|
||||
#define PH5_PIN PINH5
|
||||
#define PH5_RPORT PINH
|
||||
#define PH5_WPORT PORTH
|
||||
#define PH5_DDR DDRH
|
||||
#define PH5_PWM OCR4CL
|
||||
#define PH5_PWM &OCR4CL
|
||||
#define PH6_PIN PINH6
|
||||
#define PH6_RPORT PINH
|
||||
#define PH6_WPORT PORTH
|
||||
#define PH6_DDR DDRH
|
||||
#define PH6_PWM OCR2B
|
||||
#define PH6_PWM &OCR2B
|
||||
#define PH7_PIN PINH7
|
||||
#define PH7_RPORT PINH
|
||||
#define PH7_WPORT PORTH
|
||||
|
|
@ -886,17 +886,17 @@ pins
|
|||
#define PL3_RPORT PINL
|
||||
#define PL3_WPORT PORTL
|
||||
#define PL3_DDR DDRL
|
||||
#define PL3_PWM OCR5AL
|
||||
#define PL3_PWM &OCR5AL
|
||||
#define PL4_PIN PINL4
|
||||
#define PL4_RPORT PINL
|
||||
#define PL4_WPORT PORTL
|
||||
#define PL4_DDR DDRL
|
||||
#define PL4_PWM OCR5BL
|
||||
#define PL4_PWM &OCR5BL
|
||||
#define PL5_PIN PINL5
|
||||
#define PL5_RPORT PINL
|
||||
#define PL5_WPORT PORTL
|
||||
#define PL5_DDR DDRL
|
||||
#define PL5_PWM OCR5CL
|
||||
#define PL5_PWM &OCR5CL
|
||||
#define PL6_PIN PINL6
|
||||
#define PL6_RPORT PINL
|
||||
#define PL6_WPORT PORTL
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ pins
|
|||
#define DIO3_RPORT PIND
|
||||
#define DIO3_WPORT PORTD
|
||||
#define DIO3_DDR DDRD
|
||||
#define DIO3_PWM OCR2B
|
||||
#define DIO3_PWM &OCR2B
|
||||
|
||||
#define DIO4_PIN PIND4
|
||||
#define DIO4_RPORT PIND
|
||||
|
|
@ -60,13 +60,13 @@ pins
|
|||
#define DIO5_RPORT PIND
|
||||
#define DIO5_WPORT PORTD
|
||||
#define DIO5_DDR DDRD
|
||||
#define DIO5_PWM OCR0B
|
||||
#define DIO5_PWM &OCR0B
|
||||
|
||||
#define DIO6_PIN PIND6
|
||||
#define DIO6_RPORT PIND
|
||||
#define DIO6_WPORT PORTD
|
||||
#define DIO6_DDR DDRD
|
||||
#define DIO6_PWM OCR0A
|
||||
#define DIO6_PWM &OCR0A
|
||||
|
||||
#define DIO7_PIN PIND7
|
||||
#define DIO7_RPORT PIND
|
||||
|
|
@ -96,7 +96,7 @@ pins
|
|||
#define DIO11_RPORT PINB
|
||||
#define DIO11_WPORT PORTB
|
||||
#define DIO11_DDR DDRB
|
||||
#define DIO11_PWM OCR2A
|
||||
#define DIO11_PWM &OCR2A
|
||||
|
||||
#define DIO12_PIN PINB4
|
||||
#define DIO12_RPORT PINB
|
||||
|
|
@ -183,7 +183,7 @@ pins
|
|||
#define PB3_RPORT PINB
|
||||
#define PB3_WPORT PORTB
|
||||
#define PB3_DDR DDRB
|
||||
#define PB3_PWM OCR2A
|
||||
#define PB3_PWM &OCR2A
|
||||
|
||||
#define PB4_PIN PINB4
|
||||
#define PB4_RPORT PINB
|
||||
|
|
@ -281,7 +281,7 @@ pins
|
|||
#define PD3_RPORT PIND
|
||||
#define PD3_WPORT PORTD
|
||||
#define PD3_DDR DDRD
|
||||
#define PD3_PWM OCR2B
|
||||
#define PD3_PWM &OCR2B
|
||||
|
||||
#define PD4_PIN PIND4
|
||||
#define PD4_RPORT PIND
|
||||
|
|
@ -293,13 +293,13 @@ pins
|
|||
#define PD5_RPORT PIND
|
||||
#define PD5_WPORT PORTD
|
||||
#define PD5_DDR DDRD
|
||||
#define PD5_PWM OCR0B
|
||||
#define PD5_PWM &OCR0B
|
||||
|
||||
#define PD6_PIN PIND6
|
||||
#define PD6_RPORT PIND
|
||||
#define PD6_WPORT PORTD
|
||||
#define PD6_DDR DDRD
|
||||
#define PD6_PWM OCR0A
|
||||
#define PD6_PWM &OCR0A
|
||||
|
||||
#define PD7_PIN PIND7
|
||||
#define PD7_RPORT PIND
|
||||
|
|
|
|||
|
|
@ -52,13 +52,13 @@ pins
|
|||
#define DIO3_RPORT PINB
|
||||
#define DIO3_WPORT PORTB
|
||||
#define DIO3_DDR DDRB
|
||||
#define DIO3_PWM OCR0A
|
||||
#define DIO3_PWM &OCR0A
|
||||
|
||||
#define DIO4_PIN PINB4
|
||||
#define DIO4_RPORT PINB
|
||||
#define DIO4_WPORT PORTB
|
||||
#define DIO4_DDR DDRB
|
||||
#define DIO4_PWM OCR0B
|
||||
#define DIO4_PWM &OCR0B
|
||||
|
||||
#define DIO5_PIN PINB5
|
||||
#define DIO5_RPORT PINB
|
||||
|
|
@ -118,13 +118,13 @@ pins
|
|||
#define DIO14_RPORT PIND
|
||||
#define DIO14_WPORT PORTD
|
||||
#define DIO14_DDR DDRD
|
||||
#define DIO14_PWM OCR2B
|
||||
#define DIO14_PWM &OCR2B
|
||||
|
||||
#define DIO15_PIN PIND7
|
||||
#define DIO15_RPORT PIND
|
||||
#define DIO15_WPORT PORTD
|
||||
#define DIO15_DDR DDRD
|
||||
#define DIO15_PWM OCR2A
|
||||
#define DIO15_PWM &OCR2A
|
||||
|
||||
#define DIO16_PIN PINC0
|
||||
#define DIO16_RPORT PINC
|
||||
|
|
@ -343,13 +343,13 @@ pins
|
|||
#define PB3_RPORT PINB
|
||||
#define PB3_WPORT PORTB
|
||||
#define PB3_DDR DDRB
|
||||
#define PB3_PWM OCR0A
|
||||
#define PB3_PWM &OCR0A
|
||||
|
||||
#define PB4_PIN PINB4
|
||||
#define PB4_RPORT PINB
|
||||
#define PB4_WPORT PORTB
|
||||
#define PB4_DDR DDRB
|
||||
#define PB4_PWM OCR0B
|
||||
#define PB4_PWM &OCR0B
|
||||
|
||||
#define PB5_PIN PINB5
|
||||
#define PB5_RPORT PINB
|
||||
|
|
@ -459,10 +459,10 @@ pins
|
|||
#define PD6_RPORT PIND
|
||||
#define PD6_WPORT PORTD
|
||||
#define PD6_DDR DDRD
|
||||
#define PD6_PWM OCR2B
|
||||
#define PD6_PWM &OCR2B
|
||||
|
||||
#define PD7_PIN PIND7
|
||||
#define PD7_RPORT PIND
|
||||
#define PD7_WPORT PORTD
|
||||
#define PD7_DDR DDRD
|
||||
#define PD7_PWM OCR2A
|
||||
#define PD7_PWM &OCR2A
|
||||
|
|
|
|||
|
|
@ -1,4 +1,6 @@
|
|||
|
||||
#warning this config doesn't have PWM pins yet!
|
||||
|
||||
// SPI
|
||||
#define SCK DIO9
|
||||
#define MISO DIO11
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ pins
|
|||
#define DIO3_RPORT PIND
|
||||
#define DIO3_WPORT PORTD
|
||||
#define DIO3_DDR DDRD
|
||||
#define DIO3_PWM OCR2B
|
||||
#define DIO3_PWM &OCR2B
|
||||
|
||||
#define DIO4_PIN PIND4
|
||||
#define DIO4_RPORT PIND
|
||||
|
|
@ -60,13 +60,13 @@ pins
|
|||
#define DIO5_RPORT PIND
|
||||
#define DIO5_WPORT PORTD
|
||||
#define DIO5_DDR DDRD
|
||||
#define DIO5_PWM OCR0B
|
||||
#define DIO5_PWM &OCR0B
|
||||
|
||||
#define DIO6_PIN PIND6
|
||||
#define DIO6_RPORT PIND
|
||||
#define DIO6_WPORT PORTD
|
||||
#define DIO6_DDR DDRD
|
||||
#define DIO6_PWM OCR0A
|
||||
#define DIO6_PWM &OCR0A
|
||||
|
||||
#define DIO7_PIN PIND7
|
||||
#define DIO7_RPORT PIND
|
||||
|
|
@ -96,7 +96,7 @@ pins
|
|||
#define DIO11_RPORT PINB
|
||||
#define DIO11_WPORT PORTB
|
||||
#define DIO11_DDR DDRB
|
||||
#define DIO11_PWM OCR2A
|
||||
#define DIO11_PWM &OCR2A
|
||||
|
||||
#define DIO12_PIN PINB4
|
||||
#define DIO12_RPORT PINB
|
||||
|
|
@ -183,7 +183,7 @@ pins
|
|||
#define PB3_RPORT PINB
|
||||
#define PB3_WPORT PORTB
|
||||
#define PB3_DDR DDRB
|
||||
#define PB3_PWM OCR2A
|
||||
#define PB3_PWM &OCR2A
|
||||
|
||||
#define PB4_PIN PINB4
|
||||
#define PB4_RPORT PINB
|
||||
|
|
@ -281,7 +281,7 @@ pins
|
|||
#define PD3_RPORT PIND
|
||||
#define PD3_WPORT PORTD
|
||||
#define PD3_DDR DDRD
|
||||
#define PD3_PWM OCR2B
|
||||
#define PD3_PWM &OCR2B
|
||||
|
||||
#define PD4_PIN PIND4
|
||||
#define PD4_RPORT PIND
|
||||
|
|
@ -293,13 +293,13 @@ pins
|
|||
#define PD5_RPORT PIND
|
||||
#define PD5_WPORT PORTD
|
||||
#define PD5_DDR DDRD
|
||||
#define PD5_PWM OCR0B
|
||||
#define PD5_PWM &OCR0B
|
||||
|
||||
#define PD6_PIN PIND6
|
||||
#define PD6_RPORT PIND
|
||||
#define PD6_WPORT PORTD
|
||||
#define PD6_DDR DDRD
|
||||
#define PD6_PWM OCR0A
|
||||
#define PD6_PWM &OCR0A
|
||||
|
||||
#define PD7_PIN PIND7
|
||||
#define PD7_RPORT PIND
|
||||
|
|
|
|||
2
heater.c
2
heater.c
|
|
@ -28,7 +28,7 @@ typedef struct {
|
|||
#undef DEFINE_HEATER
|
||||
/// \brief helper macro to fill heater definition struct from config.h
|
||||
// #define DEFINE_HEATER(name, port, pin, pwm) { &(port), (pin), &(pwm) },
|
||||
#define DEFINE_HEATER(name, pin) { &(pin ## _WPORT), pin ## _PIN, &(pin ## _PWM) },
|
||||
#define DEFINE_HEATER(name, pin) { &(pin ## _WPORT), pin ## _PIN, (pin ## _PWM) },
|
||||
static const heater_definition_t heaters[NUM_HEATERS] =
|
||||
{
|
||||
#include "config.h"
|
||||
|
|
|
|||
Loading…
Reference in New Issue