03_gpio_switches 563 B

123456789101112131415161718192021222324
  1. #!/bin/sh
  2. . /lib/functions/uci-defaults.sh
  3. board_config_update
  4. board=$(board_name)
  5. case "$board" in
  6. ubnt-erx)
  7. ucidef_add_gpio_switch "poe_passthrough" "PoE Passthrough" "0"
  8. ;;
  9. ubnt-erx-sfp)
  10. ucidef_add_gpio_switch "poe_power_port0" "PoE Power Port0" "496"
  11. ucidef_add_gpio_switch "poe_power_port1" "PoE Power Port1" "497"
  12. ucidef_add_gpio_switch "poe_power_port2" "PoE Power Port2" "498"
  13. ucidef_add_gpio_switch "poe_power_port3" "PoE Power Port3" "499"
  14. ucidef_add_gpio_switch "poe_power_port4" "PoE Power Port4" "500"
  15. ;;
  16. esac
  17. board_config_flush
  18. exit 0