navbarPDF
Strip_TechNotes

Modem-Router Connection Guide

Document ID: 17719


Contents

Introduction
Prerequisites
      Requirements
      Components Used
      Conventions
Hardware Configuration
      Cabling Issues
      Console Port Issues
Line Configuration
      Bitrate Information
Modem Configuration
      Modemcaps and modem autoconfigure
      Create a Modemcap
      Create a Chat Script
      Reverse Telnetting
Caveats
Manufacturer-Specific Modem Initialization Commands
Related Information

Introduction

This document explains how to configure Cisco routers and access servers for external modems connected to asynchronous and AUX ports. It explains how to configure the modem to operate properly when connected. This document addresses connection to a console port, but only with reference to concepts, not actual installation practices.

Note: This document is not a reference for the Microcom or MICA modems used internally on the AS5200, AS5300, AS5800, Cisco 2600, or Cisco 3600 routers. This document is also not a reference for synchronous modems, though there can be a number of similarities. This document is a reference for asynchronous modems only. While much of the information here can apply to synchronous modems, do not rely on it when you configure them.

Prerequisites

Requirements

There are no specific prerequisites for this document.

Components Used

The information in this document is based on the software and hardware versions below.

Note: This document does not address platforms that have reached End of Life status, such as ASMs, MSMs, CSMs, STS-10s or 500-CSs.

The information presented in this document was created from devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If you work in a live network, ensure that you understand the potential impact of any command before you use it.

Conventions

Refer to the Cisco Technical Tips Conventions for more information on document conventions.

Hardware Configuration

The first step to attach a modem to a router is to install the hardware. The main concerns are which cables to use and why or why not to use the console port for a modem.

Cabling Issues

It is important to connect the modem to the router before you configure the modem in order to verify communication between them. If the cabling is incorrect, the rest of the process fails.

As a rule, external modems are built with a female data communications equipment (DCE) DB-25 port for connection to a controlling device such as a PC or a router. This table helps you to select the appropriate cables to make the connection between the router and the modem. The table also includes information on the required cabling and the types of physical ports on Cisco routers to which you can connect a modem.

Router Port

Examples of where found

Cables Required

DB-25 DTE

Male DB-25 AUX on the Cisco 4000, 7000, 7200, and 7500.

Straight-through DB-25F -- DB25M RS-232 cable.

DB-25 DCE

Female DB-25 console port on the Cisco 4000 and 7000 series.

Null-modem DB-25M -- DB25M RS232 cable. A rolled RJ-45--RJ-45 with CAB-25AS-MMOD adapters on both ends will work.

DB-60

Sync/async interfaces. Cisco 1005, 1600s, and 2500s; network modules on the Cisco 2600, 3600, and 4000.

Cisco-specific cable, the CAB-232MT(=).

RJ-45

AUX or CON on the Cisco 2500s, 2600, 3600, AS5200, and AS5300.

Rolled RJ-45--RJ-45 cable with adapter marked "MODEM" (part number CAB-25AS-MMOD).

68-pin

Cisco 2509-2512; network modules on the Cisco 2600 and 3600.

Cisco parts CAB-OCTAL-ASYNC(=) (with connectors marked "MODEM") and CAB-OCTAL-MODEM(=).

"Smart Serial"

WAN interface card (WIC) on 1720 and 2600s.

Cisco part CAB-SS-232MT(=).

Note: Sync/async interfaces require the physical-layer async configuration command in order to operate in asynchronous mode.

Note: The Cisco 1005 requires the IP/ASYNC or the IP/IPX/ASYNC feature set of Cisco IOS Software in order to allow asynchronous mode on its Serial interface.

Console Port Issues

There are several advantages to connecting a modem to the console port of a router instead of the AUX port. However, the disadvantages are significant.

Advantages of connecting a modem on the console port:

Disadvantages of connecting a modem on the console port:

Note: The remainder of this document addresses non-console connections.

Line Configuration

It is essential that you configure the TTY line before you configure or initialize the modem itself. The two main reasons are:

In general, this line configuration works best:

line "x"

TTY #. AUX port is line 1 on the router, last_tty+1 on the access server, line 65 on the Cisco 2600s and 3620, and line 129 on the Cisco 3640.

speed "xxxxx"

Set to the highest speed in common between the modem and the port. This value is usually 115200 baud. See the Bitrate Information.

stopbits 1

Improve throughput by reducing async framing overhead (default is stopbits 2).

flowcontrol hardware

RTS/CTS flow control.

modem inout

Drop connection on loss of DCD (DSR). Cycle DTR for connection close. This command also allows outbound connections to the modem.

transport input all | telnet

Allow outbound connections to this line. Needed in order to allow reverse Telnet to the modem.

This configuration assumes that the modem always talks to us at "speed" (which is why you must LOCK SPEED on the modem), that the CD lead of the modem reflects the actual state of the carrier, and that the modem hangs up when the router drops DTR. Avoid substituting autobaud for speed if at all possible since it usually results in lower throughput.

Bitrate Information

Maximum Speed

Supporting platforms and interfaces

38400

Most AUX ports

115200

Cisco 1005, 1600, and 2509 through 2512 AUX on Cisco 2600 and 3600 Modules and WICs that support external asynchronous modems (for example, NM-16A, WIC-2A/S)

Note: If you are routing over the AUX port, notice that each character generates a processor interrupt. You can resolve abnormally high CPU utilization when you use a lower AUX port speed.

Modem Configuration

Cisco recommends you use the modem autoconfigure type <modemcap_name> command (introduced in Cisco IOS Software Release 11.1), to configure modems attached to async lines. If you use a version of Cisco IOS Software earlier than 11.1, you can use script startup and script reset to configure the modems via a chat script.

For most applications, configure a modern modem as this list details:

Refer to the documentation provided by your vendor or see the www.56k.com leavingcisco.com page for a list of links to this documentation for details on the command set used by your modem,.

Modemcaps and modem autoconfigure

Cisco IOS Software maintains a set of built-in modemcaps for various internal and external modems. This output shows an example modemcap from Cisco IOS Software Release 11.3(9)T:

router#show modemcap

default
codex_3260
usr_courier
usr_sportster
hayes_optima
global_village
viva
telebit_t3000
microcom_hdms
microcom_server
nec_v34
nec_v110
nec_piafs
cisco_v110
mica

If you think one of these built-in modemcaps is suitable, you can use the modem autoconfigure type <modem_name> or the modem autoconfigure discovery command:

async-1#terminal monitor
async-1#debug confmodem
Modem Configuration Database debugging is on
async-1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
async-1(config)#line 1
async-1(config-line)#modem autoconfigure discovery
async-1(config-line)#

*Mar 3 03:02:19.535: TTY1: detection speed (38400) response ---OK---
*Mar 3 03:02:24.727: TTY1: Modem type is default
*Mar 3 03:02:24.731: TTY1: Modem command: --AT&F&C1&D2SO=1H0--
*Mar 3 03:02:25.259: TTY1: Modem configuration succeeded
*Mar 3 03:02:25.259: TTY1: Detected modem speed 38400
*Mar 3 03:02:25.259: TTY1: Done with modem configuration

Note: The built-in modemcap mica consists of an &F. You can use it with many modems to reset to factory defaults.

Note: Cisco does not warrant the suitability or currentness of the built-in modemcaps for non-Cisco modems.

You can also define your own modemcap and use the modem autoconfigure type command:

async-1#terminal monitor
async-1#debug confmodem
Modem Configuration Database debugging is on
async-1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
async-1(config)#modemcap edit MyTest misc &FSO=1
async-1(config)#line 1
async-1(config-line)#modem autoconfigure type MyTest
async-1(config-line)#

*Mar 3 03:06:30.931: TTY1: detection speed (38400) response ---OK---
*Mar 3 03:06:30.963: TTY1: Modem command: --AT&FSO=1--
*Mar 3 03:06:31.483: TTY1: Modem configuration succeeded
*Mar 3 03:06:31.487: TTY1: Detected modem speed 38400
*Mar 3 03:06:31.487: TTY1: Done with modem configuration

Create a Modemcap

Use this global configuration command in order to define your own modemcap:

modemcap edit <modemcap_name> miscellaneous <initialization string>

The modemcap is applied to the line configuration with this command:

modem autoconfigure type <modemcap_name>

Here are some useful manufacturer-specific modem commands.

Note: The initialization string in the modemcap edit command is entered without a preceding AT and without the terminating &W.

Note: The modemcap_name in these commands should not be the same as one of the predefined entries listed by the show modemcap command.

Note: The initialization string should begin with the command to reset to defaults (typically &F or &F1).

Note: For this method to work, the modem must be configured with echo and response codes turned on. Modems usually come from the factory with these values set. However, you might need to manually reverse Telnet to the modem and issue the command to turn on echo and response. The usual command to do this is ATE1Q0. Check your modem documentation.

Create a Chat Script

Use this global configuration command to configure a chat script for the configuration of a modem:

chat-script <script-name> AT OK "initialization string" OK

The chat script can be invoked manually for a single line with this command:

start-chat <script-name><line-number>

The chat script can also be invoked automatically. Add this command to the line configuration:

script startup <script-name>
script reset <script-name>

The chat script is invoked every time the system reloads, the line resets at the termination of a session, or the line is cleared manually.

Use the debug chat command to verify that the chat script functions properly.

Note: For this method to work, you must configure the modem with echo and response codes turned on. Modems usually come from the factory with these values set. But, you might need to manually reverse Telnet to the modem and issue the command to turn on echo and response. The usual command to do this is ATE1Q0. Check your modem documentation.

Reverse Telnetting

Issue this command to establish a reverse Telnet connection:

telnet x.x.x.x 2yyy or [2000+yyy]

The x.x.x.x represents the IP address of any up/up interface on the Cisco router (for example, an Ethernet or Loopback) and yyy is the line number to which you want to connect. If you have already configured the TTY line, you can issue the telnet command from anywhere on the network that can ping the x.x.x.x interface.

The AUX port of any router is the last async line number + 1. You can use the show line or show line aux 0 command to see which line number this is.

If your connection is refused, this usually means that there is already a connection to that port, or there is an EXEC (prompt) that runs on that port. The cause can be that the modem fails to lower CD after a call disconnects. This results in an EXEC that remains after the disconnect. In order to force the line back into an idle state, you can clear the line from the console to try again. If it still fails, make sure that you have set the modem inout and transport input all | telnet commands for that line. Also be sure that the modem is not set to override DTR (for example, as the USR modems can do with DIP switch settings). If you do not have modem control (as in pre-9.21 AUX ports), be sure to set the no exec command on the line before you make a reverse connection. You can also try to configure the modem using an external terminal. As a last resort, disconnect the modem, clear the line, make the Telnet connection, and then attach the modem. This prevents a misconfigured modem from denying line access.

Always issue the initialization commands to the modem starting with AT and issue them at the speed at which you wish the modem to talk to the Cisco router. This ensures that the modem always talks at the expected speed regardless of the speed of any incoming modem connection (if you set the modem to lock on the DTE speed, which is required).

Caveats

Manufacturer-Specific Modem Initialization Commands

Recommended initialization strings are provided here for some common modems, but be aware that Cisco does not warrant that they are suitable or current. When in doubt, refer to the modem vendor's documentation or technical support.

Modem Brand

Initialization String

Notes

3Com/USRobotics

&F1S0=1

&F1 factory hardware flow control defaults In addition to the initialization string, 3Com/USR modems require DIP switches to be properly set. Switches 3 and 8 must be down and all the rest must be up.

AT&T/Paradyne

&FS0=1&C1&D3\Q3\N7%C1

 

Best Data Smart One

&FS0=1&C1&D3

 

Diamond/Supra

&FS0=1

 

Global Village

&FS0=1&C1&D3\Q3\J0\N3%C1

 

Hayes Optima

&FS0=1&Q9&C1&D3

Note: Do not use the built-in hayes_optima modemcap. It sets &Q6, which disables error control.

Microcom

&FS0=1&C1&D3\Q3\J0\N6%C1

Note: This information is not intended for use with the internal modems found on the AS5200, Cisco 2600, or Cisco 3600 platforms. This information is intended for Microcom stand-alone modems.

Motorola ModemSurfr

&FS0=1&C1&D3\J

 

Motorola/Codex

&FS0=1&C1&D3*FL3*SC1*SM3*DC1

 

Multitech

&FS0=1&C4&D3$SB115200

Tip:  For Multitech modems: The DTE speed must be expressly declared with the $SB command. Set it to whatever line speed you have configured. Failure to do so results in speed mismatches.


Related Information


Toolbar

All contents are Copyright © 1992-2005 Cisco Systems, Inc. All rights reserved. Important Notices and Privacy Statement.


Updated: Sep 29, 2005Document ID: 17719