echo
for testing There is still a chip that would need to check on the wheel, the best possible chip for the task, but that should still consume power.I think this approach can reach the lowest possible power consumption since nothing is running as long as the volume wheel doesn't move, which should be most of the time.
Yes, it is the power controller chip which also monitors battery, charger plug-in etc. with the same circuit (just on a different channel). But that is far from being as power hungry as the M4 or A15 cores running background tasks.There is still a chip that would need to check on the wheel, the best possible chip for the task, but that should still consume power.
Yes, exactly. That chip is already always onYes, it is the power controller chip which also monitors battery, charger plug-in etc. with the same circuit (just on a different channel). But that is far from being as power hungry as the M4 or A15 cores running background tasks.
So kudos to risca for finding the palmas gpadc threshold feature and providing us with working code!
BTW: the latest daemon will now be integrated into the LetuxOS rootfs.
Well, -rc (or "Prepatch") kernels are never "useable" since they are development and integration snapshots and Letux can't be better than Linus... See: https://www.kernel.org/category/releases.htmlI gave it a try,
First i applied the patches to the 5.6.19 kernel (since that's still the only one where everything (3d,screen,audio) works properly)
Patch applied with a few tweaks, but i assume some more parts of the palmas_gpadc driver outside the iio got changed since that kernel.
No values were read from the device.
on kernel letux-6.1.0-rc5:
iio device returns values, pyra_vol_mon works, but only reports values between 6 and 1249.
(just running it with "sudo ./pyra_vol_mon echo"
Reading the raw iio device with my own daemon does show the expected 0-2050 raw values, so it's probably something in the vol_mon
When the value is at minimum (6, but also happens if you manage to get it on anything <10) it triggers outputs continously, even if the value doesn't change.
To make things even more fun, the L15 audio device doesn't appear (only hdmi), so that kernel isn't usable for us. (on top of the other issues)
Great!I gave it a try,
I'll have a look and see if I can reproduce the issue. Is this Letux-5.6.19 kernel or mainline? I'm gonna assume Letux-5.6.19 and pyra_defconfigFirst i applied the patches to the 5.6.19 kernel (since that's still the only one where everything (3d,screen,audio) works properly)
Patch applied with a few tweaks, but i assume some more parts of the palmas_gpadc driver outside the iio got changed since that kernel.
No values were read from the device.
There are 2 sysfs/iio files to read data from:on kernel letux-6.1.0-rc5:
iio device returns values, pyra_vol_mon works, but only reports values between 6 and 1249.
(just running it with "sudo ./pyra_vol_mon echo"
Reading the raw iio device with my own daemon does show the expected 0-2050 raw values, so it's probably something in the vol_mon
Yes, this has been addressed in the latest revisions: https://github.com/Risca/pyra_vol_mon/When the value is at minimum (6, but also happens if you manage to get it on anything <10) it triggers outputs continously, even if the value doesn't change.
Great!
I'll have a look and see if I can reproduce the issue. Is this Letux-5.6.19 kernel or mainline?
Hmm... I can't get this kernel to boot on my devboard might be missing a cmdline parameter?It's Letux-5.6.19 with a few additional patches and a more debian compatible config. (We need aufs patched in for the dbp system, and the Letux config is very minimal)
It was scraped together from various git repos, but never really properly commited anywhere.
I'll give this one a tryExact source is here : https://packages.pyra-handheld.com/...-aufs_5.6.19-daveiii-pyradef-aufs.orig.tar.gz , with https://packages.pyra-handheld.com/...ef-aufs_5.6.19-daveiii-pyradef-aufs-3.diff.gz applied on top.
But if you can get it going in any of the letux-5.6.y kernels I'm sure I can get it going in ours.
Then maybe try this oneIf that fails, 5.10.y is a close second to being fully working, although that has an issue where the screen doesn't power back up after going into power/screensave mode.
Unfortunately anything after that, the gpu drivers either don't work at all, or give very low framerates. (with various amounts of breakage in other places too).
I'm able to reproduce the issue and I'll take a look when I get the timeFirst i applied the patches to the 5.6.19 kernel (since that's still the only one where everything (3d,screen,audio) works properly)
Patch applied with a few tweaks, but i assume some more parts of the palmas_gpadc driver outside the iio got changed since that kernel.
No values were read from the device.
Hmm... I have a couple of ideas, but I'm quite busy this week. You could try theYup, works.
Still get the 6..1249 range thing though, (and continous output on 6) with most recent (last commit was 3 days ago) pyra_vol_mon from that repo.
--min
flag to clamp the minimum value to e.g. 10 or something. I sometimes notice that the very first reading is slow/times out, but subsequent reads are much, much faster. How slow are we talking about here?Did you ever figure out why reading the adc is so incredibly slow/cpu heavy ? All the other iio devices seem to have none of the issues and report much faster at much lower cpu usage.
/root/pyra_vol_mon/pyra_vol_mon -c 2 echo &
wait(&status);