Table of Contents
Here is a description of the Hayes Command Set. Most modems follow this command set to large extent. If you lost your modem manual or never had one in the first place, this reference might come in handy. I for instance finally found out how to turn my modems speaker off: ATM0 -- Finally: Silence!
The modem initialization string consists of a series of commands. It prepares the modem for communications, setting such features as dialing mode, waits, detection of the busy signal and many other settings. Newer modem communications programs reset the initializations string for you according to which menu options you select, which features you enable, etc..
For many years Hayes modems have been the standard. As the field of modem manufactures has grown, most have adhered at least loosely to the Hayes standard. The following is a partial list of the Hayes command set. (called the “AT” commands). The Hayes Command Set can be divided into four groups:
A capital character followed by a digit. For example, M1.
An “&” (ampersand) and a capital character followed by a digit. This is an extension of the basic command set. For example, &M1. Note that M1 is different from &M1.
Usually started by either a backslash (“\”), or a percent sign (“%”), these commands vary widely among modem manufacturers. For that reason, only a few of these commands are listed below.
Sr
=n
where r
is the number of the register to be changed,
and n
is the new value that is
assigned.
A “register” is computerese for a specific physical location in memory. Modems have small amounts of memory onboard. This fourth set of commands is used to enter values in a particular register (memory location). The register will be storing a particular “variable” (alpha-numeric information) which is utilized by the modem and communication software. For example, S7=60 instructs your computer to “Set register #7 to the value 60”.
Although most commands are defined by a letter-number combination (L0, L1 etc.), the user of a zero is optional. In this example, L0 is the same as a plain L. Keep this in mind when reading the table below!
Here are some of the most important characters that may appear in the modem initialization string. These characters normally should not be changed.
Tells the modem that modem commands follow. This must begin each line of commands.
Resets the modem to it's default state
makes your software pause for a second. You can use more than
one , in a row. For example, ,,,, tells
the software to pause four seconds. (The duration of the pause is governed by
the setting of register S8
.
Sends the terminating Carriage Return character to the modem. This is a control code that most communication software translates as “Carriage Return”
In alphabetical order:
Table B.1. Basic Hayes Command Set
Command | Description | Comments |
---|---|---|
A0 or A | Answer incoming call | |
A/ | Repeat last command | Don't preface with AT. Enter usually aborts. |
B0 or B | Call negotiation | V32 Mode/CCITT Answer Seq. |
B1 | Call negotiation | Bell 212A Answer Seq. |
B2 | Call negotiation | Verbose/Quiet On Answer |
D | Dial | Dial the following number and then handshake in originate mode.
|
E0 or E | No Echo | Will not echo commands to the computer |
E1 | Echo | Will echo commands to the computer (so one can see what one types) |
H0 | Hook Status | On hook - Hang up |
H1 | Hook status | Off hook - phone picked up |
I0 or I | Inquiry, Information, or Interrogation | This command is very model specific. I0 usually returns a number or code, while higher numbers often provide much more useful information. |
L0 or L | Speaker Loudness. Modems with volume control knobs will not have these options. | Off or low volume |
L1 | Low Volume | |
L2 | Medium Volume | |
L3 | Loud or High Volume | |
M0 or M | Speaker off | M3 is also common, but different on many brands |
M1 | Speaker on until remote carrier detected (that is, until the other modem is heard) | |
M2 | Speaker is always on (data sounds are heard after CONNECT) | |
N0 or N | Handshake Speed | Handshake only at speed in S37 |
N1 | Handshake at highest speed larger than S37 | |
O0 or O | Return Online | See also X1 as dial tone detection may be active. |
O1 | Return Online after an equalizer retrain sequence | |
Q0 or Q1 | Quiet Mode | Off - Displays result codes, user sees command responses (for example,
OK ) |
Q1 | Quiet Mode | On - Result codes are suppressed, user does not see responses. |
Sn ? | Query the contents of S-register
n | |
Sn =r | Store | Store the value of r in S-register
n |
V0 or V | Verbose | Numeric result codes |
V1 | English result codes (for example,
CONNECT ,
BUSY , NO
CARRIER etc.) | |
X0 or X | Smartmodem | Hayes Smartmodem 300 compatible result codes |
X1 | Usually adds connection speed to basic result codes (for example,
CONNECT 1200 | |
X2 | Usually adds dial tone detection (preventing blind dial, and sometimes preventing AT0) | |
X3 | Usually adds busy signal detection | |
X4 | Usually adds both busy signal and dial tone detection | |
Z0 or Z | Reset | Reset modem to stored configuration. Use Z0, Z1 etc. for multiple profiles. This is the same as &F for factory default on modems without NVRAM (non voltaile memory) |
Would you like to comment or contribute an update to this page?
Send feedback to the TDE Development Team