uc: include METERCONST and MUXN as config options in Makefile
This commit is contained in:
parent
2b769d5556
commit
b6e98cd734
|
@ -86,13 +86,15 @@ F_CPU = 1000000
|
||||||
# make TYPE= xxxx SENSOR0=yyyy ...
|
# make TYPE= xxxx SENSOR0=yyyy ...
|
||||||
#
|
#
|
||||||
TYPE = 2301
|
TYPE = 2301
|
||||||
|
METERCONST = 7091
|
||||||
|
MUXN = 0
|
||||||
#
|
#
|
||||||
SENSOR0 = 0123456789abcdef0123456789abcde0
|
SENSOR0 = 0123456789abcdef0123456789abcde0
|
||||||
SENSOR1 = 0123456789abcdef0123456789abcde1
|
SENSOR1 = 0123456789abcdef0123456789abcde1
|
||||||
SENSOR2 = 0123456789abcdef0123456789abcde2
|
SENSOR2 = 0123456789abcdef0123456789abcde2
|
||||||
SENSOR3 = 0123456789abcdef0123456789abcde3
|
SENSOR3 = 0123456789abcdef0123456789abcde3
|
||||||
#
|
#
|
||||||
CEXTRA = -D TYPE=$(TYPE) -D 'SENSOR0="$(SENSOR0)"' -D 'SENSOR1="$(SENSOR1)"' -D 'SENSOR2="$(SENSOR2)"' -D 'SENSOR3="$(SENSOR3)"'
|
CEXTRA = -D TYPE=$(TYPE) -D METERCONST=$(METERCONST) -D MUXN=$(MUXN) -D 'SENSOR0="$(SENSOR0)"' -D 'SENSOR1="$(SENSOR1)"' -D 'SENSOR2="$(SENSOR2)"' -D 'SENSOR3="$(SENSOR3)"'
|
||||||
#####################################################################################
|
#####################################################################################
|
||||||
|
|
||||||
#####################################################################################
|
#####################################################################################
|
||||||
|
|
|
@ -40,7 +40,7 @@
|
||||||
#define TYPE 2301
|
#define TYPE 2301
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifndef METERCONST
|
||||||
#if TYPE == 2201 // 220V - 1-phase @ 488.28Hz sampling rate
|
#if TYPE == 2201 // 220V - 1-phase @ 488.28Hz sampling rate
|
||||||
#define METERCONST 6783
|
#define METERCONST 6783
|
||||||
#define MUXN 0
|
#define MUXN 0
|
||||||
|
@ -71,6 +71,7 @@
|
||||||
#define MUXN 1
|
#define MUXN 1
|
||||||
#warning "240V - 3-phase selected. METERCONST set to 7331"
|
#warning "240V - 3-phase selected. METERCONST set to 7331"
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#define START 0
|
#define START 0
|
||||||
#define END3 0xffffffff
|
#define END3 0xffffffff
|
||||||
|
|
Loading…
Reference in New Issue