Closed apreb closed 6 years ago
Hi, this is not a bug but intended action. I need to know about the last error code, even after a few correct readings, after a days :) With the code as above, this information disappears after the next correct reading. If You need clear readingerrcode then I can add a function like clearErrCode()
I understand your intention, however the overall output is not very clear, if you perform a read request you never know if the readingerrcode is related to the actual request or if it is a previous error that happnened in the past.
With the small hack i can clearly see what's happening in my debug:
(reading,errorcode)
(240.66,0) (0.78,0) (134.24,0) {"Ts":37094,"M":29192,"Va":240.7,"Aa":0.78,"Pa":134,"Err":832} (240.67,0) (0.78,0) (0.00,1) // --> got a crc here while reading power {"Ts":37095,"M":29192,"Va":240.7,"Aa":0.78,"Pa":134,"Err":833}
Anyway after knowing the intention for me it's OK either way.
that's why I suggest adding clearErrCode() function, then:
at the moment you are reading getErrCode() anyway, so additional clearErrCode() probably not be a problem :) and everyone will be happy
Sure, thank you!
done
You can use additional clearErrCode() or simply getErrCode(true) which will delete errorcode automatically
Perfect! Thanks for your availability!! you can close this issue
Hi, i found a small bug in the error code handling while troubleshooting NAN values.
could you please fix?
In this section: