Fit-PC 2 as HTPC using (L) Ubuntu 11.04 Natty Narwhal
Monday, May 23rd, 2011This post explains how you can setup our own media centre using Lubuntu. Using my Fit-PC 2 as example.
Fit-PC is a small, light, fan-less nettop computer manufactured by the Israeli company CompuLab. I use it in my living room and it’s nearly invisible. When I install an SSD in it, I will stick it back on my TV.
After the installing Lubuntu from USB stick I had to manually shut the computer down. Apparently there are some ACPI bugs in Natty, but it’s not important. It will be on most of it’s life. I made sure the computer was up to date before installing display driver.
sudo apt-get update
sudo apt-get upgrade
The fit-pc 2 ships with GMA500 Intel graphics. It kinda sucks since Intel is unable to give us proper drivers for it! This is why I will think twice or even three times before buying anything from Intel again.
To use GMA500 I deceided to use EMGD (source):
sudo add-apt-repository ppa:gma500/emgd
sudo apt-get update
sudo apt-get install xorg-emgd emgd-dkms
sudo emgd-xorg-conf
emgd-xorg-conf creates a config in /usr/share/X11/xorg.conf.d/10-emgd.conf. This is when the problems occour. emgd-xorg-conf discovers wrong port which I had to manually edit. My modified 10-emgd.conf:
Section “ServerLayout”
Identifier “Default Layout”
Screen 0 “Screen0″ 0 0
EndSection
Section “Device”
Identifier “Intel_IEGD-0″
Driver “emgd”
VendorName “Intel(R) DEG”
BoardName “Embedded Graphics”
BusID “0:2:0″
Screen 0
Option “PcfVersion” “1792″
Option “ConfigId” “1″
Option “ALL/1/name” “svdo-display”
Option “ALL/1/General/PortOrder” “24000″
Option “ALL/1/General/DisplayConfig” “1″
Option “ALL/1/General/DisplayDetect” “1″
Option “ALL/1/General/Accel” “1″
Option “PortDrivers” “svdo”
Option “ALL/1/General/VideoRam” “131072″
Option “ALL/1/Port/2/General/name” “sdvo”
Option “ALL/1/Port/2/General/Edid” “1″
Option “ALL/1/Port/2/Attr/70″ “0″
EndSection
Section “Screen”
Identifier “Screen0″
Device “Intel_IEGD-0″
Monitor “sdvo”
SubSection “Display”
Depth 24
Modes “1024×768″
EndSubSection
EndSection
Section “Monitor”
Identifier “sdvo”
ModelName “sdvo panel 1024×768″
EndSection
Section “DRI”
Mode 0666
EndSection
Section “Extensions”
Option “composite” “enable”
EndSection
Keyword here is ALL/1/Port/2 were port 2 was 4 in the orginal configuration and sdvo was lvds.
I then installed lirc to be able to use my transcend remote for my picture frame, you can use anything. I followed some tutorial for making it work. Basically run irrecord to trian lirc to understand my remote.
sudo irrecord -d /dev/lirc0 /etc/lirc/transcend.conf
I tried Boxee first, but it’s bloated. Ended up using XBMC:
sudo add-apt-repository ppa:team-xbmc sudo apt-get update sudo apt-get install xbmc sudo apt-get update sudo apt-get upgrade
Edit #1
If you want XBMC to automatically detect new movies just open crontab
crontab -e
and add the line
* 10 * * * wget -T 60 -q -O /dev/null "http://user:passwd@localhost:8080/xbmcCmds/xbmcHttp?command=ExecBuiltIn(updatelibrary(video))" # run once a day
You will of course have to enable HTTP controlling in XBMC for this to work. Also make sure your user, password and port is correct from the line above.
End of edit
To make lirc work with XBMC we will have to setup a config in XBMC. It should be located in /home/user/.xbmc/userdata/Lircmap.xml. Here is mine:
<lircmap> <remote device="/etc/lirc/transcend.conf"> <play>KEY_PLAYPAUSE</play> <pause>KEY_PLAYPAUSE</pause> <stop>KEY_STOP</stop> <forward>KEY_NEXT</forward> <reverse>KEY_PREV</reverse> <left>KEY_LEFT</left> <right>KEY_RIGHT</right> <up>KEY_UP</up> <down>KEY_DOWN</down> <select>KEY_OK</select> <pageplus>KEY_PAGEUP</pageplus> <pageminus>KEY_PAGEDOWN</pageminus> <back>KEY_EXIT</back> <menu>KEY_MODE</menu> <title>Guide</title> <info>KEY_CYCLEWINDOWS</info> <skipplus>Skip</skipplus> <skipminus>Replay</skipminus> <display>Aspect</display> <start>KEY_HOME</start> <record>Record</record> <volumeplus>KEY_VOLUMEUP</volumeplus> <volumeminus>KEY_VOLUMEDOWN</volumeminus> <mute>KEY_MUTE</mute> <power>KEY_POWER</power> <myvideo>KEY_VIDEO</myvideo> <mymusic>KEY_MUSIC</mymusic> <mypictures>KEY_PROG1</mypictures> <mytv>KEY_CALENDAR</mytv> <one>One</one> <two>Two</two> <three>Three</three> <four>Four</four> <five>Five</five> <six>Six</six> <seven>Seven</seven> <eight>Eight</eight> <nine>Nine</nine> <zero>Zero</zero> <star>Star</star> <hash>Hash</hash> <clear>Clear</clear> <enter>Enter</enter> <red>Red</red> <green>Green</green> <yellow>Yellow</yellow> <blue>Blue</blue> <teletext>Teletext</teletext> </remote> </lircmap>
Give me a comment if anything is unclear.




