From 1fa598049d211ffde3dd04a04f9132566e2349d3 Mon Sep 17 00:00:00 2001 From: atef Date: Mon, 4 Sep 2023 10:19:08 +0200 Subject: [PATCH] Add Salimax and battery service file --- csharp/App/SaliMax/resources/Battery.Service | 13 +++++++++++++ csharp/App/SaliMax/resources/Salimax.Service | 13 +++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 csharp/App/SaliMax/resources/Battery.Service create mode 100644 csharp/App/SaliMax/resources/Salimax.Service diff --git a/csharp/App/SaliMax/resources/Battery.Service b/csharp/App/SaliMax/resources/Battery.Service new file mode 100644 index 000000000..8437b8c59 --- /dev/null +++ b/csharp/App/SaliMax/resources/Battery.Service @@ -0,0 +1,13 @@ +[Unit] +Description=Battery48TL_TCP_Bridge + +[Service] +Type=simple +#ExecStart=socat -v -v TCP-LISTEN:6855,nodelay,fork,reuseaddr GOPEN:/dev/ttyUSB0,raw,b115200 +#ExecStart=socat -x -d -d TCP-LISTEN:6855,fork,max-children=1 GOPEN:/dev/ttyUSB0,rawer,b115200,cs8,parenb=1,parodd=1 +ExecStart=socat -x -d -d TCP-LISTEN:6855 GOPEN:/dev/ttyUSB0,rawer,b115200,cs8,parenb=1,parodd=1 +Restart=always +RestartSec=500ms + +[Install] +WantedBy=multi-user.target diff --git a/csharp/App/SaliMax/resources/Salimax.Service b/csharp/App/SaliMax/resources/Salimax.Service new file mode 100644 index 000000000..d823b591f --- /dev/null +++ b/csharp/App/SaliMax/resources/Salimax.Service @@ -0,0 +1,13 @@ +[Unit] +Description=Salimax Controller +Wants=battery.service + +[Service] +WorkingDirectory=/home/ie-entwicklung/salimax +ExecStart=/home/ie-entwicklung/salimax/SaliMax +WatchdogSec=30s +Restart=always +RestartSec=500ms + +[Install] +WantedBy=multi-user.target