mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-07 16:29:51 +03:00
auto formatting
This commit is contained in:
14
src/ems.cpp
14
src/ems.cpp
@@ -1473,7 +1473,6 @@ void _process_HPMonitor2(_EMS_RxTelegram * EMS_RxTelegram) {
|
||||
* Junkers ISM1 Solar Module - type 0x0003 EMS+ for energy readings
|
||||
*/
|
||||
void _process_ISM1StatusMessage(_EMS_RxTelegram * EMS_RxTelegram) {
|
||||
|
||||
if (EMS_RxTelegram->offset == 0) {
|
||||
// e.g. B0 00 FF 00 00 03 32 00 00 00 00 13 00 D6 00 00 00 FB D0 F0
|
||||
EMS_SolarModule.collectorTemp = _toShort(4); // Collector Temperature
|
||||
@@ -1675,7 +1674,11 @@ void _process_Version(_EMS_RxTelegram * EMS_RxTelegram) {
|
||||
}
|
||||
|
||||
if (typeFound) {
|
||||
myDebug_P(PSTR("Solar Module found: %s (DeviceID:0x%02X ProductID:%d Version:%s)"), SolarModule_Types[i].model_string, SolarModule_Types[i].device_id, product_id, version);
|
||||
myDebug_P(PSTR("Solar Module found: %s (DeviceID:0x%02X ProductID:%d Version:%s)"),
|
||||
SolarModule_Types[i].model_string,
|
||||
SolarModule_Types[i].device_id,
|
||||
product_id,
|
||||
version);
|
||||
|
||||
// add to list
|
||||
_addDevice(product_id, SolarModule_Types[i].device_id, version, SolarModule_Types[i].model_string);
|
||||
@@ -1690,7 +1693,6 @@ void _process_Version(_EMS_RxTelegram * EMS_RxTelegram) {
|
||||
// fetch Solar Module values
|
||||
ems_getSolarModuleValues();
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1719,7 +1721,6 @@ void _process_Version(_EMS_RxTelegram * EMS_RxTelegram) {
|
||||
EMS_Other.product_id = product_id;
|
||||
strlcpy(EMS_Other.version, version, sizeof(EMS_Other.version));
|
||||
// fetch Solar Module values > not yet implemented
|
||||
|
||||
}
|
||||
|
||||
return;
|
||||
@@ -1871,17 +1872,14 @@ void ems_getBoilerValues() {
|
||||
* Get other values from EMS devices
|
||||
*/
|
||||
void ems_getSolarModuleValues() {
|
||||
|
||||
uint8_t product_id = EMS_SolarModule.product_id;
|
||||
|
||||
if (ems_getSolarModuleEnabled()) {
|
||||
if (product_id == EMS_PRODUCTID_SM10) {
|
||||
ems_doReadCommand(EMS_TYPE_SM10Monitor, EMS_ID_SM); // fetch all from SM10Monitor
|
||||
}
|
||||
else if (product_id == EMS_PRODUCTID_SM100) {
|
||||
} else if (product_id == EMS_PRODUCTID_SM100) {
|
||||
ems_doReadCommand(EMS_TYPE_SM100Monitor, EMS_ID_SM); // fetch all from SM100Monitor
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user