cmvr-es/scripts/start_can.sh
lgv 08d9a393be chore(build): unify scripts and add build/install entrypoint
Add a Debug-default build script with Release and RelWithDebInfo support and automatic output installation. Run bundled protobuf tools without requiring a prior install.

Consolidate scripts/, remove unused tools and meshes, and update documentation and test commands. Include the TCHL profile-position test target adjustment to 3 rad.
2026-10-27 11:32:41 +08:00

19 lines
414 B
Bash
Executable File

#!/bin/bash
# CAN interfaces list
CAN_INTERFACES=("can0" "can1" "can2" "can3")
BITRATE=1000000
for CAN_IF in "${CAN_INTERFACES[@]}"; do
# Bring interface down first (in case it's already up)
sudo ip link set $CAN_IF down
# Set bitrate
sudo ip link set $CAN_IF type can bitrate $BITRATE
# Bring interface up
sudo ip link set $CAN_IF up
echo "$CAN_IF started, bitrate $BITRATE"
done