vedirect
vedirect copied to clipboard
packet is not cleared between callbacks
Thank you for publishing this code.
I found that packets are not cleared between call-back invocations. This means that the packet
dict may contain lingering values from previous callbacks and not only data from the very last message out of the MPPT.
To reproduce, simply add a key+value to the packet in the callback and note that it is retained across callbacks.
I work around this by calling packet.clear()
at the end of my callback implementation. Not pretty, but effective.