X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=recipes-core%2Fudev%2Fusb-can-udev-conf%2Fslcand%40.service;fp=recipes-core%2Fudev%2Fusb-can-udev-conf%2Fslcand%40.service;h=3c30e51b0fc8e2cd17149773fe58db84a9d9a89f;hb=41591d4f8c586aa801220fac0924556f406c58bd;hp=0000000000000000000000000000000000000000;hpb=4830bcef14e7f49cdc851c646a69c9bb9bd92e82;p=AGL%2Fmeta-agl-demo.git diff --git a/recipes-core/udev/usb-can-udev-conf/slcand@.service b/recipes-core/udev/usb-can-udev-conf/slcand@.service new file mode 100644 index 000000000..3c30e51b0 --- /dev/null +++ b/recipes-core/udev/usb-can-udev-conf/slcand@.service @@ -0,0 +1,13 @@ +[Unit] +Description=Serial CAN daemon (can-utils) +BindsTo=dev-%i.device +After=dev-%i.device + +[Service] +Type=forking +StopWhenUnneeded=yes +Environment=SLCAND_OPTS="-o -c -s6" SLCAND_DEV=can0 +EnvironmentFile=-/etc/default/slcand +EnvironmentFile=-/etc/sysconfig/slcand +ExecStart=/usr/bin/slcand $SLCAND_OPTS %I $SLCAND_DEV +ExecStartPost=/bin/sh -c '/bin/sleep 3; /sbin/ip link set $SLCAND_DEV up'