Repository navigation
Conversation
|
Initial inquiry in OctoPrint Discord/#dev-core; capturing as it contains interesting notes about current behavior in this situation:
|
foosel
left a comment
There was a problem hiding this comment.
Hm... I'd definitely prefer an abstraction layer here - use hwmon info if available, otherwise try to fall back on vcgencmd. No matter where the data comes from, report it back from one single helper, and use that report everywhere else. Maybe include the source (hwmon or vcgencmd) for debugging reasons, but that's about it.
So no separate check enabled flags, no separate properties on the responses, but everything aligned.
This is a rough pass at adding/conveying https://www.kernel.org/doc/html/latest/hwmon/raspberrypi-hwmon.html status reporting, for when
vcgencmdis not available.It has not been tested, only a quick pass meant to convey the idea and drum conversation. Questions exist about how to formulate/alter the abstraction (both at the implementation/technical level and also those facing the administrator and user), and I see now also that more recent raspberrypi-hwmon driver reports on more than simply "presently undervolt."