Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
raspberry:pi_radio [2016/10/19 01:08] admin |
raspberry:pi_radio [2016/10/25 02:18] admin [Setting up the radio] |
||
---|---|---|---|
Line 1: | Line 1: | ||
===== Pi-Radio ===== | ===== Pi-Radio ===== | ||
+ | Image: 2016-09-23-raspbian-jessie-lite.img | ||
IP Address: 192.168.0.121\\ | IP Address: 192.168.0.121\\ | ||
Line 7: | Line 8: | ||
---- | ---- | ||
==== Upgrade ==== | ==== Upgrade ==== | ||
+ | |||
+ | $ sudo raspi-config | ||
+ | |||
$ sudo apt-get update | $ sudo apt-get update | ||
$ sudo apt-get upgrade | $ sudo apt-get upgrade | ||
| | ||
- | $ sudo apt-get install htop | + | $ sudo apt-get install htop python-pip idle idle3 |
- | + | ||
- | ---- | + | |
- | ==== Read-Only SD Card ==== | + | |
- | Change the SD card to a read-only mode.\\ | + | |
- | [[http:// | + | |
- | [[https:// | + | |
- | + | ||
- | === Fstab === | + | |
- | in: | + | |
- | $ sudo nano / | + | |
- | change: | + | |
- | / | + | |
- | tmpfs / | + | |
- | + | ||
- | === Disable some Programms === | + | |
- | disable rsyslog and dphys-swapfile: | + | |
- | + | ||
- | **Jessie: | + | |
- | $ sudo systemctl disable rsyslog | + | |
- | $ sudo systemctl disable dphys-swapfile | + | |
- | + | ||
- | === Remount === | + | |
- | To remount the partition writabe: | + | |
- | $ sudo mount / -o remount,rw | + | |
---- | ---- | ||
Line 41: | Line 21: | ||
$ sudo mkdir / | $ sudo mkdir / | ||
$ sudo blkid | $ sudo blkid | ||
- | /dev/mmcblk0p3: LABEL=" | + | /dev/sda1: LABEL=" |
$ sudo nano /etc/fstab | $ sudo nano /etc/fstab | ||
edit: | edit: | ||
#USB Stick on /dev/sda1 | #USB Stick on /dev/sda1 | ||
- | UUID=A933-7A00 / | + | UUID=3DE8-04D4 / |
+ | or: | ||
+ | #USB Stick on /dev/sda1 | ||
+ | / | ||
$ sudo mount -a | $ sudo mount -a | ||
Line 74: | Line 57: | ||
netmask 255.255.255.0 | netmask 255.255.255.0 | ||
gateway 192.168.0.1 | gateway 192.168.0.1 | ||
- | dns-nameservers | + | dns-nameservers |
| | ||
Save and quit, ctl+o, Return, ctl+x.\\ | Save and quit, ctl+o, Return, ctl+x.\\ | ||
Line 110: | Line 93: | ||
==== Setting up the radio ==== | ==== Setting up the radio ==== | ||
- | **Pi-FM-TDS**\\ | + | **Pi-FM-RDS**\\ |
[[https:// | [[https:// | ||
$ mkdir / | $ mkdir / | ||
Line 122: | Line 105: | ||
| | ||
$ sudo ./pi_fm_rds -freq 99.9 -audio sound.wav | $ sudo ./pi_fm_rds -freq 99.9 -audio sound.wav | ||
- | | + | or: |
+ | $ sudo / | ||
- | **PiFM**\\ | + | ---- |
- | [[https:// | + | ==== Autostart ==== |
- | [[http:// | + | |
- | $ mkdir /home/pi/radio | + | $ sudo nano /etc/rc.local |
- | | + | insert before "exit 0": |
- | download pifm:\\ | + | printf " " |
- | $ wget http://omattos.com/pifm.tar.gz | + | printf " |
- | or:\\ | + | printf " |
- | $ wget http://dernulleffekt.de/download/pifm.tar.gz | + | printf " |
- | and unpack:\\ | + | printf " |
- | $ tar -xzvf pifm.tar.gz | + | printf " |
- | connect a wire to GPIO 4.\\ | + | printf " |
- | $ sudo ./pifm left_right.wav freq 22050 stereo | + | printf " |
- | + | printf " | |
- | ==== for Pi 2,3 ==== | + | printf " |
+ | printf " | ||
+ | printf " | ||
+ | printf " | ||
+ | printf " " | ||
+ | |||
+ | # | ||
+ | /home/pi/stolenmoments/ | ||
+ | |||
+ | |||
+ | ---- | ||
+ | ==== Read-Only SD Card ==== | ||
+ | Change the SD card to a read-only mode.\\ | ||
+ | [[http://raspberrypi.stackexchange.com/questions/ | ||
+ | [[https:// | ||
+ | |||
+ | === Fstab === | ||
+ | in: | ||
+ | $ sudo nano / | ||
+ | change: | ||
+ | | ||
+ | tmpfs /tmp tmpfs | ||
+ | |||
+ | === Disable some Programms === | ||
+ | disable rsyslog | ||
+ | |||
+ | $ sudo systemctl disable rsyslog | ||
+ | $ sudo systemctl disable dphys-swapfile | ||
+ | |||
+ | === Remount === | ||
+ | To remount the partition writabe:\\ | ||
+ | $ sudo mount / -o remount, | ||
+ | |||
+ | ---- | ||
+ | ====GPIO Connections==== | ||
+ | GPIO 04 | ||
+ | GPIO 17 | ||
+ | GPIO 18 | ||
+ | GPIO 22 LED DE | ||
+ | GPIO 23 LED EN | ||
+ | GPIO 27 | ||
+ | |||
+ | [[http:// | ||
+ | < | ||
+ | <img src=http:// | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | ==== Other Radios ==== | ||
+ | === for Pi 2,3 === | ||
make a folder: | make a folder: | ||
Line 162: | Line 194: | ||
---- | ---- | ||
- | ====GPIO Connections==== | ||
- | GPIO 04 | ||
- | GPIO 17 | ||
- | GPIO 18 | ||
- | GPIO 22 LED EN | ||
- | GPIO 23 LED DE | ||
- | GPIO 27 | ||
- | |||
- | [[http:// | ||
- | < | ||
- | <img src=http:// | ||
- | </ | ||
- | |||
- | ---- | ||
- |