PowerPort configuration for different charger types improved
- Solar and battery ports now defined as references to actual hardware ports at very beginning of main.cpp, allowing to use the references also in data_objects.cpp - Different charger types (PWM / MPPT) are configured more clearly by switching on/off features (DC/DC, PWM switch and load) in PCB configuration
This commit is contained in:
+2
-3
@@ -22,8 +22,7 @@
|
||||
|
||||
#include <time.h> // for time(NULL) function
|
||||
|
||||
// timer used for PWM generation has to be globally selected for the used PCB
|
||||
#if (PWM_TIM == 3) && defined(CHARGER_TYPE_PWM)
|
||||
#if FEATURE_PWM_SWITCH
|
||||
|
||||
static int _pwm_resolution;
|
||||
|
||||
@@ -183,6 +182,6 @@ void pwm_switch_control(PwmSwitch *pwm_switch, PowerPort *solar, PowerPort *bat)
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* CHARGER_TYPE_PWM */
|
||||
#endif /* FEATURE_PWM_SWITCH */
|
||||
|
||||
#endif /* UNIT_TEST */
|
||||
|
||||
Reference in New Issue
Block a user