celsworth / lxp-bridge

A bridge to MQTT/InfluxDB/Postgres for communications with LuxPower inverters
MIT License
9 stars 14 forks source link

Allow signed integer #161

Closed dgcartersa closed 1 year ago

dgcartersa commented 1 year ago

This fixes an error with data coming from an SNA5000 inverter when sending to InfluxDB. The inverter provides a negative integer causing the process to panic.

celsworth commented 1 year ago

I'm happy to merge this as it is pretty similar to a problem I was discussing with someone over email not too long ago.

But out of curiosity, which value are you seeing that can be negative, is that actually a valid scenario? The problem we were having was that the inverter was sending negative numbers for battery cycle count which is clearly nuts.