Serial Console on OSX
April 13, 2008 by Greg Ferro · 12 Comments
I bought a USB Serial port that had MAC drivers. Check before you buy it that it has drivers. Not all USB Serial have MAC support. I assume that you have installed the correct drivers from here.
First, open Terminal (Applications/Utilities/Terminal). Next, type
ls /dev/tty.*
to get a list of your serial lines. Pick the one that you want to open. For example, my list looks like this:
gf:dev gf$ ls -al tty.*
crw-rw-rw- 1 root wheel 18, 4 Jan 25 07:32 tty.Bluetooth-Modem
crw-rw-rw- 1 root wheel 18, 8 Jan 25 07:32 tty.Bluetooth-PDA-Sync
crw-rw-rw- 1 root wheel 18, 10 Jan 25 09:20 tty.PL2303-0000103D
crw-rw-rw- 1 root wheel 18, 0 Jan 25 07:32 tty.SerialPort-1
gf:dev gf$
And I know /dev/tty.PL2303-0000103D is the USB-to-serial adaptor becuase it’s connected, if you unplug it the tty.PL2303-0000103D stops being listed.
Knowing the serial port, you can just type screen portname datarate to show the serial data on the screen. In my case, it was:
screen /dev/tty.PL2303-0000103D 9600
To quit the screen app, type control-A, then control-\.
Postscript
I don’t think that this is very complete, but it worked for me and might help you to get your USB serial working. Please let me know if there anything I can add to complete this piece.
Update 2008÷12÷28: A reader has pointed out this article is based on a similar article at http://www.tigoe.net/pcomp/resources/archives/avr/000749.shtml. I must have copied some of the text and then mistakenly believed it was my own. Apologies for this mistake.
- Serial Console on OSX
- IOS: Reverse SSH console access — Part 2
- IOS: enable and .… disable ?
- IOS: Setting the TCP timeout on IOS
- IOS:CLI Tip — terminal full help
- OS X:Terminal break for Serial Console on OS X
- Changing the break character in Cisco IOS
- IOS CLI: show run linenum
- IOS: Setting Terminal Window Length
- IOS: Clearing an interface configuration
- IOS: Console, Terminal, Monitor, VTY — what is what ?
- IOS: “terminal monitor” on, off — logging to your terminal
- The poor man’s IOS Traffic Generator
- Setting the Defaults for PUTTY
- Putty — Recommended Default Settings for a Network Engineer
- Putty, the Command Line and NO clicky clicky
- Review: goSerial — Console Break for Network Devices on OSX



I bought the keyspan serial adapter and it had a CD with MAC drivers. Installed it, plugged in the keyspan to a switch and fired up Zterm. Zterm gave me a drop down of options on how to connect. Key was one of the options. I chose it and was connected. I too stumbled around for a few days before i got it working.
Brandon
I am sure that some people know how to do this, but for me, I had to work at it a little bit. There are some days when I just wish my first job was with *nix, my life would have been much simpler.
Note that the short form of “Macintosh” is not a TLA.
Sadly no. But I like the idea
Why did you steal this ?
http://www.tigoe.net/pcomp/resources/archives/avr/000749.shtml
It would seem that I owe an apology as I must have taken at least some part of this article from http://www.tigoe.net/pcomp/resources/archives/avr/000749.shtml.
If I try to remember I think I found a few references around the internet and had some notes that I had captured. I use a text editor and will cut/paste these notes. I must have forgotten or missed recording where I found those notes and when I later read the notes figured I must have written it — the author has the same tone as I do.
I have made a note in main article referencing the original post. Thanks for pointing it out, it wasn’t deliberate.
The PL2303 chipset based units are reasonably well supported under OSX since 10.4 now, and most USB serial leads are PL2303 based. There’s drivers available from Prolific, the manufacturers of the chipset and also an open source available through Sourceforge. However, there still seems to be an ongoing issue with sending breaks through the cable in that they get, er, broken. But otherwise, if you’re looking for a cable then try to ensure it’s PL2303 based.
Cheers,
Gary Smith
Using this, how could we send a break?, any key combination?
Has anyone found a way to make this work on OS X 10.6.2 with unlimited (or at least increased) scrollback? I’ve done mountains of research, but I’m no programmer. If anyone has (or can figure out) a usable applescript, I would extremely grateful!
Doing “screen /dev/tty.PL2.…” gives me a screen with the serial cable connected, which is great — but any idea how to get a second serial connection up? It’d be quite nice to have a screen split and viewing the output from two routers at the same time…