Moode Forum
How to add rotary encoder for switching between radio stations? - Printable Version

+- Moode Forum (https://moodeaudio.org/forum)
+-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3)
+--- Forum: Support (https://moodeaudio.org/forum/forumdisplay.php?fid=7)
+--- Thread: How to add rotary encoder for switching between radio stations? (/showthread.php?tid=1668)



How to add rotary encoder for switching between radio stations? - bertron - 08-26-2019

Hello,

I want to add a rotary encoder to the GPIO port of my raspberry pi to switch between the stations on the moode webradio.
How should the encoder be wired and what do I have to add or alter in the code and settings?

thanks for any help

Bernd


RE: How to add rotary encoder for switching between radio stations? - TheOldPresbyope - 08-26-2019

(08-26-2019, 03:25 PM)bertron Wrote: Hello,

I want to add a rotary encoder to the GPIO port of my raspberry pi to switch between the stations on the moode webradio.
How should the encoder be wired and what do I have to add or alter in the code and settings?

thanks for any help

Bernd

Hi, Bernd.

The devil is in the details. What is your expectation for "to switch between the stations"? Do you imagine scrolling through a station list ala a typical InternetRadio? That would take a lot of work.

Basic scripting is already available for the classic Play Next/Play Prev control of playlist tracks some folks implement on their systems using hard-wired buttons or an IR or wireless controller. Once a radio station playlist is loaded, one can use the existing framework to step through the stations on the list.

Regards,
Kent


RE: How to add rotary encoder for switching between radio stations? - bertron - 08-26-2019

Hi Kent,

yes, exactly. What I ment is scrolling through the stations that are written on a list. But I have no idea how to wire the encoder and how to configure moode to do so.
I thought that someone might have already done this as it is the typical function of an InternetRadio as you said.
Bernd


RE: How to add rotary encoder for switching between radio stations? - DRONE7 - 08-26-2019

I'll take a guess that you want to operate a moOde device as a conventional mantle radio...? No screen and no access from other devices...just turn on and select from a favourite list of stations...? Hence your question about a rotary encoder.

If this is the use case then you will find something similar has been done using infra-red remote and /or push-buttons.
Tutorials are in the FAQ and Guides section of the forum.


RE: How to add rotary encoder for switching between radio stations? - bertron - 08-26-2019

Yes, that's more or less what I had in mind. I want to add a OLED display later, like that one described here:
http://moodeaudio.org/forum/showthread.php?tid=155

But without the need to access from other devices to select the station. OK, I will have a look at the FAQ and tutorials.
Thanks!

Bernd


RE: How to add rotary encoder for switching between radio stations? - bertron - 08-27-2019

I got it know, was not too difficult. Just changing some commands in the script provided by Cyanoazimin:
http://moodeaudio.org/forum/showthread.php?tid=198&pid=9428#pid9428

Bernd