Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for RPI-RF-MOD/HM-MOD-RPI-PCB for HomeMatic/homematicIP communication #1266

Merged
merged 26 commits into from
Apr 7, 2021
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
c85f89e
added eq3_char_loop package (eQ-3 char loopback kernel module)
jens-maus Mar 9, 2021
7c74c7b
added rpi-rf-mod package (device tree overlay support for RPI-RF-MOD/…
jens-maus Mar 9, 2021
dab7923
added rx8130-rtc package (kernel module for RX-8130 RTC of RPI-RF-MOD)
jens-maus Mar 9, 2021
4335837
added generic_raw_uart package (low-latency raw uart kernel driver)
jens-maus Mar 9, 2021
844dc84
added new eq3_char_loop, rpi-rf-mod, rx8130-rtc and generic_raw_uart
jens-maus Mar 9, 2021
791d4df
added GPIOLIB and GPIO_SYSFS required for RPI-RF-MOD/HM-MOD-RPI-PCB
jens-maus Mar 9, 2021
854f4ae
modified raspberrypi defconfig file to enable packages required for
jens-maus Mar 9, 2021
1535c17
added basic RPI-RF-MOD/HM-MOD-RPI-PCB support for Tinkerboard.
jens-maus Mar 9, 2021
e9054fa
added packages for RPI-RF-MOD/HM-MOD-RPI-PCB support to generic_x86_64
jens-maus Mar 9, 2021
bac6349
added basic support for RPI-RF-MOD/HM-MOD-RPI-PCB to odroid defconfig
jens-maus Mar 9, 2021
a019800
Merge branch 'dev' into rpi-rf-mod-support
jens-maus Mar 12, 2021
3f502f7
integrated changes according to
jens-maus Mar 14, 2021
b810197
Merge branch 'dev' into rpi-rf-mod-support
jens-maus Mar 19, 2021
447911f
removed the dedicated rx8130-rtc buildroot package in favor of using the
jens-maus Mar 19, 2021
a5a6360
removed BR2_PACKAGE_HASSIO_MACHINE use in rpi-rf-mod buildroot package
jens-maus Mar 19, 2021
52b3380
typo fix
jens-maus Mar 19, 2021
684cc50
removed the generic_raw_uart package dts patches which were setting the
jens-maus Mar 23, 2021
e94d5dd
Merge branch 'dev' into rpi-rf-mod-support
jens-maus Mar 23, 2021
15110db
Merge branch 'dev' into rpi-rf-mod-support
jens-maus Mar 26, 2021
ecfef27
updated generic_raw_uart to latest master version and updated rpi-rf-mod
jens-maus Mar 26, 2021
b6b887b
added device tree overlay support for ASUS tinkerboard and added
jens-maus Mar 31, 2021
e9b5190
improved comment for enabling RPI-RF-MOD/HM-MOD-RPI-PCB support
jens-maus Mar 31, 2021
7dd3560
explicitly enable CONFIG_OF_LIBFDT_OVERLAY rather than via a patch ag…
jens-maus Apr 2, 2021
4d404cc
modified eq3_char_loop package to use the upstream sources from
jens-maus Apr 2, 2021
d3670fc
modified the rpi-rf-mod package to fetch the dts sources upstream rather
jens-maus Apr 2, 2021
3147640
Rename bootEnv.txt to haos-config.txt
agners Apr 7, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions buildroot-external/Config.in
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@ source "$BR2_EXTERNAL_HASSOS_PATH/package/rpi-eeprom/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/rtl8812au/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/os-agent/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/udisks2/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/eq3_char_loop/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/generic_raw_uart/Config.in"
source "$BR2_EXTERNAL_HASSOS_PATH/package/rpi-rf-mod/Config.in"
4 changes: 4 additions & 0 deletions buildroot-external/board/asus/hassos-hook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ function hassos_pre_image() {
"${BINARIES_DIR}/rk3288-tinker.dtb" \
"${BINARIES_DIR}/rk3288-tinker-s.dtb"

mkdir -p "${BOOT_DATA}/overlays"
cp "${BINARIES_DIR}"/*.dtbo "${BOOT_DATA}/overlays/"
cp "${BOARD_DIR}/boot-env.txt" "${BOOT_DATA}/bootEnv.txt"

echo "console=tty1" > "${BOOT_DATA}/cmdline.txt"

# SPL
Expand Down
2 changes: 2 additions & 0 deletions buildroot-external/board/asus/tinker/boot-env.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Uncomment this to enable GPIO support for RPI-RF-MOD/HM-MOD-RPI-PCB
#overlays=rpi-rf-mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 8a23c76d..bb1e3cb7 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1321,6 +1321,8 @@ config ARCH_ROCKCHIP
select DM_SPI_FLASH
select DM_USB if USB
select ENABLE_ARM_SOC_BOOT0_HOOK
+ select OF_LIBFDT
+ select OF_LIBFDT_OVERLAY
jens-maus marked this conversation as resolved.
Show resolved Hide resolved
select OF_CONTROL
select SPI
select SPL_DM if SPL
27 changes: 25 additions & 2 deletions buildroot-external/board/asus/tinker/uboot-boot.ush
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,37 @@ setenv bootargs_hassos "zram.enabled=1 zram.num_devices=3 apparmor=1 security=ap
setenv bootargs_a "root=PARTUUID=8d3d53e3-6d49-4c38-8349-aff6859e82fd rootfstype=squashfs ro rootwait"
setenv bootargs_b "root=PARTUUID=a3ec664e-32ce-4665-95ea-7ae90ce9aa20 rootfstype=squashfs ro rootwait"

# Load environment from bootEnv.txt
if test -e mmc ${devnum}:1 bootEnv.txt; then
fatload mmc ${devnum}:1 ${ramdisk_addr_r} bootEnv.txt
env import -t ${ramdisk_addr_r} ${filesize}
fi

# Load extraargs
fileenv mmc ${devnum}:1 ${ramdisk_addr_r} cmdline.txt cmdline

# Load device tree
if test "$devnum" = "0"; then
fatload mmc ${devnum}:1 ${fdt_addr_r} rk3288-tinker-s.dtb
setenv fdtfile "rk3288-tinker-s.dtb"
else
fatload mmc ${devnum}:1 ${fdt_addr_r} rk3288-tinker.dtb
setenv fdtfile "rk3288-tinker.dtb"
fi

echo "Loading standard device tree ${fdtfile}"
fatload mmc ${devnum}:1 ${fdt_addr_r} ${fdtfile}
fdt addr ${fdt_addr_r}

# load dt overlays
fdt resize 65536
for overlay_file in ${overlays}; do
if fatload mmc ${devnum}:1 ${ramdisk_addr_r} overlays/${overlay_file}.dtbo; then
echo "Applying kernel provided DT overlay ${overlay_file}.dtbo"
fdt apply ${ramdisk_addr_r} || setenv overlay_error "true"
fi
done
if test "${overlay_error}" = "true"; then
echo "Error applying DT overlays, restoring original DT"
fatload mmc ${devnum}:1 ${fdt_addr_r} ${fdtfile}
fi

setenv bootargs
Expand Down
6 changes: 6 additions & 0 deletions buildroot-external/board/raspberrypi/boot-env.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ kernel=u-boot.bin
# Uncomment this to enable the lirc-rpi module
#dtoverlay=lirc-rpi

# Uncomment this to enable GPIO support for RPI-RF-MOD/HM-MOD-RPI-PCB
#enable_uart=1
#dtparam=i2c_arm=on
#dtoverlay=miniuart-bt
#dtoverlay=rpi-rf-mod

# Additional overlays and parameters are documented /boot/overlays/README

# Enable audio (loads snd_bcm2835)
Expand Down
1 change: 1 addition & 0 deletions buildroot-external/board/raspberrypi/hassos-hook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ function hassos_pre_image() {
cp "${BINARIES_DIR}"/*.dtb "${BOOT_DATA}/"
cp -r "${BINARIES_DIR}/rpi-firmware/"* "${BOOT_DATA}/"
cp "${BOARD_DIR}/../boot-env.txt" "${BOOT_DATA}/config.txt"
cp "${BINARIES_DIR}"/*.dtbo "${BOOT_DATA}/overlays/"

# EEPROM update for Raspberry Pi 4/Compute Module 4
if grep -Eq "^BR2_PACKAGE_RPI_EEPROM=y$" "${BR2_CONFIG}"; then
Expand Down
1 change: 1 addition & 0 deletions buildroot-external/configs/generic_x86_64_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,4 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_INTEL_E1000E=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
1 change: 1 addition & 0 deletions buildroot-external/configs/odroid_c2_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,4 @@ BR2_PACKAGE_HARDKERNEL_BOOT_ODROID_C2=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RTL8812AU=y
BR2_PACKAGE_RPI_RF_MOD=y
1 change: 1 addition & 0 deletions buildroot-external/configs/odroid_c4_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -109,3 +109,4 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_HARDKERNEL_BOOT=y
BR2_PACKAGE_HARDKERNEL_BOOT_ODROID_C4=y
BR2_PACKAGE_RTL8812AU=y
BR2_PACKAGE_RPI_RF_MOD=y
1 change: 1 addition & 0 deletions buildroot-external/configs/odroid_n2_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,4 @@ BR2_PACKAGE_HARDKERNEL_BOOT_ODROID_N2=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RTL8812AU=y
BR2_PACKAGE_RPI_RF_MOD=y
1 change: 1 addition & 0 deletions buildroot-external/configs/odroid_xu4_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,4 @@ BR2_PACKAGE_HARDKERNEL_BOOT_ODROID_XU4=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RTL8812AU=y
BR2_PACKAGE_RPI_RF_MOD=y
1 change: 1 addition & 0 deletions buildroot-external/configs/ova_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -115,3 +115,4 @@ BR2_PACKAGE_APPARMOR_PROFILES=y
BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi0_w_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,5 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_BCM43XX=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi2_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -109,3 +109,5 @@ BR2_PACKAGE_APPARMOR_PROFILES=y
BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi3_64_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,5 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_BCM43XX=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi3_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,5 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_BCM43XX=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi4_64_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,5 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_BCM43XX=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi4_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -109,3 +109,5 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_BCM43XX=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
2 changes: 2 additions & 0 deletions buildroot-external/configs/rpi_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -109,3 +109,5 @@ BR2_PACKAGE_APPARMOR_PROFILES=y
BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
4 changes: 4 additions & 0 deletions buildroot-external/configs/tinker_defconfig
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(BR2_EXTERNAL_HASSOS_PATH)/kernel/hasso
BR2_LINUX_KERNEL_LZ4=y
BR2_LINUX_KERNEL_DTS_SUPPORT=y
BR2_LINUX_KERNEL_INTREE_DTS_NAME="rk3288-tinker rk3288-tinker-s"
BR2_LINUX_KERNEL_DTB_OVERLAY_SUPPORT=y
BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y
BR2_LINUX_KERNEL_NEEDS_HOST_LIBELF=y
BR2_PACKAGE_BUSYBOX_CONFIG="$(BR2_EXTERNAL_HASSOS_PATH)/busybox.config"
Expand Down Expand Up @@ -113,3 +114,6 @@ BR2_PACKAGE_LIBCURL_CURL=y
BR2_PACKAGE_BLUETOOTH_RTL8723=y
BR2_PACKAGE_DOSFSTOOLS=y
BR2_PACKAGE_DOSFSTOOLS_FSCK_FAT=y
BR2_PACKAGE_RPI_RF_MOD=y
BR2_PACKAGE_RPI_RF_MOD_DTS=y
BR2_PACKAGE_RPI_RF_MOD_DTS_TINKER=y
4 changes: 4 additions & 0 deletions buildroot-external/kernel/device-support.config
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,10 @@ CONFIG_SND_HDA_CODEC_ANALOG=m
CONFIG_SND_HDA_CODEC_VIA=m
CONFIG_SND_HDA_CODEC_HDMI=m

# GPIO support
CONFIG_GPIOLIB=y
CONFIG_GPIO_SYSFS=y

# Can Bus support
CONFIG_CAN=m
CONFIG_CAN_RAW=m
Expand Down
2 changes: 2 additions & 0 deletions buildroot-external/package/eq3_char_loop/Config.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
config BR2_PACKAGE_EQ3_CHAR_LOOP
bool "Support for eq3 char loop kernel module"
1 change: 1 addition & 0 deletions buildroot-external/package/eq3_char_loop/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
obj-m += eq3_char_loop.o
Loading