Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I recently purchased a VT220 and all the hardware necessary to hook it to my macbook pro. After several hours of fiddling I got it working with a shell - my only problem is my shell of choice, ZSH, behaves weirdly. Backspace and Arrow keys, as well as Ctrl-a and Ctrl-e do not actually move the cursor and while they do delete it is kind of awkward.

Using BASH on the other hand, the device works flawlessly. Is there an issue with some control character or something that ZSH is using?

share|improve this question
3  
Did you try export TERM=vt220? –  Mischa Arefiev Feb 28 '12 at 9:04
    
I had not - that FIXED IT!!! Thank you very much. Is there a way I can have it do this automatically on this specific console but not my other consoles? I'd throw it in my zshrc but that would do every console... –  donatJ Mar 1 '12 at 0:04
1  
The default value of TERM is normally specified by the getty process accepting the serial connection. If this were Linux, you might run getty like /sbin/getty 115200 ttyS0 vt220. This will set TERM to vt220 when accepting any login over ttyS0. I'm not sure of the MacOS equivalent. –  penguin359 Mar 2 '12 at 22:24
    
Third column in /etc/ttys on OS X. –  Ingmar Hupp Mar 3 '12 at 3:02
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.