[mythtv-users] Beta of MiniMyth2 RPI2 edition

Piotr Oniszczuk piotr.oniszczuk at gmail.com
Wed Jan 27 20:27:42 UTC 2016


Hi *

Last year Santa Claus decided to gift me RPI2 :-)
I started to play with it and later I decided: let my RPI2 learning be
useful for others.
So I decided to prepare small, dedicated to MythTV frontend distro
converting RPI2 into ready to run MythTV frontend.
Goal is to get running MythTV on RPI2 in easiest possible way.

Currently procedure is like this:

1.Partition SD card
2.Download & unpack file to SD card
3.Insert SD card into RPI2
4.Power-on RPI2
5.Select discovered MythTV backend.
6.You should get fully running MythTV on PRI2

Now I have initial ver. with current MythTV master.
This is beta & prof-of-concept - so expect changes and issues....

If anybody wants to try, procedure is following:


0.You have to have working in Your LAN:
-MythTV backend with current MythTV master
-properly working DHCP server


1.Partition SD card:

(a) Start fdisk to partition the SD card:
   "fdisk /dev/sdX"

(b) At the fdisk prompt, delete old partitions and create a new one:
   Type o. This will clear out any partitions on the drive.
   Type p to list partitions. There should be no partitions left.
   Type n, then p for primary, 1 for the first partition on the drive,
press ENTER to accept the default first sector, then type +100M for the
last sector.
   Type t, then c to set the first partition to type W95 FAT32 (LBA).
   Type n, then p for primary, 2 for the second partition on the
drive, and then press ENTER twice to accept the default first and last
sector.
   Write the partition table and exit by typing w.

(c) Create and mount the FAT filesystem:
   "mkfs.vfat /dev/sdX1"
   "mkdir boot"
   "mount /dev/sdX1 boot"

(d) Create and mount the ext4 filesystem:
   "mkfs.ext4 /dev/sdX2"
   "mkdir root"
   "mount /dev/sdX2 root"


2. Install MiniMyth2 RPI edition software on SD card:
(replace "xx" in URL!)
(a) Download software (as root, not via sudo)
   "wgethxxp://warped.homenet.org/MiniMyth2-rpi2-latest.tar.bz2"
   "bsdtar -xpf MiniMyth2-rpi2-latest.tar.bz2 -C root"
   "sync"
(b) Move boot files to the first partition:
   "mv root/boot/* boot"
(c) Unmount the two partitions:
   "umount boot root"


3. Insert SD card to RPI2, power-on


4. You should see country/language selection screen. Select appropriate.


5. Next You should see BE selection. Select BE and use "Save".


6. Normally you should see reloading frontend and next famous MythTV
main menu, but due MythTV ARM bug, mythfrontend initial reload gives
black screen. Solution to this is simply kill mythfrontend process.
Build-in watchdog will auto restart and You should finally get all working.
So do following:
   (a) fire terminal somewhere in LAN
   (b) type "ssh -l root <RPI2 IP address>"
   user: root
   pass root
   (c) type "killall mythfrontend"
Frontend should restart automatically


7. Go to MythTV setup and select in playback profile openmax etc. Do the
same also for audio. Set rest things accordingly to Your's preference.


8. Ask MiniMyth2 to update to most current version:

(a) fire terminal somewhere in LAN
(b) type "ssh -l root <RPI2 IP address>"
user: root
pass root
(c) type "pacman -Sy"
(d) type "pacman -Su"
press 'y'
(e) reboot RPI2 to get running new software


9. Setup all boring things like TZ, etc.
(a) ssh as root/root
(b) Check the current zone defined in the system:
   "timedatectl"
(c) To list available zones:
   "timedatectl list-timezones"
(d) To change your time zone:
   "timedatectl set-timezone Zone/SubZone"






If You have problems:
(a) Log via ssh as root/root
(b) type "cat /home/mythtv/mythfrontend.log"
(c) type "journalctl -b"

See what problem might be....




IR remote support:

This distro has pre-installed LIRC support for Microsoft MCE remote.
(https://www.mythtv.org/wiki/MCE_Remote)
So - if You have such remote - just plug-in it's USB IR receiver and all should work.

If You have other remote - then just follow this procedure:

(a) Identify is there remote/receiver a known config for it:
Use "irdb-get" command to search the remotes database.

Example for a Streamzap remote:
"irdb-get find stream"

will return:
atiusb/atiusb.lircd.conf
digital_stream/DTX9900.lircd.conf
snapstream/Firefly-Mini.lircd.conf
streamzap/PC_Remote.lircd.conf
streamzap/streamzap.lircd.conf
x10/atiusb.lircd.conf

(b) Download appropriate config
"irdb-get download streamzap/streamzap.lircd.conf"
Downloaded sourceforge.net/p/lirc-remotes/code/ci/master/tree/remotes/streamzap/streamzap.lircd.conf as streamzap.lircd.conf

(c) Copy the downloaded remote conf file to
/etc/lirc/lircd.conf.d/
to allow LIRC to support it.

(d) Prepare appropriate lircrc file and put it in /home/mythtv/ as .lircrc

(e) Reboot RPI2 and see is it working.
If not, You can use "irw" to see is remote recognized, and if it is - what
KEY codes it emits to lirc daemon. They should correspond with definitions is .lircrc file



Your feedback is always welcome!


BTW: MiniMyth2-rpi2-latest.tar.bz2 resides on my home server (with 120/12 Inet access) - so expect slow downloads.
If anybody knows free hosting space for HTTP downloads - pls advice!


More information about the mythtv-users mailing list