adds optional script to enable poe passthrough on cpe210

The script is only included in ar71xx builds and only executes on the
cpe210 v1.1 hardware.
It is intended to be called from /etc/rc.local.fff_userconfig since the
state of poe passthrough is reset on each reboot.

Signed-off-by: Tobias Klaus <tk+ff@meskal.net>
Reviewed-by: Christian Dresel <fff@chrisi01.de>
Reviewed-by: Tim Niemeyer <tim@tn-x.org>
This commit is contained in:
Tobias Klaus 2016-05-11 08:40:29 +02:00 committed by Tim Niemeyer
parent 49975b9bd9
commit bb3fc82089
2 changed files with 10 additions and 4 deletions

View File

@ -23,19 +23,20 @@ define Package/fff-support/description
endef
define Build/Prepare
echo "all: " > $(PKG_BUILD_DIR)/Makefile
echo "all: " > $(PKG_BUILD_DIR)/Makefile
endef
define Build/Configure
# nothing
# nothing
endef
define Build/Compile
# nothing
# nothing
endef
define Package/fff-support/install
$(CP) ./files/* $(1)/
$(CP) ./files/* $(1)/
test -d ./$(BOARD) && $(CP) ./$(BOARD)/* $(1)/
endef
$(eval $(call BuildPackage,fff-support))

View File

@ -0,0 +1,5 @@
if [ "$(cat /var/sysinfo/model)" = "TP-Link CPE210 v1.1" ] ; then
echo 20 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio20/direction
echo 1 > /sys/class/gpio/gpio20/value
fi