Kommunikation hat funktioniert

This commit is contained in:
Bernhard
2025-12-06 19:20:49 +01:00
commit 9b3c4b3fd2
13 changed files with 1115 additions and 0 deletions

23
scripts/CanRtDriver.service Executable file
View File

@@ -0,0 +1,23 @@
## Service Definition
## Datei gehört in /etc/systemd/system
## aktivieren dann mit:
## - sudo systemctl daemon-reload
## - sudo systemctl enable CanRtDriver.service
## - sudo systemctl start CanRtDriver.service
[Unit]
Description=CAN-Bus Treiber für Gegenstromanlage
After=network.target
[Service]
ExecStart=/home/veltmann/Documents/CanRtDriver/bin/CanRtDriver
# Oder: ExecStart=/usr/bin/python3 /home/pi/meinprogramm.py
WorkingDirectory=/home/veltmann/Documents/CanRtDriver/bin
StandardOutput=inherit
StandardError=inherit
Restart=always
#User=veltmann
# Optional: Group=meinbenutzergruppe
[Install]
WantedBy=multi-user.target

7
scripts/can_link_up.sh Executable file
View File

@@ -0,0 +1,7 @@
#!/bin/bash
ip link set can0 up type can bitrate 250000
ip link set can1 up type can bitrate 250000
ifconfig can0 txqueuelen 65536
ifconfig can1 txqueuelen 65536

2
scripts/candump.sh Executable file
View File

@@ -0,0 +1,2 @@
candump can1