slcan is only for usb adapter from now on.
--- a/etc/slcan.sh Sun Nov 08 19:08:01 2015 +0000
+++ b/etc/slcan.sh Wed Nov 11 05:09:02 2015 +0000
@@ -24,7 +24,7 @@
fi
}
-TRY="try: slcan.sh stop or can0|can1 start|stop|status"
+TRY="try: slcan.sh stop or canX start|stop|status"
if test $# = 1; then
if test ! "$1" = "stop"; then
@@ -47,18 +47,7 @@
fi
CAN=$1
-
-if test "$CAN" = "can0"; then
- kctrl restore
- gpio_setfunc 30 ALT3
- CMD="slcand -t hw -S 1000000 /dev/ttyAMA0 can0"
-elif test "$CAN" = "can1"; then
- CMD="slcand -S 460800 /dev/ttyPL2303 can1"
-else
- echo $TRY
- exit 1
-fi
-
+CMD="slcand -S 460800 /dev/ttyUSB0 ${CAN}"
PID=$(ps auxw | grep "$CMD" | grep -v grep | awk '{print $2}')
OPT=$2