File tree 2 files changed +16
-1
lines changed
vehicle/OVMS.V3/components/vehicle_vweup/src
2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 29
29
#include < string>
30
30
static const char *TAG = " v-vweup" ;
31
31
32
- #define VERSION " 0.22.1 "
32
+ #define VERSION " 0.22.2 "
33
33
34
34
#include < stdio.h>
35
35
#include < string>
@@ -97,6 +97,18 @@ OvmsVehicleVWeUp::OvmsVehicleVWeUp()
97
97
98
98
m_use_phase = UP_None;
99
99
m_obd_state = OBDS_Init;
100
+
101
+ m_soc_norm_start = 0 ;
102
+ m_soc_abs_start = 0 ;
103
+ m_energy_recd_start = 0 ;
104
+ m_energy_used_start = 0 ;
105
+ m_energy_charged_start = 0 ;
106
+ m_coulomb_recd_start = 0 ;
107
+ m_coulomb_used_start = 0 ;
108
+ m_coulomb_charged_start = 0 ;
109
+ m_charge_kwh_grid_start = 0 ;
110
+ m_charge_kwh_grid = 0 ;
111
+
100
112
m_chargestart_ticker = 0 ;
101
113
m_chargestop_ticker = 0 ;
102
114
m_chargestate_lastsoc = 100 ;
Original file line number Diff line number Diff line change @@ -1384,6 +1384,9 @@ void OvmsVehicleVWeUp::UpdateChargeCap(bool charging)
1384
1384
static int checkpoint = 9999 ;
1385
1385
bool log_data = false , update_caps = false , update_soh = false ;
1386
1386
1387
+ if (m_soc_abs_start == 0 || m_coulomb_charged_start == 0 )
1388
+ return ;
1389
+
1387
1390
int charge_time = StdMetrics.ms_v_charge_time ->AsInt ();
1388
1391
float soc_abs_diff = BatMgmtSoCAbs->AsFloat () - m_soc_abs_start;
1389
1392
float soc_norm_diff = StdMetrics.ms_v_bat_soc ->AsFloat () - m_soc_norm_start;
You can’t perform that action at this time.
0 commit comments