add serial TERMINATOR!
parent
5151beb9a7
commit
f1b8d5c8fe
@ -0,0 +1,54 @@
|
||||
;;; serial-terminator.el --- Allows for the creation of one or more serial terminals, each existing in their own buffer + window combo. -*- lexical-binding: t; -*-
|
||||
|
||||
;; Copyright (C) 2023 Penguin
|
||||
|
||||
;; Author: Penguin <penguin@epenguin.net>
|
||||
;; Keywords: terminals
|
||||
|
||||
;; This program is free software; you can redistribute it and/or modify
|
||||
;; it under the terms of the GNU General Public License as published by
|
||||
;; the Free Software Foundation, either version 3 of the License, or
|
||||
;; (at your option) any later version.
|
||||
|
||||
;; This program is distributed in the hope that it will be useful,
|
||||
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
;; GNU General Public License for more details.
|
||||
|
||||
;; You should have received a copy of the GNU General Public License
|
||||
;; along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
;;; Commentary:
|
||||
|
||||
;;
|
||||
|
||||
;;; Code:
|
||||
|
||||
|
||||
|
||||
(provide 'serial-terminator)
|
||||
;;; serial-terminator.el ends here
|
||||
|
||||
(require 'evil)
|
||||
(defun quad-serial-term-setup ()
|
||||
"Opens 4 buffers in a 2x2 square, then opens serial ports in each one"
|
||||
(interactive)
|
||||
|
||||
(ansi-term "/bin/zsh" "/dev/ttyUSB0")
|
||||
(evil-window-split)
|
||||
|
||||
(ansi-term "/bin/zsh" "/dev/ttyUSB1")
|
||||
(evil-window-vsplit)
|
||||
|
||||
(ansi-term "/bin/zsh" "/dev/ttyUSB2")
|
||||
(evil-window-down 1)
|
||||
(evil-window-vsplit)
|
||||
|
||||
(ansi-term "/bin/zsh" "/dev/ttyUSB3")
|
||||
|
||||
(comint-send-string "*/dev/ttyUSB0*" "minicom -D /dev/ttyUSB0 -b 115200\n")
|
||||
(comint-send-string "*/dev/ttyUSB1*" "minicom -D /dev/ttyUSB1 -b 115200\n")
|
||||
(comint-send-string "*/dev/ttyUSB2*" "minicom -D /dev/ttyUSB2 -b 115200\n")
|
||||
(comint-send-string "*/dev/ttyUSB3*" "minicom -D /dev/ttyUSB3 -b 115200\n"))
|
||||
(provide 'quad-serial-term)
|
||||
;;; quad-serial-term.el ends here
|
Loading…
Reference in New Issue