GPIO rotary volume
-
@subs Controlling the ALSA controls is explained i the HiFiBerry wiki article that I wrote some time ago, if you speak about this?
-
@lackyluuk @dh04000 the idea is to have a gpio read Volume+ or Volume- ticks. So yes, the Hifiberry configuration part is almost exactly what will be done. May also need to check with recalbox internal audio volume, if it needs to be saved or not ...
-
@subs okay cool. Yes, this could be a useful improvement. Because I cannot use the internal audio seekbar from ES with my script
-
<topic moved to the right category>
-
@subs
I am going to buy that rotary encoder found in the github link. When it arrives, would you mind helping me integrate this into my Recalbox 4.0 build? I'm going to upgrade to 4.1 due to fba rom set version changes. Thank you.
-
4.1 is not publicly available. But either me either @supernature2k can help you to make it run meanwhile. Still, i didn't check how the button works, so wait a little before buying it
-
@subs said in GPIO rotary volume:
4.1 is not publicly available. But either me either @supernature2k can help you to make it run meanwhile. Still, i didn't check how the button works, so wait a little before buying it
Alright, I'll hold off on the order. Thank you for assistance subs and supernature2k!
-
@dh04000 several things as looked a little more in depth ... So :
- looks like it's a little more complicated than expected to port it
- it's python3, and we run python 2.7, so the script must be backported to python 2.7. Can't tell how much work it represents, i don't know enough python
- i think it's too much work for @supernature2k
-
@subs said in GPIO rotary volume:
@dh04000 several things as looked a little more in depth ... So :
- looks like it's a little more complicated than expected to port it
- it's python3, and we run python 2.7, so the script must be backported to python 2.7. Can't tell how much work it represents, i don't know enough python
- i think it's too much work for @supernature2k
That's a shame
Would this program help? https://wiki.python.org/moin/3to2 https://wiki.python.org/moin/3to2 It converts python 3 code to python 2 code. Maybe it'll work without modification? Crossing my fingers.
-
Here's another way to do a rotary encoder. No idea if python 3 or 2. https://volumio.org/forum/gpio-pins-control-volume-t2219.html
Looks even simpler. But, that button to play music lines would need to be cut out.
-
@dh04000 indeed, much easier. Can't say if it's python 3 or not, but it looks rather easy to setup
-
Is there any hope of a gpio volume by button or rotary encoder in the future, or should I start working on a new plan for my arcade box? Do you know if usb volume controllers work on recalbox?
-
It's hard to tell. We just lack devices to test. Almost everything in recalbox is ready to handle it, except the gpio handling
-
@subs said in GPIO rotary volume:
It's hard to tell. We just lack devices to test. Almost everything in recalbox is ready to handle it, except the gpio handling
Lacking devices to test, does that mean that you lack a rotary encoder to test? How much to the recalbox paypal would solve that? There's an issue withe the gpio handling? I thought recalbox could read gpio events already?
-
@dh04000 we don't have any rotary button such as yours we do handle gpio, hopefully lol
-
@subs said in GPIO rotary volume:
@dh04000 we don't have any rotary button such as yours we do handle gpio, hopefully lol
Post a link to the cheapest amazon listing for a compatible rotary encoder with free shipping in France (do you have Amazon PRIME?). I'll put the listing money in the Recalbox paypal after my next pay cycle.
-
It's not a question of price, but time (wire, code, test), finding something that fits the needs, being able to make a description of how the button works so that anyone can find a similar rortary button.
Let's take a shortcut : does it work like this
If so, that's as we would expect it and it is easy.
-
@subs said in GPIO rotary volume:
It's not a question of price, but time (wire, code, test), finding something that fits the needs, being able to make a description of how the button works so that anyone can find a similar rortary button.
Let's take a shortcut : does it work like this
If so, that's as we would expect it and it is easy.
I offered money because it is what I can offer Recalbox. I can't code, so the only things I can offer is time, and money. Time is me finding this and trying to talk about a feature that users (like me) might enjoy to have. I'd be willing to test it as well, tell me when and I'll purchase myself a rotary encoder. Money being to purchase the parts needed to allow you and others to attempt to implement it. If I could code, I would do it myself and contribute the code, but I can't.
Anyhoo, the github code matches an Adafruit rotary encoder, and from what I can gleam from the data sheet (https://cdn-shop.adafruit.com/datasheets/pec11.pdf), that image you posted matches the functionality, where the button is a simple on/off mechanism, and the left and right turns are a series of A or B connections to the common ground (middle post), depending on which direction is turned.
Seems to be what you expect.
-
Well @supernature2k can handle this, just leave him some time. But it should work one way or another if it's just a pair of switches
-
Hello @dh04000
look this script : https://gist.github.com/savetheclocktower/9b5f67c20f6c04e65ed88f2e594d43c1
may be you can create same for recalbox .