Open mortenfyhn opened 5 months ago
It does seem to be a busy loop, the HX711 driver just does "while not ready, delay(0)".
I should instead try to estimate when it will be ready and do some kind of proper low power sleep until then.
I should also consider just hooking up an interrupt to the DOUT pin, which is what "is ready" actually checks: When DOUT goes low, it means data is ready for reading.
And I should do some timing again to see which parts of the program take how much time.
And then consider optimizing the rest of the code.
If the read is a busy loop, maybe that's wasting energy and I instead can sleep until it's ready.