I was using your implementation as a guide to implementing a parallel API in golang, and I came across an issue I wanted to flag to your attention.
Consider the following uptime response returned by my Tesla Energy Gateway:
148h28m15.954321454s
The existing parse uptime in this repo treats the value after the decimal as microseconds. Note however the 9 digits after the decimal. For microseconds, we would expect 6 digits. What's being returned by the gateway after the decimal is nanoseconds, rather than microseconds. Parsing it with the existing code adds about 15 minutes to the uptime duration.
I was using your implementation as a guide to implementing a parallel API in golang, and I came across an issue I wanted to flag to your attention.
Consider the following uptime response returned by my Tesla Energy Gateway:
148h28m15.954321454s
The existing parse uptime in this repo treats the value after the decimal as microseconds. Note however the 9 digits after the decimal. For microseconds, we would expect 6 digits. What's being returned by the gateway after the decimal is nanoseconds, rather than microseconds. Parsing it with the existing code adds about 15 minutes to the uptime duration.
Hope that helps.