mirror of
https://github.com/UtilitechAS/amsreader-firmware.git
synced 2026-03-06 11:33:38 +00:00
Show error when unknown data was received (#1013)
This commit is contained in:
@@ -324,6 +324,7 @@
|
||||
"-51" : "Authentication failed",
|
||||
"-52" : "Decryption failed",
|
||||
"-53" : "Encryption key invalid",
|
||||
"89" : "Unrecognized data received from meter",
|
||||
"90" : "No HAN data received for at least 30s",
|
||||
"91" : "Serial break",
|
||||
"92" : "Serial buffer full",
|
||||
|
||||
@@ -46,6 +46,7 @@ ADC_MODE(ADC_VCC);
|
||||
#define METER_PARSER_PULSE 2
|
||||
#define METER_PARSER_KAMSTRUP 9
|
||||
|
||||
#define METER_ERROR_UNKNOWN_DATA 89
|
||||
#define METER_ERROR_NO_DATA 90
|
||||
#define METER_ERROR_BREAK 91
|
||||
#define METER_ERROR_BUFFER 92
|
||||
@@ -1345,6 +1346,8 @@ bool readHanPort() {
|
||||
if(data != NULL) {
|
||||
if(data->getListType() > 0) {
|
||||
handleDataSuccess(data);
|
||||
} else {
|
||||
meterState.setLastError(METER_ERROR_UNKNOWN_DATA);
|
||||
}
|
||||
delete data;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user