-
Notifications
You must be signed in to change notification settings - Fork 128
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #139 from hifiberry/development
20200908 release
- Loading branch information
Showing
38 changed files
with
723 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
config BR2_PACKAGE_COPY_OVERLAYS | ||
bool "copy overlays" | ||
help | ||
"copy device tree binaries to overlays directory" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
################################################################################ | ||
# | ||
# copy-overlays | ||
# | ||
################################################################################ | ||
|
||
|
||
COPY_OVERLAYS_DEPENDENCIES = rpi-firmware linux | ||
|
||
define COPY_OVERLAYS_INSTALL_TARGET_CMDS | ||
echo "Copying overlays" | ||
mkdir -p $(TARGET_DIR)/usr/lib/firmware/rpi/overlays | ||
for i in hifiberry vc4 i2c-gpio; do \ | ||
cp -v $(BUILD_DIR)/linux-custom/arch/arm/boot/dts/overlays/$$i*.dtbo $(BINARIES_DIR)/rpi-firmware/overlays; \ | ||
cp -v $(BUILD_DIR)/linux-custom/arch/arm/boot/dts/overlays/$$i*.dtbo $(TARGET_DIR)/usr/lib/firmware/rpi/overlays; \ | ||
done | ||
for i in $(BUILD_DIR)/linux-custom/arch/arm/boot/dts/bcm*rpi*.dtb; do \ | ||
cp -v $$i $(BINARIES_DIR); \ | ||
done | ||
endef | ||
|
||
$(eval $(generic-package)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#! /bin/sh | ||
|
||
# Write profile to DAC2HD and play a test tone | ||
|
||
OUT=/dev/tty1 | ||
|
||
# Cleanup some stuff | ||
rm /etc/init.d/S49ntp 2>/dev/null | ||
rm /etc/init.d/S90sigmatcp 2>/dev/null | ||
# rm /etc/init.d/S40network 2>/dev/null | ||
# rm /etc/init.d/S50sshd 2>/dev/null | ||
|
||
case "$1" in | ||
start) | ||
i2c=`cat /boot/config.txt | grep i2c-gpio` | ||
if [ "$i2c" == "" ]; then | ||
echo "dtoverlay=i2c-gpio" >> /boot/config.txt | ||
echo "dtparam=i2c_gpio_sda=0" >> /boot/config.txt | ||
echo "dtparam=i2c_gpio_scl=1" >> /boot/config.txt | ||
fi | ||
|
||
# Program EEPROM | ||
PATH=$PATH:/opt/hifiberry/contrib | ||
export PATH | ||
/opt/hifiberry/contrib/hbflash.sh --writeread -f=/opt/hifiberry/contrib/dac2pro.eep -t=24c32 | ||
if [ "$?" != "0" ]; then | ||
echo | ||
echo | ||
echo | ||
echo "EEPROM write FAIL, data not correct" | ||
echo "aborting..." | ||
echo | ||
echo | ||
echo | ||
else | ||
amixer sset PCM 100% | ||
i2cset -y 1 0x60 0x01 0xc0 | ||
i2cset -y 1 0x60 0x02 0x31 | ||
play -n synth 60 sine 1000 & | ||
|
||
fi | ||
|
||
;; | ||
stop) | ||
;; | ||
restart) | ||
$0 stop | ||
$0 start | ||
;; | ||
*) | ||
echo "Usage: $0 {start|stop|restart}" | ||
exit 1 | ||
;; | ||
esac | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
######################################################################## | ||
# EEPROM settings text file | ||
# | ||
# Edit this file for your particular board and run through eepmake tool, | ||
# then use eepflash tool to write to attached HAT ID EEPROM | ||
# | ||
# Tools available: | ||
# eepmake Parses EEPROM text file and creates binary .eep file | ||
# eepdump Dumps a binary .eep file as human readable text (for debug) | ||
# eepflash Write or read .eep binary image to/from HAT EEPROM | ||
# | ||
######################################################################## | ||
|
||
######################################################################## | ||
# Vendor info | ||
|
||
# 128 bit UUID. If left at zero eepmake tool will auto-generate | ||
# RFC 4122 compliant UUID | ||
product_uuid 00000000-0000-0000-0000-000000000000 | ||
|
||
# 16 bit product id | ||
product_id 0x0000 | ||
|
||
# 16 bit product version | ||
product_ver 0x0000 | ||
|
||
# ASCII vendor string (max 255 characters) | ||
vendor "HiFiBerry" | ||
|
||
# ASCII product string (max 255 characters) | ||
product "DAC+" | ||
|
||
|
||
######################################################################## | ||
# GPIO bank settings, set to nonzero to change from the default. | ||
# NOTE these setting can only be set per BANK, uncommenting any of | ||
# these will force the bank to use the custom setting. | ||
|
||
# drive strength, 0=default, 1-8=2,4,6,8,10,12,14,16mA, 9-15=reserved | ||
gpio_drive 0 | ||
|
||
# 0=default, 1=slew rate limiting, 2=no slew limiting, 3=reserved | ||
gpio_slew 0 | ||
|
||
# 0=default, 1=hysteresis disabled, 2=hysteresis enabled, 3=reserved | ||
gpio_hysteresis 0 | ||
|
||
# If board back-powers Pi via 5V GPIO header pins: | ||
# 0 = board does not back-power | ||
# 1 = board back-powers and can supply the Pi with a minimum of 1.3A | ||
# 2 = board back-powers and can supply the Pi with a minimum of 2A | ||
# 3 = reserved | ||
# If back_power=2 then USB high current mode will be automatically | ||
# enabled on the Pi | ||
back_power 0 | ||
|
||
######################################################################## | ||
# GPIO pins, uncomment for GPIOs used on board | ||
# Options for FUNCTION: INPUT, OUTPUT, ALT0-ALT5 | ||
# Options for PULL: DEFAULT, UP, DOWN, NONE | ||
# NB GPIO0 and GPIO1 are reserved for ID EEPROM so cannot be set | ||
|
||
# GPIO FUNCTION PULL | ||
# ---- -------- ---- | ||
setgpio 2 ALT0 UP | ||
setgpio 3 ALT0 UP | ||
#setgpio 4 INPUT DEFAULT | ||
#setgpio 5 OUTPUT DEFAULT | ||
#setgpio 6 OUTPUT DEFAULT | ||
#setgpio 7 INPUT DEFAULT | ||
#setgpio 8 INPUT DEFAULT | ||
#setgpio 9 INPUT DEFAULT | ||
#setgpio 10 INPUT DEFAULT | ||
#setgpio 11 INPUT DEFAULT | ||
#setgpio 12 INPUT DEFAULT | ||
#setgpio 13 INPUT DEFAULT | ||
#setgpio 14 INPUT DEFAULT | ||
#setgpio 15 INPUT DEFAULT | ||
#setgpio 16 INPUT DEFAULT | ||
#setgpio 17 INPUT DEFAULT | ||
setgpio 18 ALT0 DEFAULT | ||
setgpio 19 ALT0 DEFAULT | ||
setgpio 20 ALT0 DEFAULT | ||
setgpio 21 ALT0 DEFAULT | ||
#setgpio 22 INPUT DEFAULT | ||
#setgpio 23 INPUT DEFAULT | ||
#setgpio 24 INPUT DEFAULT | ||
#setgpio 25 INPUT DEFAULT | ||
#setgpio 26 INPUT DEFAULT | ||
#setgpio 27 INPUT DEFAULT | ||
|
Binary file not shown.
Oops, something went wrong.