2.4GHz Airmouse as remote

Raspberry Pi related support

Re: 2.4GHz Airmouse as remote

Postby SlF » 04 Aug 2017, 16:20

yeongheon wrote:Hi,
I am trying to setup 2.4GHz Airmouse too. According to your guide, I installed empcd and base-devel. And it seems that the Airmouse remote identified. But only volumeup and down are working.

So, I need to find Key name of mouse button to describe in empcd.conf. But I dont know.

How can I get the Keyname?


I posted a guide on my website. It's in German. You may want to use google translator.
https://ole-hellmers.de/2017/03/24ghz-f ... runeaudio/

https://translate.google.de/translate?s ... t=&act=url

best regards

ole
SlF
 
Posts: 27
Joined: 29 Sep 2015, 14:09
Location: Germany

Re: 2.4GHz Airmouse as remote

Postby yeongheon » 05 Aug 2017, 07:30

Thanks, SIF


I found that my AirMouse already working with runeaudio(raspberry pi3) as mouse before installing empcd. especially volumeup/down.
I guess that it should be disabled for using mpd remote control. But i dont know how.

it is my airmouse.
https://www.aliexpress.com/item/Free-Sh ... 0.0.ODnJoJ

Please help me to use this remote control for runeaudio. and the airmouse could not be used for runeaudio remote?

Mentioned from SIF, background service for empcd did not working properly. Once I opened terminal and login the runeaudio, and run command "empcd -f", it is working perfectly during the command(empcd -f) is running.
yeongheon
 
Posts: 3
Joined: 03 Mar 2017, 08:01

Re: 2.4GHz Airmouse as remote

Postby SlF » 11 Aug 2017, 10:52

yeongheon wrote:Thanks, SIF


I found that my AirMouse already working with runeaudio(raspberry pi3) as mouse before installing empcd. especially volumeup/down.
I guess that it should be disabled for using mpd remote control. But i dont know how.

it is my airmouse.
https://www.aliexpress.com/item/Free-Sh ... 0.0.ODnJoJ

Please help me to use this remote control for runeaudio. and the airmouse could not be used for runeaudio remote?


You need to control MPD in order to control Runeaudio. Runeaudio gets the current status of MPD and displays it.
Focus on the last part of my guide:
"Mit evtest habe ich ausmachen können, welche Signale die Tastatur sendet."
You need to use evtest to find out the commands, that your remote is sending.
e.g. "KEY_HOMEPAGE" which is the home button. Just press a button and see what key gets send. "UP" "DOWN" "REPEAT" means if the button is pressed, released or hold.

You may want to use my config file, most buttons should work since our remotes are very similar.

Edit: since there is no mouse in shell you don't need to disable the air mouse function. Just use the keys.

Code: Select all
##################################################
# ecmpd.conf by Jeroen Massar <jeroen@massar.ch>
# Example empcd configuration file
#
# Lines starting with ‚#‘ or ‚//‘ are comment lines
# Repeating spaces and tabs are trimmed
##################################################

##################################################
# MPD settings
##################################################
# Run empcd under the ‚mpd‘ account
user mpd

# mpd_host [<password>@]<host> (defaults to „localhost“)
mpd_host localhost

# mpd_port <port> (defaults to 6600)
mpd_port 6600

# Device to read events from
//eventdevice /dev/input/event0

# Exclusive (default) / Non-Exclusive device access
//exclusive

##################################################
# Key configuration
##################################################
#
# key <key-id> up|down|repeat <function> [arguments]
#
# down   = key gets pressed down
# up     = key goes up (after being pressed down)
# repeat = key is kept down and sends repeat events
#
# functions (also see ‚empcd –list-functions‘):
# exec <shellcmd>       Execute a shell command (eg exec mount /dev/sdb2 /mnt)
# mpd_next              MPD Next Track
# mpd_play              MPD Previous Track
# mpd_stop              MPD Stop Playing
# mpd_play              MPD Start Playing
# mpd_pause [on|off]    MPD Pause Toggle (no options) or set
# mpd_seek              MPD Seek
#                       „mpd_seek 0“   – begin of track
#                       „mpd_seek 100“ – begin of track
#                       „mpd_seek +10“ – advance 10 seconds
#                       „mpd_seek -20“ – backward 20 seconds
# mpd_random            MPD Random Toggle (no options) or set
#
#
###################################################
# Play/Pause
key KEY_ENTER             UP      mpd_pause
key KEY_MUTE    UP    mpd_play
key KEY_POWER    UP    mpd_stop

# Prev/Next
key KEY_LEFT         UP      mpd_prev
key KEY_RIGHT          UP      mpd_next

# Volume
key KEY_VOLUMEDOWN    DOWN    mpd_volume -5%
key KEY_VOLUMEUP      DOWN    mpd_volume +5%
key KEY_VOLUMEDOWN    REPEAT    mpd_volume -1%
key KEY_VOLUMEUP    REPEAT    mpd_volume +1%

# key KEY_MUTE    UP    mpd_volume -100%

# Seek to the beginning of the current song
key KEY_HOMEPAGE       UP      mpd_seek 0

#  2 seconds back/forward on 1 hit,
# 10 seconds back/forward when holding
key KEY_DOWN         UP      mpd_seek -2
key KEY_DOWN         REPEAT  mpd_seek -10
key KEY_UP      UP      mpd_seek +2
key KEY_UP      REPEAT  mpd_seek +10
SlF
 
Posts: 27
Joined: 29 Sep 2015, 14:09
Location: Germany

Re: 2.4GHz Airmouse as remote

Postby yeongheon » 19 Aug 2017, 03:05

Hi, SIF

Thanks your kindly guide.

And I would like to ask about "empcd in daemon not working".
Does it need start manually yet? or Resolve it?


Regards
Yeong
yeongheon
 
Posts: 3
Joined: 03 Mar 2017, 08:01

support RuneAudio Donate with PayPal

Previous

Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 1 guest