Badut: Home Theater Media Browser
Badut is a Home Theater PC media browser application, an audio and
video jukebox. It is preconfigured to play video and audio files
using mplayer or xine. The configuration can be easily changed and
extended by the user. CDRDAO audio CD images can be played
natively. Badut can show thumbnailed screen captures for
the selected item.
Badut has direct support for the Soundgraph iMON LCD+IR module,
e.g. found in recent Silverstone GD01 chassis.
Why another HTPC software |
※ |
|
Screen Shot
|
What's the advantage over, say, MythTV? |
※ |
Badut can overlay directory trees and present them as
one merged tree to the user.
E.g. if you specify /media/* as a set of root dirs, the relative
path /videos/ as shown by Badut will be expanded to
/media/*/videos and all files found in those directories will be
presented as one merged directory.
This makes the organisation of your media files easier because you can
distribute them over several directories (e.g. over several
partitions and disks) and still have a consistent display.
-
Badut can play cdrdao audio images out of the box. This
is for people who want the CD image as one big uncompressed file where
track transitions without pauses cause no audible distortion.
-
The Soundgraph iMON-LCD, e.g. in a SilverStone GD01 (Grandia) chassis,
is driven graphically with hand-optimised fonts that are narrow, yet very
well-readable and have a high spouse acceptance factor. :-)
-
There is no initial, fully recursive scan of the browsed directories.
Badut only scans what is necessary for showing the current directory.
So it starts up quickly even with many files in the directory
structure.
-
The configuration files are easy to read and write because
they are kept simple and are well documented.
-
You can easily write plugins for special purposes easily. The
interfaces are documented well, and kept to a minimum.
-
It is hard to accidentally exit the GUI and by default no applications
will be started that cannot handle infrared remote signals. You are
able to control the HTPC box with LCD + IR remote alone without the
accidental need for a keyboard or mouse.
-
Badut supports recording CDs/DVDs from the normal menu and is
extensible by arbitrary user actions.
- Watch TV, record TV shows, watch weather news, browse the web:
Badut is a jukebox-only application for now for browsing
your audio and video media.
- Drive any other LCDs other than the iMON LCD. Only USB ID 15c2:0038
is currently supported. (But it seems it is quite wide-spread.)
Driver plugins are easily written but have not been written yet.
Support for LCDd is also still missing: I have my own graphical daemon.
|
LCD Screen Shot
|
- Browse files (typically audio and video) and play them according to
customisable rules with whatever program you want to. Out of the
box, the usual video formats are pre-configured to be played by mplayer
or xine.
|
HTPC Photo
|
Thu, 2008-08-07: I wrote this whole stuff mainly because the iMON LCD
I was using was not properly supported: you still needed a patch for
LIRC even for the CVS version. You still need a patch for LCDd.
The patches which are available in some form or another from several
fora work quite fine but LCDd only handles text, but my LCD display is
graphical, and also I found the font quite displeasing and wasteful of
space.
Another reason was that MythTV, which I tried first, would not read my
CDRDAO images out of the box.
Further, I was displeased by the speed of MythTV's media browser,
because it recursively searches the whole directory tree when
starting, which takes a considerable amount of time.
Moreover, MythTV opens applications that cannot not handle remote
control commands when you accidentally open the wrong item in the
MythTV menus.
Finally, the MythTV configuration was partly done via huge menues in
the GUI and partly, e.g. for some ALSA stuff, in good-old config
files. I decided that the good old way would be the way I want it:
nice configure files, also because a consistent and complete
configurability inside the GUI is very hard to achieve.
I exclusively need a media browser, so I only used one plugin of
MythTV. This plugin's functionality did not fully convince me, so I
started to write my own little browser, basically without bells or
whistles, but with the functionality I need and with the possibility
for expanding it to something fancy later.
|
LCD Photo
|
This package consists of the following pieces:
- 'filesel', a command line program to construct virtual directory hierarchies,
- 'gfilesel', the media browser: the main application,
- 'gtocplay', a plugin for 'gfilesel' (see below) to play CDRDAO .toc files,
- A LIRC config files for 'gfilesel'. It supports two drivers: that very
iMON LCD+IR device and also the mceusb2 driver.
- modprobe config file for preventing HID driver from
grabbing the iMON device (we drive it using LIRC),
- 'lcdgraph', the graphical LCD daemon,
- an init script to start the 'lcdgraph' daemon,
With these pieces, it should be possible to turn a standard Ubuntu 8.04
box (and probably most other Linux boxes, too) into a media browser HTPC.
If you do not need LCD support, then the installation of Badut probably
only takes a few seconds. Ok, maybe a few minutes. :-) If you have one
of the very common mceusb2 remote controls, the remote control will
work, too.
However, when installing Badut with support for the iMON LCD+IR, you
still need some manual work, because that USB device is not fully
supported by Linux distros yet, as mentioned above. You have to
recompile LIRC, install the new modules, probably removing the old
ones. I did this on Ubuntu 8.04 (actually, on Mythbuntu 8.04, which is
derived from Xubuntu 8.04, but that should be no difference).
For the LCD to work, you need the following USB device (check 'lsusb'):
Bus 004 Device 003: ID 15c2:0038 SoundGraph Inc.
The other stuff will work with any other hardware, too.
For other remote controls than the two packaged, you need to write a
config file to configure the keys, however. This is due to an awkward
configuration philosophy of LIRC, which calls the keys different on
each remote control. There are no standard names, so you need to
check with 'irw' what the control codes are for your remote control.
For installation instructions, download and unpack
Badut and read the INSTALL document.
- control with keyboard and remove control
- merge several directory trees into one merged tree to be
browsed by the user
- allow virtial directories to be added, e.g. the contents
of CDRDAO .toc files.
- start external players or run plugins according to simple
configure files
- graphical driver for LCD displays
- Shows screen captures if available
Please be so kind to give me feedback on all bugs and quirks. Compilation
issues, failures, crashes, missing features.
- Version 5 (not yet released)
-
- bug fix
-
After playing raw audio toc files, gfilesel would consume
100% CPU. This is fixed; it was caused by a misinterpretation
of the GTK documentation.
- feature
-
gfilesel knows more actions now to make it easier to cope
with different types of remote controls and still do the
right thing(tm) in the different situations.
The navigation keys 'left','right','up','down' are all native
actions now.
The user actions can be entered by a new 'user' action
+ '0'..'9' keys, so you don't need an extra key for each
user action.
- feature
-
DVD playback of raw files was improved: for DVDs where the
navigation does not work in mplayer for some reason
(actually, for me those are most DVD images), the DVD is now
opened as a virtual directory, showing the titles and their
size is MB. The titles can then directory be played.
The old dvdnav playback is still accessible as user action 1.
- feature
-
When starting audio playback, some hardware needs a certain time to
be initialised. To cope with this, gtocplay can be configured to
send silence before actually starting to play the payload.
- Version 4
-
- feature
-
PNG screen captures are searched in the .caps subdirectory and
displayed on the right edge.
- Version 3
-
- bugfix
-
Bad command line option for mplayer fixed in predefined config
file rules.
- feature
-
Directories can be inserted at any point in the virtual
directory hierarchy.
- feature
-
'record' actions can be defined. For audio.toc, a default
action invoking 'cdrdao write ...' is included.
- feature
-
user actions can be defined.
- feature
-
menu entries can be defined: i.e., an action (=shell command)
can be assigned to any virtual directory entry.
- feature
-
'gfilesel' reads command line options from config files.
- feature
-
'gfilesel' can display a clock.
- feature
-
DBus/Hal notification for mounting/unmouting to automatically
refresh the display.
- Version 2
-
- bugfix
-
audio.toc files play (hopefully): there was a bad config file left from an
alpha test version that has been repaired.
- bugfix
-
.toc parser: the last track was not listed.
- bugfix
-
'gtocplay' does not claim anymore to be able to resample the
stream, so it drives ALSA devices correctly that do software
resampling.
- feature
-
Clauses in the config files (unfold{}, run{}, and slave{}) can
have user-defined labels that can be matched in prefer{} clauses.
- clean-up
-
gfilesel tries to not crash if the connection to lcdgraph
breaks off, e.g. when the daemon is restarted. It will then try to
reconnect.
- clean-up
-
Make the config files more self-explanatory; improve the
README files.
- Version 1
- initial release
- A detailed description of how to get the iMON device working. You can use the
LIRC patch provided there, too, instead of my patch. My patch is basically that
patch fixed for a more recent version of the LIRC CVS. Since 2008-08-24, my updated
patch is also in LIRC CVS, so no patch is needed anymore.