Thursday, July 2, 2015

Run Pidora on Raspberry Pi Model B+

Inroduction

Pidora is a Fedora Remix optimized for the Raspberry Pi computer. So, it is a good candidate choice for implementation if you are familiar with Fedora.
Here, I present the installation steps of installing Pidora 20 on Raspberry Pi Model B+ board. All the preparing works are done on Fedora 20.


Download image file

http://pidora.ca/pidora/releases/20/images/Pidora-2014-R3.zip


Write image file to SD card

dd (convert and copy a file) is a command-line utility for Unix/Linux, I use dd to write Pidora-2014-R3.img file to SD card.

# unzip Pidora-2014-R3.zip (uncompress to Pidora-2014-R3.img)
# dd if=Pidora-2014-R3.img of=/dev/sdb bs=4M (The SD card is at /dev/sdb)

On Windows, you can write image file by Win32 Disk Image.

After the dd command has done, remove the SD card and plug into socket, again. It would be mounted at 2 path:
/run/media/{user}/BOOT
/run/media/{user}/rootfs



Extra works

The default running job is display X window on TV/Monitor via HDMI interface, and the default network is using dynamic IP address. If you want to run it on console mode with static IP address, there is some extra work that you should do.

# vi /run/media/{user}/BOOT/headless
IPADDR=192.168.1.19         # the static IP address
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
RESIZE         # extend the SD card size to its real size
SWAP=512

# vi /run/media/{user}/rootfs/etc/sysconfig/network-scripts/ifcfg-Wired_connection_1
TYPE=Ethernet
BOOTPROTO=none
IPADDR0=192.168.1.19    # the static IP address
PREFIX0=24
GATEWAY0=192.168.1.1
DNS1=168.95.1.1
DNS2=168.95.192.1
DEFROUTE=yes
IPV4_FAILURE_FATAL=yes
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_PEERDNS=yes
IPV6_PEERROUTES=yes
IPV6_FAILURE_FATAL=no
NAME="Wired connection 1"
UUID=b2df4348-a75e-4e80-ab3f-470154e1fc8c
ONBOOT=yes


Install/Update application packages

Some of my works is done by python with serial communication, therefore, I have to install some packages:


# yum update
# yum install python-setuptools
# yum install python-pip
# easy_install pyerial   <== serial communication package
# yum install python-devel
# yum install libxml2 libxslt
# yum install libxslt-devel
# pip install RPi.GPIO   <== GPIO control package
# pip install cython
# reboot


Conclusion

Except the write image to SD card process and disk partition policy is different from Fedora on PC, other works are same as you work on Fedora environment.


Reference

Pidroa official site
Win32 Disk Image

No comments: