See: https://www.raspberrypi.org/documentation/installation/installing-images/linux.md
touch /boot/ssh
See: https://www.raspberrypi.org/documentation/remote-access/ssh/
Default password: https://www.raspberrypi.org/documentation/linux/usage/users.md
Edit /etc/modprobe.d/blacklist-rtl8192cu.conf
and make it
# CUSTOM: rtl8192cu actually seems to work better than the default `8192cu`
#blacklist rtl8192cu
blacklist 8192cu
sudo raspi-config
See: https://www.raspberrypi.org/documentation/configuration/wireless/wireless-cli.md
sudo apt-get update
sudo apt-get upgrade
Edit /etc/inputrc
and uncomments the following settings:
# alternate mappings for "page up" and "page down" to search the history
# "\e[5~": history-search-backward
# "\e[6~": history-search-forward
sudo apt-get install fluidsynth
- Pianissimum -- http://sunsite.univie.ac.at/musicres/thammer/HammerSound/localfiles/soundfonts/pianissimum.zip -- Great sound, but makes clicking noises when pressing multiple keys
- Steinway Grand Piano -- https://github.com/morashon/morashon/blob/master/score/fluidsynth/Steinway%20Grand%20Piano%201.2.SF2 -- Decent sound; less clicking noises
Or choose some other: https://www.youtube.com/watch?v=se0Ei4uhnl0
You can use Polyphone to convert or merge soundfont files.
fluidsynth --audio-bufcount=8 --audio-driver=alsa --chorus=0 --reverb=0 -o synth.polyphony=32 -o midi.autoconnect=1 -o synth.midi-bank-select=mma --gain=1 --no-shell --server /usr/share/sounds/sf2/pianissimum.sf2
Explanation of options:
--audio-bufcount=8
- lowers the latency--audio-driver=alsa
- explicitly select Alsa in order to prevent from using any extra interlinks (like Jack) that would eat more CPU--chorus=0 --reverb=0 -o synth.polyphony=32
- makes it less CPU heavy so that the sound does not get distorted even on my Rasperry Pi 1B (single core 700 MHz ARMv6 CPU)-o midi.autoconnect=1
- autoconnect MIDI device (instead of runningaconnect
manually)-o synth.midi-bank-select=mma
- use bank selection mode that Studiologic SL990 Pro keyboard uses--gain=1
- increases the volume--no-shell --server
- something like a daemon mode
Create /home/pi/fluidsynth.config
with the following contents:
# Remove current rules (to remove cc sustain events):
router_clear
# Map modulation wheel to volume
router_begin cc
router_par1 1 1 0 7
router_end
# Enable back sustain pedal
router_begin cc
router_par1 64 64 0 64
router_end
# Enable back bank select (MSB)
router_begin cc
router_par1 0 0 0 0
router_end
# Enable back bank select (LSB)
router_begin cc
router_par1 32 32 0 32
router_end
# Set the rules to pass through other messages types (note, prog, pbend, cpress, kpress)
router_begin note
router_end
router_begin prog
router_end
router_begin pbend
router_end
router_begin cpress
router_end
router_begin kpress
router_end
Create /etc/systemd/system/fluidsynth.service
with the following contents:
[Unit]
Description=Runs FluidSynth server
[Service]
ExecStart=/usr/bin/fluidsynth --audio-bufcount=8 --audio-driver=alsa --chorus=0 --reverb=0 -o synth.polyphony=32 -o midi.autoconnect=1 -o synth.midi-bank-select=mma --gain=1 --no-shell --server --load-config fluidsynth.config /usr/share/sounds/sf2/pianissimum.sf2
WorkingDirectory=/home/pi
StandardOutput=inherit
StandardError=inherit
Restart=always
User=pi
[Install]
WantedBy=multi-user.target
Enable the services:
sudo systemctl enable fluidsynth.service