Commit Graph

2212 Commits

Author SHA1 Message Date
Bernhard Kirchen
7c069b1cc4 replace BatteryStats::isValid() method
in the respective context, the DPL only needs to be sure that the SoC
value is not outdated. it should not even care about other values
reported by the battery interface. hence, the isValid() method shall be
concerned with the SoC value timestamp only. the method is renamed for
clarity.
2024-02-18 22:17:15 +01:00
Bernhard Kirchen
3595725f8a Feature: implement subscription to battery voltage MQTT topic
this extends the MqttBattery implementation by an additional topic which
allows to subscribe to receive battery voltage readings through the MQTT
broker. similar to the battery SoC topic, this allows to import a
critical battery data point for the DPL, in case the user chooses to use
voltage thresholds rather than SoC thresholds to control the DPL. if an
otherwise incompatible BMS is available which publishes the battery pack
voltage through MQTT, this can now be used to feed accurate voltage
readings to the DPL.
2024-02-18 22:17:15 +01:00
Bernhard Kirchen
30bfffb848 BatteryStats: manage battery pack voltage in base class
the BatteryStats base class shall be able to tell the total battery pack
voltage. for that reason, and to avoid code duplication, the voltage is
now handled in the base class and treated as a datum that is common to
all battery providers.
2024-02-18 21:49:12 +01:00
Bernhard Kirchen
921302bf73 Feature: DPL: add switch allowing to ignore SoC
unfortunately, the battery SoC values reported by battery BMSs are
unreliable, at least for some users, or at least without regular
(manual) full charge cycles to calibrate the BMS. it offers great
advantages to connect OpenDTU-OnBattery to a BMS (MQTT publishing of
values, Home Assistent integration, etc.), but previously the users
were then forced to configure the DPL by SoC values.

this change allows to configure the DPL such that SoC values are
ignored. instead, the voltage limits are used to make DPL decisions, as
if no SoC was available in the first place.

the SoC related setting are hidden from the DPL settings view if SoC
values are configured to be ignored.

closes #654.
2024-02-18 21:46:42 +01:00
helgeerbe
b794f46ef0 Merge remote-tracking branch 'tbnobody/OpenDTU/master' into development 2024-02-09 20:14:58 +01:00
Bernhard Kirchen
7c84621ea9
update VE.Direct product IDsfixes typos and errors, and adds previously unknown PIDs.closes #641.
* update VE.Direct product IDs

fixes typos and errors, and adds previously unknown PIDs.

closes #641.
2024-02-09 19:50:36 +01:00
helgeerbe
df5b416b3f
Merge pull request #640 from schlimmchen:jkbms-home-assistent-pr
JK BMS Home Assistent Integration
2024-02-09 19:46:59 +01:00
Bernhard Kirchen
1865113842 Feature: JK BMS Home Assistent integration
* pylontech HA integration: remove unused method/variable

* make MqttHandlePylontechHassClass::publishConfig() private.
  there are no outside users of that method.

* rename to MqttHandleBatteryHass

* battery HA integration: merge methods and bring back forceUpdate().
  even though the forceUpdate() method was not in use before, it makes
  sense to implement it and use it when the battery config changes.
  rather than controlling a separate flag, it now changes the _doPublish
  flag of the class, which also triggers publishing the device config to
  Home Assistant when an MQTT connection problem was detected. since
  both situations are now handled similarly, we can merge the loop() and
  publishConfig() methods.

* battery: provider specific sensors for HA

* move Battery MQTT loop to BatteryStats
  the BatteryStats class should handle the MQTT publishing, including the
  interval. for the calculation of a reasonable Home Assistent expiration
  value this class now also knows the maximum publish interval.

* JK BMS: fix publishing values for Home Assistent
  Home Assistent values expire, because we set them to expire after three
  MQTT publish durations. for that reason, we need to re-publish all
  values after our self-inflicted full publish interval.

* define JK BMS sensors for Home Assistent

closes #482.
2024-02-05 21:22:07 +01:00
Bernhard Kirchen
c2b49931be Fix: must call Pylontech Home Assistent init() method
previously, the Pytlontech Home Assistent class implementation had an
init() method, that was never called, as it did nothing. the class
relied on its loop() method being called from the main loop(). after
switching to the TaskScheduler approach, the Pylontech Home Assistent
class init() method was adjusted to register a task that calls the
loop() method periodically. however, the init() method was still not
called.
2024-02-05 20:54:34 +01:00
Thomas Basler
21ec72f4c0 webapp: add app.js.gz 2024-01-26 21:42:55 +01:00
Thomas Basler
59022347eb Doc: Remove deprecated documentation 2024-01-26 21:40:57 +01:00
Thomas Basler
2c4952b196 Doc: Migrated needed hardware info to official documentation 2024-01-26 21:30:58 +01:00
Thomas Basler
ac2e963799 Doc: Move display documentation to official documentation 2024-01-26 17:12:55 +01:00
Thomas Basler
c04407f740 Doc: Move partition migration to official documentation 2024-01-26 17:02:55 +01:00
Thomas Basler
fe9ac6a2fd webapp: update dependencies 2024-01-26 16:56:49 +01:00
Thomas Basler
f0061b976d Merge branch 'pr1676' into dev 2024-01-26 16:48:15 +01:00
Thomas Basler
4e669d8932 Feature: Add support for ST7567 GM12864I-59N Display 2024-01-26 16:05:56 +01:00
helgeerbe
1916d6d6a8 check twice a second for new vedirect data on live viw 2024-01-26 14:32:44 +01:00
helgeerbe
7094bca7db fix: Inverter Labels in InverterTotalInfo 2024-01-26 13:34:03 +01:00
helgeerbe
ebacc2f25f Merge remote-tracking branch 'tbnobody/OpenDTU/master' into development 2024-01-25 23:36:32 +01:00
Stefan Oberhumer
7aece2e143 Call SunPosition.isDayPeriod() once 2024-01-23 09:42:13 +01:00
Thomas Basler
a5cc0a424f webapp: add app.js.gz 2024-01-21 16:49:41 +01:00
Thomas Basler
d99de94c00 webapp: Fix lint errors 2024-01-21 16:48:47 +01:00
Thomas Basler
3f135e8349 webapp: update dependencies 2024-01-21 16:39:22 +01:00
Thomas Basler
178525a49b Feature: Added device profile for Olimex ESP32 Gateway
Thanks to @fdcg in #1672
2024-01-21 11:32:18 +01:00
Thomas Basler
4cfb1b1c26 Fix: PullToRefresh does not work anymore
It was using the wrong mainElement
2024-01-21 00:55:05 +01:00
Thomas Basler
4f2fbaaf2a Remove unused function parameter 2024-01-20 23:12:59 +01:00
Thomas Basler
8a80289474 Feature: Implement firmware update check is a opt-in to protect your privacy 2024-01-20 22:43:40 +01:00
Thomas Basler
16fbad92ac simplify calculations in WebApi_ws_Live 2024-01-20 11:38:52 +01:00
Thomas Basler
7bc1a17fac Move task initialization from init method to constructor
This saves flash
2024-01-20 11:24:57 +01:00
Thomas Basler
251d197fb6 Migrate WebApi loop() methods to scheduler tasks 2024-01-20 02:00:22 +01:00
Thomas Basler
e66060e769 Move the conversation from time_t to String into DevInfoParser 2024-01-20 01:09:42 +01:00
Thomas Basler
dcc157261e Don't perform redundant conversions 2024-01-20 00:32:13 +01:00
Thomas Basler
9428eecce4 webapp: Use CardElement in InverterTotalInfo 2024-01-19 22:03:26 +01:00
Thomas Basler
a06d21024c webapp: Move interfaces to seperate file 2024-01-19 21:48:39 +01:00
Thomas Basler
6b31a4d470 webapp: Introduce Modal component
Less duplicated code
2024-01-19 21:36:18 +01:00
Thomas Basler
5d63f64411 webapp: Fix typo 2024-01-19 20:02:03 +01:00
Thomas Basler
0584eadcf2 Feature: Automatic page reload after firmware upgrade
This will work after the current upgrade if this code was loaded.
2024-01-19 19:10:49 +01:00
Thomas Basler
f7119bc3c7 webapp: Fix font-feature class 2024-01-19 17:20:57 +01:00
Thomas Basler
bdfdc3913b webapp: add app.js.gz 2024-01-18 21:23:28 +01:00
Thomas Basler
149444decb Fix: Gridprofile dump contained the whole buffer instead of the actual length
As a result, a lot of zeros where placed at the end of the dump
2024-01-18 21:21:40 +01:00
Thomas Basler
ce978cb0f5 webapp: update dependencies 2024-01-18 20:39:44 +01:00
Nikolaj Kappler
199351c703 webapp: Correctly center header text 2024-01-18 20:39:43 +01:00
Nikolaj Kappler
a7479d33e3 webapp: Reduce wasted horizontal space for better mobile UX 2024-01-18 20:39:43 +01:00
Nikolaj Kappler
41f3955429 webapp: Vertically center Header/Logo Text 2024-01-18 20:39:43 +01:00
Nikolaj Kappler
bfeb852e23 webapp: Remove redundant main container 2024-01-18 20:39:43 +01:00
Thomas Basler
72a2c58f1e Update bblanchon/ArduinoJson from 6.21.4 to 6.21.5 2024-01-18 20:39:43 +01:00
Nikolaj Kappler
caaa7b6347 fix count being a string 2024-01-18 20:39:43 +01:00
Nikolaj Kappler
f26e824247 fix #1649
one of the goals of my pull request, besides simplifying the code was to have localization.

It's nice that the browser can handle this, but for consistency, we'll go with vue-i18n since it is already available
2024-01-18 20:39:42 +01:00
Thomas Basler
6233ad12ae webapp: Prefix Country with CMT2300A 2024-01-18 20:39:28 +01:00