kopia lustrzana https://github.com/weetmuts/wmbusmeters
rodzic
0a3a54b006
commit
2f2f4a1e58
5
CHANGES
5
CHANGES
|
|
@ -1,3 +1,8 @@
|
|||
Version 0.9.26: 2020-02-07
|
||||
|
||||
Cinemarene added support for the Techem
|
||||
FHKV Data III heat cost allocator. Thanks cinemarene!
|
||||
|
||||
Version 0.9.25: 2020-02-07
|
||||
|
||||
Fix bug i esyswm and ebzwmbe that printed zero values
|
||||
|
|
|
|||
|
|
@ -68,6 +68,11 @@ telegram=|374468506549235827C3A2|129F25383300A8622600008200800A2AF86211517555287
|
|||
{"media":"heat","meter":"vario451","name":"HeatMeter","id":"58234965","total_kwh":6371.666667,"current_kwh":2729.444444,"previous_kwh":3642.222222,"timestamp":"1111-11-11T11:11:11Z"}
|
||||
|HeatMeter;58234965;6371.666667;2729.444444;3642.222222;1111-11-11 11:11.11
|
||||
|
||||
# Test FHKV data II/III
|
||||
telegram=|31446850226677116980A0119F27020480048300C408F709143C003D341A2B0B2A0707000000000000062D114457563D71A1850000|
|
||||
{"media":"Unknown","meter":"fhkvdataiii","name":"Room","id":"11776622","current_hca":11034,"current_date":"2020-10-03T02:00:00Z","previous_hca":60,"previous_date":"2010-00-09T02:00:00Z","temp_room_c":107.63,"temp_radiator_c":17.99,"timestamp":"1111-11-11T11:11:11Z"}
|
||||
|Room;11776622;11034.000000;2020-10-03T02:00:00Z;60.000000;2010-00-09T02:00:00Z;107.630000;17.990000;1111-11-11 11:11.11
|
||||
|
||||
# Test EurisII T1 telegrams
|
||||
|
||||
telegram=|7644C52501880188550872|01880188C5255508010000002F2F0B6E332211426E110182016E1102C2016E110382026E1104C2026E110582036E1106C2036E110782046E1108C2046E110982056E1110C2056E111182066E1112C2066E111382076E1114C2076E111582086E1116C2086E111702FD172100|
|
||||
|
|
@ -115,8 +120,8 @@ telegram=|2E4409077272727210077AD7102005CC2FF08D057E306D8C3078AE44AD6E3D37F8515B
|
|||
|
||||
# Test electricity meter with eBZ wMB E01.
|
||||
telegram=|5B445A149922992202378C20F6900F002C25BC9E0000BF48954821BC508D72992299225A140102F6003007102F2F040330F92A0004A9FF01FF24000004A9FF026A29000004A9FF03460600000DFD11063132333435362F2F2F2F2F2F|
|
||||
{"media":"radio converter (meter side)","meter":"ebzwmbe","name":"Elen1","id":"22992299","total_energy_consumption_kwh":2816.304,"current_power_consumption_phase1_kw":0.09471,"current_power_consumption_phase2_kw":0.10602,"current_power_consumption_phase3_kw":0.01606,"customer":"123456","timestamp":"1111-11-11T11:11:11Z"}
|
||||
|Elen1;22992299;2816.304000;0.094710;0.106020;0.016060;1111-11-11 11:11.11
|
||||
{"media":"radio converter (meter side)","meter":"ebzwmbe","name":"Elen1","id":"22992299","total_energy_consumption_kwh":2816.304,"current_power_consumption_kw":0.21679,"current_power_consumption_phase1_kw":0.09471,"current_power_consumption_phase2_kw":0.10602,"current_power_consumption_phase3_kw":0.01606,"customer":"123456","timestamp":"1111-11-11T11:11:11Z"}
|
||||
|Elen1;22992299;2816.304000;0.216790;0.094710;0.106020;0.016060;1111-11-11 11:11.11
|
||||
|
||||
# Test electricity meter with ESYS-WM20
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +0,0 @@
|
|||
telegram=||31446850249607016980A0119F27020480048300C408F709143C003D341A2B0B2A0707000000000000062D114457563D71A1850000|
|
||||
|
|
@ -134,7 +134,7 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
vector<uchar> content;
|
||||
|
||||
t->extractPayload(&content);
|
||||
|
||||
|
||||
// Consumption
|
||||
// Previous Consumption
|
||||
uchar prev_lo = content[14];
|
||||
|
|
@ -144,8 +144,7 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
|
||||
string prevs;
|
||||
strprintf(prevs, "%02x%02x", prev_lo, prev_hi);
|
||||
int offset = t->parsed.size()+4;
|
||||
t->addMoreExplanation(offset, " energy used in previous billing period (%f HCA)", prevs);
|
||||
//t->addMoreExplanation(14, " energy used in previous billing period (%f HCA)", prevs);
|
||||
|
||||
// Previous Date
|
||||
uchar date_prev_lo = content[12];
|
||||
|
|
@ -157,8 +156,7 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
int year_prev = (date_prev >> 9) & 0x3F;
|
||||
prev_energy_hca_date = std::to_string((year_prev + 2000)) + "-" + leadingZeroString(month_prev) + "-" + leadingZeroString(day_prev) + "T02:00:00Z";
|
||||
|
||||
offset = t->parsed.size()+2;
|
||||
t->addMoreExplanation(offset, " last date of previous billing period (%s)", prev_energy_hca_date);
|
||||
//t->addMoreExplanation(offset, " last date of previous billing period (%s)", prev_energy_hca_date);
|
||||
|
||||
// Current Consumption
|
||||
uchar curr_lo = content[18];
|
||||
|
|
@ -168,8 +166,7 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
|
||||
string currs;
|
||||
strprintf(currs, "%02x%02x", curr_lo, curr_hi);
|
||||
offset = t->parsed.size()+8;
|
||||
t->addMoreExplanation(offset, " energy used in current billing period (%f HCA)", currs);
|
||||
//t->addMoreExplanation(offset, " energy used in current billing period (%f HCA)", currs);
|
||||
|
||||
// Current Date
|
||||
uchar date_curr_lo = content[16];
|
||||
|
|
@ -184,10 +181,9 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
if (day_curr <= 0) day_curr = 1;
|
||||
int month_curr = (date_curr >> 9) & 0x0F;
|
||||
if (month_curr <= 0) month_curr = 12;
|
||||
curr_energy_hca_date = year_curr + "-" + leadingZeroString(month_curr) + "-" + leadingZeroString(day_curr) + "T02:00:00Z";
|
||||
curr_energy_hca_date = to_string(year_curr) + "-" + leadingZeroString(month_curr) + "-" + leadingZeroString(day_curr) + "T02:00:00Z";
|
||||
|
||||
offset = t->parsed.size()+6;
|
||||
t->addMoreExplanation(offset, " last date of current billing period (%s)", curr_energy_hca_date);
|
||||
// t->addMoreExplanation(offset, " last date of current billing period (%s)", curr_energy_hca_date);
|
||||
|
||||
// Temperature
|
||||
// Room Temperature
|
||||
|
|
@ -198,8 +194,7 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
|
||||
string room_ts;
|
||||
strprintf(room_ts, "%02x%02x", room_tlo, room_thi);
|
||||
offset = t->parsed.size()+10;
|
||||
t->addMoreExplanation(offset, " current room temparature (%f °C)", room_ts);
|
||||
// t->addMoreExplanation(offset, " current room temparature (%f °C)", room_ts);
|
||||
|
||||
// Radiator Temperature
|
||||
uchar radiator_tlo = content[22];
|
||||
|
|
@ -209,11 +204,10 @@ void MeterFHKVDataIII::processContent(Telegram *t)
|
|||
|
||||
string radiator_ts;
|
||||
strprintf(radiator_ts, "%02x%02x", radiator_tlo, radiator_thi);
|
||||
offset = t->parsed.size()+12;
|
||||
t->addMoreExplanation(offset, " current radiator temparature (%f °C)", radiator_ts);
|
||||
// t->addMoreExplanation(offset, " current radiator temparature (%f °C)", radiator_ts);
|
||||
}
|
||||
|
||||
string MeterFHKVDataIII::leadingZeroString(int num) {
|
||||
string new_num = (num < 10 ? "0": "") + std::to_string(num);
|
||||
return new_num;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
18
src/wmbus.cc
18
src/wmbus.cc
|
|
@ -716,7 +716,8 @@ Detected detectWMBusDeviceSetting(string devicefile,
|
|||
X(0x8F, ELL_IV, "ELL: IV", 16, CI_TYPE::ELL, "CC, ACC, M2, A2, SN, Payload CRC") \
|
||||
X(0x86, ELL_V, "ELL: V", -1, CI_TYPE::ELL, "Variable length") \
|
||||
X(0x90, AFL, "AFL", 10, CI_TYPE::AFL, "") \
|
||||
X(0xA2, MFCT_SPECIFIC, "MFCT SPECIFIC", 0, CI_TYPE::TPL, "")
|
||||
X(0xA0, MFCT_SPECIFIC_A0, "MFCT SPECIFIC", 0, CI_TYPE::TPL, "") \
|
||||
X(0xA2, MFCT_SPECIFIC_A2, "MFCT SPECIFIC", 0, CI_TYPE::TPL, "")
|
||||
|
||||
enum CI_Field_Values {
|
||||
#define X(val,name,cname,len,citype,explain) name = val,
|
||||
|
|
@ -1102,7 +1103,7 @@ bool Telegram::parseAFL(vector<uchar>::iterator &pos)
|
|||
addExplanationAndIncrementPos(pos, 1, "%02x afl-len (%d)",
|
||||
afl_len, afl_len);
|
||||
|
||||
int len = ciFieldLength(ell_ci);
|
||||
int len = ciFieldLength(afl_ci);
|
||||
if (remaining < len) return expectedMore(__LINE__);
|
||||
|
||||
afl_fc_b[0] = *(pos+0);
|
||||
|
|
@ -1558,15 +1559,15 @@ bool Telegram::parseTPL(vector<uchar>::iterator &pos)
|
|||
int ci_field = *pos;
|
||||
if (!isCiFieldOfType(ci_field, CI_TYPE::TPL))
|
||||
{
|
||||
warning("(wmbus) Unknown tpl-ci-field %02x\n", tpl_ci);
|
||||
return true;
|
||||
warning("(wmbus) Unknown tpl-ci-field %02x\n", ci_field);
|
||||
return false;
|
||||
}
|
||||
tpl_ci = ci_field;
|
||||
tpl_start = pos;
|
||||
|
||||
addExplanationAndIncrementPos(pos, 1, "%02x tpl-ci-field (%s)",
|
||||
ci_field, ciType(ci_field).c_str());
|
||||
tpl_ci = ci_field;
|
||||
int len = ciFieldLength(ell_ci);
|
||||
tpl_ci, ciType(tpl_ci).c_str());
|
||||
int len = ciFieldLength(tpl_ci);
|
||||
|
||||
if (remaining < len+1) return expectedMore(__LINE__);
|
||||
|
||||
|
|
@ -1576,7 +1577,8 @@ bool Telegram::parseTPL(vector<uchar>::iterator &pos)
|
|||
case CI_Field_Values::TPL_78: return parse_TPL_78(pos);
|
||||
case CI_Field_Values::TPL_79: return parse_TPL_79(pos);
|
||||
case CI_Field_Values::TPL_7A: return parse_TPL_7A(pos);
|
||||
case CI_Field_Values::MFCT_SPECIFIC:
|
||||
case CI_Field_Values::MFCT_SPECIFIC_A0:
|
||||
case CI_Field_Values::MFCT_SPECIFIC_A2:
|
||||
{
|
||||
header_size = distance(frame.begin(), pos);
|
||||
suffix_size = 0;
|
||||
|
|
|
|||
|
|
@ -57,6 +57,9 @@ Received telegram from: 34333231
|
|||
Received telegram from: 58234965
|
||||
manufacturer: (TCH) Techem Service
|
||||
device type: Heat meter
|
||||
Received telegram from: 11776622
|
||||
manufacturer: (TCH) Techem Service
|
||||
device type: Heat Cost Allocator
|
||||
Received telegram from: 88018801
|
||||
manufacturer: (INE) INNOTAS Elektronik, Germany
|
||||
device type: Heat Cost Allocator
|
||||
|
|
|
|||
|
|
@ -20,6 +20,7 @@ METERS="MyWarmWater supercom587 12345678 NOKEY
|
|||
MyElectricity1 amiplus 10101010 NOKEY
|
||||
Duschen mkradio3 34333231 NOKEY
|
||||
HeatMeter vario451 58234965 NOKEY
|
||||
Room fhkvdataiii 11776622 NOKEY
|
||||
HeatMeter eurisii 88018801 NOKEY
|
||||
Tempoo lansenth 00010203 NOKEY
|
||||
Rummet rfmamb 11772288 NOKEY
|
||||
|
|
|
|||
Ładowanie…
Reference in New Issue