pigeond pigeond


Button daemon. Basically monitoring the buttons of my ipaq. When buttons are pressed, it will run a certain stuffs for you.

The cool thing is, you can setup multiple presses for one single button or combinations of different buttons to do something.

For example, you can do:
  • One Record button press for decreasing volume...
  • Two Record button press for increasing volume...
  • Three Record button press for start playing mp3...
  • Four Record button press for start stopping mp3...

And also you can do:
  • Record button press then Calendar button press for turning on backlight
  • Record button press then up up down down for running Storm?
  • Calendar, Contacts, Q, Start to restart X

In theory there isn't a limit on the combinations of the buttons, though it's a #define value currently as 32 for the buffer size (which means 16 button presses and releases). I think that's enough even if you want to setup a combinations like up up down down left right left right record contact start :)

Run it with -l to run buttond in learning mode, what it will do is to wait until you press one button combination, then it will append the combination code to the configuration file (/etc/buttond.conf). You can edit the file yourself afterwards to put the actual running command.

buttond will reread configuration on SIGHUP.

buttond will not work properly if you have multiple buttond running. i.e. if you have buttond running, running another buttond -l will not work properly. I will look into this later.

Just run it with -h to get more help.

buttond 0.1 ipkg (Sorry for the broken link a while ago)


It contains buttond binary, buttond init script with links to start buttond at level 2 and stop buttond at level 6 (the usual). It DOES NOT contain /etc/buttond.conf. Run buttond -l to create your initial configuration file.

Alternatively, you can add

src pigeonfeeds http://pigeond.net/ipaq/feeds

into your /etc/ipkg.conf, and then ipkg update ipkg install buttond (the usual).

Also, btw, buttond is now in Familiar unstable feed, too.

buttond version 0.1

arm binary


A sample buttond.conf

The simple-mixer used in this sample is here.

It's a very simple code I wrote. Run simple-mixer to show settings. Run with -v, -t, and -b to control the volume, treble, and bass respectively. Input can be:
  • simple-mixer -v 50 will set the volume to 50
  • simple-mixer -b 90 will set the bass 50
  • simple-mixer -v +5 will raise the volume by 5
  • simple-mixer -v -5 will lower the volume by 5

dc is also working a python gui for buttond, lots of thanks :)

  • Add support for doing an action by holding down a button before the release
  • Tidy up the code a bit maybe
  • Look for bugs and memory leaks, and fix them!
blog top 24 tags
api bonding debian engrish fglive fgmap flightgear google ISP laptop lca2007 lca2008 linux live map mpserver navaids network qotd quote of the day taiwan vim windows wine
Web pigeond.net

this site is
created with vim

nearly all pages in this site are validated as
Valid HTML 4.01!

css validated by
Valid CSS!

pigeond.net copyright 2001 - 2014
designed, created, and coded by pigeon at pigeond dot net
all rights reserved