error counting, fix

This commit is contained in:
2020-09-07 19:48:07 +02:00
parent 1ca935742a
commit c9acb92466

View File

@ -66,7 +66,7 @@ abstract public class MbusDevice {
}
public double getErrorRatio() {
return this.errorCnt / this.successCnt;
return this.errorCnt / (this.successCnt + this.errorCnt);
}
public void parse(byte[] frame) throws MbusException {