Skip to content

Instantly share code, notes, and snippets.

@9bo9bo 9bo9bo/setup.sh
Last active Mar 4, 2018

Embed
What would you like to do?
Setup AirPlay
#!/bin/bash
# パッケージの更新
apt-get -y update
apt-get -y upgrade
# Raspberry Pi の設定
# SSH はここで有効にできる
# raspi-config
# ntp
sudo apt-get -y install ntp
sudo timedatectl set-timezone Asia/Tokyo
# AirPlay 機能のインストール
# https://github.com/mikebrady/shairport-sync/blob/master/README.md
apt-get -y install shairport-sync
# mp3ファイルが再生できるようにします
apt-get -y install mpg321
# 音声の出力先
amixer cset numid=3 2 # HDMI
#amixer cset numid=3 1 # line
#amixer cset numid=3 0 # auto
# 音量
amixer cset numid=1 100%
# 再生されるか確認
wget http://www.parliament.uk/audio/images/bigben-images/hourlychimebeg.mp3 ~
mpg321 -g 50 ~/hourlychimebeg.mp3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.