aboutsummaryrefslogtreecommitdiffstats
path: root/can_samples/init_vcan.sh
diff options
context:
space:
mode:
Diffstat (limited to 'can_samples/init_vcan.sh')
-rwxr-xr-xcan_samples/init_vcan.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/can_samples/init_vcan.sh b/can_samples/init_vcan.sh
new file mode 100755
index 0000000..d016289
--- /dev/null
+++ b/can_samples/init_vcan.sh
@@ -0,0 +1,6 @@
+#!/bin/sh
+# example for setting up vcan0 and modules
+sudo modprobe can
+sudo modprobe vcan
+sudo ip link add dev $1 type vcan
+sudo ip link set up $1