I wanted to use a linux box to control a router through the serial port. How do I start a terminal session and communicate with the router through serial port?
Minicom (or xminicom) is exactly what you need. But there are a couple things to note -- minicom comes by default ready to use the modem to connect. First thing you need to do -- as root run 'minicom -s' and under 'Serial Port Setup' change 'A' (Serial Device) to '/dev/ttyS0' for COM1 or '/dev/ttyS1' for COM2. You'll also have to change 'E' (Bps/par/Bits) to what you need for your serial device (ie if it is a Cisco router is 9600 8N1 and No Flow Control) - you'll have to play with these settings if you cannot get connected to your device right away.
That is all you have to do, but I also go under the 'Modem and Dialing' and remove everything from the 'Init String' and 'Reset String' - I have seen problems with those, even when using minicom for a serial device.
Finally choose 'Save settings as dfl' and 'Exit from Minicom'.
That will change the system wide settings and you can now launch minicom as a regular user and connect to a serial device.
If you don't have minicom (or xminicom) on your box, take a look at
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.