Pre-commit fix

This commit is contained in:
Daniel Öster 2024-09-08 22:12:57 +03:00
parent fca78bef78
commit 373d7a4f0f
3 changed files with 18 additions and 16 deletions

View file

@ -62,7 +62,8 @@
#include "SANTA-FE-PHEV-BATTERY.h"
#endif
#if defined(TESLA_MODEL_S_BATTERY) || defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_X_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
#if defined(TESLA_MODEL_S_BATTERY) || defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_X_BATTERY) || \
defined(TESLA_MODEL_Y_BATTERY)
#include "TESLA-BATTERY.h"
#endif

View file

@ -327,14 +327,14 @@ void update_values_battery() { //This function maps all the values fetched via
battery_cell_deviation_mV = (battery_cell_max_v - battery_cell_min_v);
#if defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
#if defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
// Autodetect algoritm for chemistry on 3/Y packs.
// NCM/A batteries have 96s, LFP has 102-106s
// Drawback with this check is that it takes 3-5minutes before all cells have been counted!
if (datalayer.battery.info.number_of_cells > 101) {
datalayer.battery.info.chemistry = battery_chemistry_enum::LFP;
}
#endif // TESLA_MODEL_3_BATTERY || TESLA_MODEL_Y_BATTERY
#endif // TESLA_MODEL_3_BATTERY || TESLA_MODEL_Y_BATTERY
//Once cell chemistry is determined, set maximum and minimum total pack voltage safety limits
if (datalayer.battery.info.chemistry == battery_chemistry_enum::LFP) {
@ -909,14 +909,14 @@ void update_values_battery2() { //This function maps all the values fetched via
battery2_cell_deviation_mV = (battery2_cell_max_v - battery2_cell_min_v);
#if defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
#if defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
// Autodetect algoritm for chemistry on 3/Y packs.
// NCM/A batteries have 96s, LFP has 102-106s
// Drawback with this check is that it takes 3-5minutes before all cells have been counted!
if (datalayer.battery2.info.number_of_cells > 101) {
datalayer.battery2.info.chemistry = battery_chemistry_enum::LFP;
}
#endif // TESLA_MODEL_3_BATTERY || TESLA_MODEL_Y_BATTERY
#endif // TESLA_MODEL_3_BATTERY || TESLA_MODEL_Y_BATTERY
//Once cell chemistry is determined, set maximum and minimum total pack voltage safety limits
if (datalayer.battery2.info.chemistry == battery_chemistry_enum::LFP) {

View file

@ -526,7 +526,8 @@ String processor(const String& var) {
#ifdef SERIAL_LINK_RECEIVER
content += "Serial link to another LilyGo board";
#endif // SERIAL_LINK_RECEIVER
#if defined(TESLA_MODEL_S_BATTERY) || defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_X_BATTERY) || defined(TESLA_MODEL_Y_BATTERY)
#if defined(TESLA_MODEL_S_BATTERY) || defined(TESLA_MODEL_3_BATTERY) || defined(TESLA_MODEL_X_BATTERY) || \
defined(TESLA_MODEL_Y_BATTERY)
content += "Tesla Model S/3/X/Y";
#endif // TESLA_MODEL_#_BATTERY
#ifdef VOLVO_SPA_BATTERY