--- elwix/config/etc/default/rc.cfg 2014/09/15 19:06:44 1.2 +++ elwix/config/etc/default/rc.cfg 2014/09/23 14:18:19 1.2.2.3 @@ -2,13 +2,13 @@ # # U-boot cfg nand map load/save management script # -# $Id: rc.cfg,v 1.2 2014/09/15 19:06:44 misho Exp $ +# $Id: rc.cfg,v 1.2.2.3 2014/09/23 14:18:19 misho Exp $ CFG_NAND_LIST="/etc/cfg.map" CFG_NAND_MAP="/dev/ada0g" CFG_NAND_SIZE=262144 -UPGRADE_GPIO_PINS="" +UPGRADE_GPIO_PINS="1 2 3" cd ${2:-/etc} @@ -50,7 +50,7 @@ case "$1" in echo "ELWIX restore process complete. Now rebooting system ..." ;; backup) - ELWIX_REMOTE_HOST="/tmp/elwix_cfg.bin" + ELWIX_REMOTE_HOST="/tmp/elwix_cfg_$(hostname).bin" echo "ELWIX starting backup process to ${ELWIX_REMOTE_HOST}" imgupd -gs ${CFG_NAND_SIZE} -f ${CFG_NAND_MAP} ${ELWIX_REMOTE_HOST} || exit 1 @@ -61,7 +61,7 @@ case "$1" in echo " You can upload now elwix_firmware.bin image to device with \"firmware\" name!!!" echo " Example: put elwix_firmware.bin firmware" for i in ${UPGRADE_GPIO_PINS}; do - gpioctl $i 1 >/dev/null 2>&1 + gpioctl $i 1 >/dev/null 2>&1 || pceng "$i=0" >/dev/null 2>&1 done TFTPd -wR ;;