Skip to content

Commit e4e9be0

Browse files
lucarin91cmaglie
andauthored
feat: add micro serial forward
Co-authored-by: Cristian Maglie <c.maglie@arduino.cc>
1 parent ff65672 commit e4e9be0

File tree

4 files changed

+32
-1
lines changed

4 files changed

+32
-1
lines changed

debian/arduino-router/DEBIAN/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ Version: $VERSION
33
Architecture: $ARCH
44
Maintainer: arduino <support@arduino.cc>
55
Description: Arduino application router
6-
Depends:
6+
Depends: socat
77

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
11
#!/bin/sh
22

3+
if [ -d /run/systemd/system ]; then
4+
systemctl daemon-reload
5+
fi
6+
37
systemctl enable arduino-router
8+
systemctl enable arduino-router-serial
9+
10+
if [ -d /run/systemd/system ]; then
11+
systemctl start arduino-router
12+
systemctl start arduino-router-serial
13+
fi

debian/arduino-router/DEBIAN/prerm

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
11
#!/bin/sh
22

33
systemctl disable arduino-router
4+
systemctl disable arduino-router-serial
5+
6+
if [ -d /run/systemd/system ]; then
7+
systemctl stop arduino-router
8+
systemctl stop arduino-router-serial
9+
fi
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[Unit]
2+
Description=Proxy for the Arduino Router Monitor to ttyGS0 serial
3+
After=network-online.target arduino-router.service
4+
Wants=network-online.target arduino-router.service
5+
Requires=arduino-router.service
6+
7+
[Service]
8+
ExecStart=/usr/bin/socat file:/dev/ttyGS0,raw,echo=0,b9600,crtscts=0 tcp:127.0.0.1:7500
9+
StandardOutput=journal
10+
StandardError=journal
11+
Restart=always
12+
RestartSec=3
13+
14+
[Install]
15+
WantedBy=multi-user.target

0 commit comments

Comments
 (0)