OpenDTU-old/include
ranma 191cc8007d
Feature: parse additional Pylontech CAN protocol fields (#1213)
I noticed that these are missing while looking at dissassembly of the
Pytes implementation of the protocol. I also found Pylontech sample
CAN messages] which match the Pytes implementation [1]:

```
CAN ID – followed by 2 to 8 bytes of data:
0x351 – 14 02 74 0E 74 0E CC 01 – Battery voltage + current limits
                          ^^^^^ discharge cutoff voltage 46.0V
0x355 – 1A 00 64 00 – State of Health (SOH) / State of Charge (SOC)
0x356 – 4e 13 02 03 04 05 – Voltage / Current / Temp
0x359 – 00 00 00 00 0A 50 4E – Protection & Alarm flags
                       ^^^^^ always 0x50 0x59 in Pytes implementation
                    ^^ module count (matches the blog article image)
0x35C – C0 00 – Battery charge request flags
        ^^ two possible additional flags (bit 3 and bit 4)
0x35E – 50 59 4C 4F 4E 20 20 20 – Manufacturer name (“PYLON “)
        ^^^^^^^^^^^^^^ Note: Pytes sends a 5-byte message "PYTES" instead
                       padding with spaces
```

The extra charge request flag is "bit4: SOC low" (Seems to be SoC < 10%
threshold for Pytes), I haven't bothered adding that as it provides
little value.

[1] https://www.setfirelabs.com/green-energy/pylontech-can-reading-can-replication
2024-09-25 14:45:52 +02:00
..
__compiled_constants.h embrace upstream __compiled_constants.h approach 2024-05-07 22:04:36 +02:00
Battery.h Feature: extend battery discharge limit support (#1245) 2024-09-13 20:52:23 +02:00
BatteryCanReceiver.h Feature: Support for SBS Unipower batteries (#1199) 2024-09-16 15:22:15 +02:00
BatteryStats.h Feature: parse additional Pylontech CAN protocol fields (#1213) 2024-09-25 14:45:52 +02:00
Configuration.h Feature: extend battery discharge limit support (#1245) 2024-09-13 20:52:23 +02:00
Datastore.h Move task initialization from init method to constructor 2024-01-20 11:24:57 +01:00
defaults.h Feature: extend battery discharge limit support (#1245) 2024-09-13 20:52:23 +02:00
Display_Graphic_Diagram.h Feature: Added fullscreen diagram to display 2024-01-13 11:31:12 +01:00
Display_Graphic.h Feature: Add support for ST7567 GM12864I-59N Display 2024-01-26 16:05:56 +01:00
helper.h Change License to GPLv2 as the RF24 lib uses GPL-2.0-only 2022-07-15 18:05:58 +02:00
HttpGetter.h Feature: HttpGetter: cache digest challenge 2024-08-28 13:32:47 +02:00
Huawei_can.h convert files with CRLF endings to LF endings 2024-06-24 21:57:12 +02:00
InverterSettings.h Move task initialization from init method to constructor 2024-01-20 11:24:57 +01:00
JkBmsController.h restore JK BMS dummy implementation 2024-06-21 16:57:11 +02:00
JkBmsDataPoints.h use frozen::string and frozen::map where reasonable (#593) 2024-01-04 23:28:34 +01:00
JkBmsDummy.h restore JK BMS dummy implementation 2024-06-21 16:57:11 +02:00
JkBmsSerialMessage.h Support for Jikong JK BMS using serial connection (#319) 2023-08-31 16:21:32 +02:00
Led_Single.h merge V23.12.16 (#556) 2023-12-27 11:49:57 +01:00
MessageOutput.h convert files with CRLF endings to LF endings 2024-06-24 21:57:12 +02:00
MqttBattery.h Feature: extend battery discharge limit support (#1245) 2024-09-13 20:52:23 +02:00
MqttHandleBatteryHass.h Feature: JK BMS Home Assistent integration 2024-02-05 21:22:07 +01:00
MqttHandleDtu.h Move task initialization from init method to constructor 2024-01-20 11:24:57 +01:00
MqttHandleHass.h Merge branch 'pr2168' into dev 2024-08-01 17:53:53 +02:00
MqttHandleHuawei.h fix: update mqtt subscriptions when topic changed (#1156) 2024-08-20 23:44:27 +02:00
MqttHandleInverter.h Fix #2000: MQTT subscriptions where not updated if MQTT base was changed 2024-05-20 17:56:59 +02:00
MqttHandleInverterTotal.h Move task initialization from init method to constructor 2024-01-20 11:24:57 +01:00
MqttHandlePowerLimiter.h fix: update mqtt subscriptions when topic changed (#1156) 2024-08-20 23:44:27 +02:00
MqttHandlePowerLimiterHass.h Feature: expose 'full solar passsthrough active' via MQTT (#1136) 2024-07-26 20:37:40 +02:00
MqttHandleVedirect.h VE.Direct: simplify access to data 2024-04-02 21:05:59 +02:00
MqttHandleVedirectHass.h VE.Direct: simplify access to data 2024-04-02 21:05:59 +02:00
MqttSettings.h Merge upstream tag 'v24.6.29' into development 2024-07-10 21:45:43 +02:00
NetworkSettings.h Merge remote-tracking branch 'tbnobody/master' into development 2024-09-21 22:00:49 +02:00
NtpSettings.h Cleanup includes 2022-12-14 22:13:03 +01:00
PinMapping.h Feature: rxen/txen support for RS485 transceiver for SDM power meter (#1269) 2024-09-23 21:20:03 +02:00
PowerLimiter.h Feature: DPL: Honor battery-provided discharge power limit (#1198) 2024-09-13 20:36:16 +02:00
PowerMeter.h powermeter refactor: split providers into their own classes 2024-06-26 20:51:54 +02:00
PowerMeterHttpJson.h Fix: initialize HTTP(S)+JSON power meter values 2024-08-28 13:32:47 +02:00
PowerMeterHttpSml.h power meter refactoring: split loop task init from init() 2024-06-27 22:18:41 +02:00
PowerMeterMqtt.h Fix: don't republish MQTT powermeter data to MQTT (#1250) 2024-09-13 17:26:30 +02:00
PowerMeterProvider.h Feature: make power meter polling intervals configurable 2024-06-27 22:18:41 +02:00
PowerMeterSerialSdm.h power meter refactoring: split loop task init from init() 2024-06-27 22:18:41 +02:00
PowerMeterSerialSml.h power meter refactoring: split loop task init from init() 2024-06-27 22:18:41 +02:00
PowerMeterSml.h Feature: SML power meters: reset SML decoder 2024-06-27 22:18:41 +02:00
PowerMeterUdpSmaHomeManager.h powermeter refactor: use destructors to de-initialize 2024-06-26 20:51:56 +02:00
PylontechCanReceiver.h refactor PylontechCanBattery to be more generic (#1064) 2024-06-23 19:42:04 +02:00
PytesCanReceiver.h Feature: add support for Pytes batteries using CAN (#1088) 2024-07-10 21:01:49 +02:00
README Initial commit 2022-04-09 11:05:14 +02:00
RestartHelper.h Fix: Restart was triggered before all website data was sent 2024-09-23 18:11:52 +02:00
SBSCanReceiver.h Feature: Support for SBS Unipower batteries (#1199) 2024-09-16 15:22:15 +02:00
Scheduler.h merge V23.12.16 (#556) 2023-12-27 11:49:57 +01:00
SerialPortManager.h refactor serial port manager: hand out UARTs FCFS 2024-06-02 22:41:07 +02:00
SPIPortManager.h Feature: SPIPortManager allows simultaneous use of CMT2300 and Huawei charger 2024-08-19 20:44:59 +02:00
SunPosition.h merge V23.12.16 (#556) 2023-12-27 11:49:57 +01:00
Utils.h Merge remote-tracking branch 'tbnobody/master' into development 2024-09-23 21:38:50 +02:00
VictronMppt.h refactor serial port manager: hand out UARTs FCFS 2024-06-02 22:41:07 +02:00
VictronSmartShunt.h refactor serial port manager: hand out UARTs FCFS 2024-06-02 22:41:07 +02:00
WebApi_battery.h Merge remote-tracking branch 'tbnobody/OpenDTU/master' into development 2024-01-25 23:36:32 +01:00
WebApi_config.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_device.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_devinfo.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_dtu.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_errors.h Feature: Allow custom MQTT Client ID 2024-06-29 00:28:21 +02:00
WebApi_eventlog.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_firmware.h Merge remote-tracking branch 'tbnobody/master' into development 2024-09-23 21:38:50 +02:00
WebApi_gridprofile.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_Huawei.h convert files with CRLF endings to LF endings 2024-06-24 21:57:12 +02:00
WebApi_inverter.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_limit.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_maintenance.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_mqtt.h Feature: Migrated ArduinoJson 6 to 7 2024-04-05 19:14:56 +02:00
WebApi_network.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_ntp.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_power.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_powerlimiter.h DPL settings in web app: split metadata from config 2024-03-23 22:13:50 +01:00
WebApi_powermeter.h powermeter refactor: generalize HTTP request config 2024-06-26 21:25:08 +02:00
WebApi_prometheus.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_security.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_sysstatus.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_vedirect.h Merge remote-tracking branch 'tbnobody/OpenDTU/master' into development 2024-01-25 23:36:32 +01:00
WebApi_webapp.h Merge branch 'pr1642' into dev 2024-01-30 20:47:45 +01:00
WebApi_ws_battery.h convert files with CRLF endings to LF endings 2024-06-24 21:57:12 +02:00
WebApi_ws_console.h Removed not required pointer to AsyncServer instance 2024-01-27 01:09:55 +01:00
WebApi_ws_Huawei.h convert files with CRLF endings to LF endings 2024-06-24 21:57:12 +02:00
WebApi_ws_live.h Feature: live view: update with respective frequency 2024-03-05 11:31:44 +01:00
WebApi_ws_vedirect_live.h Merge remote-tracking branch 'tbnobody/OpenDTU/master' into merge-v24.4.12 2024-04-25 20:59:19 +02:00
WebApi.h Merge remote-tracking branch 'tbnobody/OpenDTU/master' into merge-v24.4.12 2024-04-25 20:59:19 +02:00

This directory is intended for project header files.

A header file is a file containing C declarations and macro definitions
to be shared between several project source files. You request the use of a
header file in your project source file (C, C++, etc) located in `src` folder
by including it, with the C preprocessing directive `#include'.

```src/main.c

#include "header.h"

int main (void)
{
 ...
}
```

Including a header file produces the same results as copying the header file
into each source file that needs it. Such copying would be time-consuming
and error-prone. With a header file, the related declarations appear
in only one place. If they need to be changed, they can be changed in one
place, and programs that include the header file will automatically use the
new version when next recompiled. The header file eliminates the labor of
finding and changing all the copies as well as the risk that a failure to
find one copy will result in inconsistencies within a program.

In C, the usual convention is to give header files names that end with `.h'.
It is most portable to use only letters, digits, dashes, and underscores in
header file names, and at most one dot.

Read more about using header files in official GCC documentation:

* Include Syntax
* Include Operation
* Once-Only Headers
* Computed Includes

https://gcc.gnu.org/onlinedocs/cpp/Header-Files.html