It uses the returned watermeter_current_alarms directly but this value is built using binary flags (see here) so it can contain multiple errors and, more serious, it values goes from 0 to 1023 which will cause an overflow on the alarm_error_text array.
Current code in the lambda that builds the alarm message (and previous alarm message) is wrong.
It uses the returned
watermeter_current_alarms
directly but this value is built using binary flags (see here) so it can contain multiple errors and, more serious, it values goes from 0 to 1023 which will cause an overflow on thealarm_error_text
array.Here is the quick fix I applied for my usage: