From bc9c5ec0bc97e86e3b3bf3b476552eed2ddab59b Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Fri, 6 Jul 2018 13:30:26 -0400 Subject: [PATCH] Adjustments for new setup --- config.json | 4 ++-- libremanage | 2 ++ serial/stripped-serial.sh | 6 +++--- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/config.json b/config.json index bed78a7..61f0580 100644 --- a/config.json +++ b/config.json @@ -3,7 +3,7 @@ "web2": { "manager": "myboard", "tty": { - "file": "/dev/ttyO0", + "file": "/dev/ttyUSB0", "baud": 115200 }, "power": { @@ -14,7 +14,7 @@ }, "managers": { "myboard": { - "host": "192.168.7.2", + "host": "192.168.0.250", "port": 22, "username": "root" } diff --git a/libremanage b/libremanage index 4f4312f..cba0dab 100755 --- a/libremanage +++ b/libremanage @@ -122,6 +122,8 @@ COMMANDS = { # TTY access (or keyboard if wired as such) "tty": lambda s: open_ssh(s, "screen " + s["tty"]["file"] + " " + str(s["tty"]["baud"]), force_tty=True), + "tty-baud": lambda s: open_ssh(s, "stty -F "+ s["tty"]["file"] + " " + str(s["tty"]["baud"])), + "tty-read": lambda s: open_ssh(s, "cat " + s["tty"]["file"], force_tty=True), # SSH sanity tests diff --git a/serial/stripped-serial.sh b/serial/stripped-serial.sh index 2ac0150..6ee8b5b 100755 --- a/serial/stripped-serial.sh +++ b/serial/stripped-serial.sh @@ -1,5 +1,5 @@ #!/bin/sh -stty -F $1 115200 -tmux new-session -d "cat $1 | ./uncolor" -tmux split-window -h "stdbuf -o0 cat > $1" +libremanage $1 tty-baud +tmux new-session -d "libremanage $1 tty-read | ./uncolor" +tmux split-window -h "libremanage $1 tty-write" tmux at -- 2.25.1