HiFiBerry Amp 2
WARNING: DO NOT use the Raspberry Pi's 5V power supply connected to the Micro-USB port of the Raspberry Pi.
Use a 12V barrel power supply connected to the HiBerry Amp 2. The Raspberry Pi will be powered by the HiBerry Amp. Do not connect power supply to HiBerry AMP 2
Step 1. Mount the HiBerry Amp 2
Shutdown the Raspberry Pi
$ sudo shutdown now
Wait for the lights to stop blinking
Remove the micro USB power supply from the Raspberry Pi
Mount the HiBerry Amp 2 on top of the Raspberry Pi
Step 2. Make connections
I am only using a single speaker and a 12V barrel power supply:
Step 3. Configure raspbian to work with HiBerry AMP 2
Edit config.txt
$ sudo nano /boot/config.txt
and comment out the line
# dtparam=audio=on
and at the end of the file add the lines
# HiBerry AMP 2
dtoverlay=hifiberry-dacplus
CTRL-o, ENTER, CTRL-x to save and exit the editor
and then reboot:
$ sudo reboot
Step 4. Check if sound card is installed
This command will check if the sound card is installed
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: sndrpihifiberry [snd_rpi_hifiberry_dacplus], device 0: HiFiBerry DAC+ HiFi pcm512x-hifi-0 []
Subdevices: 1/1
Subdevice #0: subdevice #0
Step 5. Check if it works
HiBerry Amp 2 Pins used:
I2C (GPIO 2, 3) SDA and SCL pins 3 and 5 are used to control the HiBerry Amp 2
GPIO 4 is used to control the MUTE function of the power stage. Pulling it low mutes the output.
GPIOs 18-21 (pins 12, 35, 38 and 40) are used for audio interface
Pin 27 and 28 are always reserved for an ID EEPROM Since over-the-air FM Radio uses I2C, I will need to figure out how to use HiBerry Amp 2 and Si4702 as I2C slave devices.