Fast and Ugly solution; First commit; Tested and working.

This commit is contained in:
2024-02-08 22:14:00 +01:00
parent 9b624565c4
commit a0e7a15dc8
3 changed files with 112 additions and 0 deletions

14
setbaud.sh Executable file
View File

@@ -0,0 +1,14 @@
#!/bin/bash
sudo ip link set $1 down
ARGS=$(ip link | awk 'BEGIN{ORS=" "};/can.*/{ if(/can.*:/){print $2};if(/alias/){print $2,"\n"} }' | grep $1: | awk '{print $1,$2}' | awk 'BEGIN{FS="_"}{print $1,$2}' | awk '{print $3,$2}')
echo $1 $ARGS $2 $3
sudo libicsneo_setbaud $ARGS $2 $3
sudo ip link set $1 up
echo $ARGS