From 34191e046288f0b391002e25f7a49659610c19cb Mon Sep 17 00:00:00 2001 From: tck Date: Fri, 29 May 2026 14:42:16 +0800 Subject: [PATCH] add all --- flip_display.sh | 20 ++++++++++++++------ rtu-dev.service | 4 ++-- start.sh | 1 + systemd-rtu-dev.service | 1 + 4 files changed, 18 insertions(+), 8 deletions(-) create mode 120000 systemd-rtu-dev.service diff --git a/flip_display.sh b/flip_display.sh index cc4d20e01..a62dc27dd 100755 --- a/flip_display.sh +++ b/flip_display.sh @@ -3,11 +3,19 @@ # Flip screen # C-Fu for TCK -# Flip the display -DISPLAY=:0 xrandr --output HDMI-1 --reflect x - -# Flip the touch input (using ID 7 for your specific device) -DISPLAY=:0 xinput set-prop 7 'Coordinate Transformation Matrix' -1 0 1 0 1 0 0 0 1 - # Change reso DISPLAY=:0 xrandr --output HDMI-1 --mode 1024x600 + +# Flip the display +#DISPLAY=:0 xrandr --output HDMI-1 --reflect x +DISPLAY=:0 xrandr --output HDMI-1 --reflect y + +# Flip the touch input (using ID 7 for your specific device) +# Invert 180 +#DISPLAY=:0 xinput set-prop 7 'Coordinate Transformation Matrix' -1 0 1 0 -1 1 0 0 1 + +# Normal +DISPLAY=:0 xinput set-prop 7 'Coordinate Transformation Matrix' 1 0 0 0 1 0 0 0 1 + +# Change reso +#DISPLAY=:0 xrandr --output HDMI-1 --mode 1024x600 diff --git a/rtu-dev.service b/rtu-dev.service index 46a8adb53..37cba73b7 100644 --- a/rtu-dev.service +++ b/rtu-dev.service @@ -1,10 +1,10 @@ [Unit] -Description=TCK RTU Dev 8888 +Description=TCK RTU Dev 8888 for 7inch and 9999 for remote hd screen After=network.target #Before=nextcloud-web.service [Service] -ExecStart=/root/rtu_v5/start.sh dev:8888 +ExecStart=/root/rtu_v5/start.sh #ExecReload=/root/rtu_v4/start.sh dev:8888 Type=simple Restart=always diff --git a/start.sh b/start.sh index caccea022..7cab80787 100755 --- a/start.sh +++ b/start.sh @@ -12,6 +12,7 @@ # Flip the touch input (using ID 7 for your specific device) #DISPLAY=:0 xinput set-prop 7 'Coordinate Transformation Matrix' -1 0 1 0 1 0 0 0 1 +bash flip_display.sh set -e diff --git a/systemd-rtu-dev.service b/systemd-rtu-dev.service new file mode 120000 index 000000000..726ddb359 --- /dev/null +++ b/systemd-rtu-dev.service @@ -0,0 +1 @@ +/etc/systemd/system/rtu-dev.service \ No newline at end of file