Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Serial terminal in emacs

I'm working on and embedded system with a serial (RS232) console. (With a Linux desktop) I would like to connect to the serial port in emacs and be able to navigate the output with my normal emacs navigation (search / copy / yank / etc )

I am currently doing this with ansi-term + GNU Screen.

However, I cannot get the GNU Screen navigation to my liking.

Any suggestions??

like image 249
James Wooderson Avatar asked Dec 02 '11 19:12

James Wooderson


People also ask

How do I run a terminal in Emacs?

If you are working with a graphical user interface, start Emacs by clicking its icon or by running emacs & at the command line. The & tells the command line to open Emacs in the background and immediately return control of the terminal to you.

How do I use Emacs shells?

7.7 How do I use a shell in Emacs? You can start an interactive shell in Emacs by typing M-x shell . By default, this will start the standard Windows shell cmd.exe . Emacs uses the SHELL environment variable to determine which program to use as the shell.


2 Answers

I'm not sure how GNU screen fits into the equation but have a look at serial-term.

Use C-cC-k to go to char mode and C-cC-j to go to line mode (where your normal bindings apply).

Killing the buffer closes the port (C-ck in char mode, C-xk in line mode).

like image 113
Ben Avatar answered Oct 23 '22 09:10

Ben


This page covers using screen with ansi-term under emacs: GnuScreen

like image 43
Josh Avatar answered Oct 23 '22 09:10

Josh