useful_linux_scripts/reset_can.sh

14 lines
265 B
Bash
Executable File

#!/bin/bash
sudo ip link set can0 down
sudo ip link set can0 type can bitrate 100000 sjw 128
sudo ip link set can0 up
/usr/bin/candump -l -t A can0 &
# Find and delete .log files older than one month
#
find . -type f -name "*.log" -mtime +30 -exec rm -f {} \;