Command mode and Data mode refers to the two modes in which a computer modem may operate. These modes are defined in the Hayes command set, which is the de facto standard for all modems. These modes exist because there is only one channel of communication between the modem and the computer, which must carry both the computer's commands to the modem, as well as the data that the modem is enlisted to transmit to the remote party over the telephone line.
When a modem is in command mode, any characters sent to it are interpreted as commands for the modem to execute, per the Hayes command set. A command is preceded by the letters 'AT', which stand for 'Attention'. For example, if a modem receives 'ATDT5551212' while in the command mode, it interprets that as an instruction to dial the numbers 5551212 on the telephone, using touch-tone dialing. During a command mode operation, the modem may send responses back to the computer indicating the outcome of the command. For example, the modem may respond with the word "BUSY" in response to the ATDT command, if it hears a busy signal after dialing and is configured to listen for busy signals. Any communication in command mode (in both directions) is terminated by a carriage return.
When a modem is in data mode, any characters sent to the modem are intended to be transmitted to the remote party. [1] The modem enters data mode immediately after it makes a connection. For example, if ATDT5551212 resulted in a phone call that was answered by another computer modem, the modem would report the word "CONNECT" and then switch to data mode. Any further characters received over the serial link are deemed to be from the remote party, and any characters sent are transmitted to the remote party.
When a voice-capable modem is in "voice data" mode, any data sent to the modem is interpreted as audio data to be played over the phone line, rather than character bytes to be transmitted digitally to the other party.
Modems always start out in command mode when powered up. Here are the ways a modem can switch to data mode:
Modems switch back into command mode from data mode for the following reasons:
The DTR pin is usually how computers invoke the termination of a modem call nowadays. The +++ escape sequence is rarely used, and may even be disabled to avoid malfunction in case these characters are legitimately a part of the data stream (ignoring the 1-second pauses).
Today, most modems are configured with the characters "&C1&D2" in the initialization string, or otherwise behave this way by default. This causes the following behavior:
For normal dial-up data communications, modems enter data mode only once - starting when the session connects, and ending when the session disconnects. However, when modems are used for fax and voice (audio) communication, they rapidly switch between command and data modes several times during a call. This is because the role of the modem changes more frequently - rather than simply handing bytes from point A to point B, it is either negotiating parameters and pages with a fax machine, or switching between recording, pausing, and playback audio modes.
In fax and voice data modes, sometimes events occur that the modem wishes to signal to the computer regardless of whether it's in command or data mode. An example of such an event is a caller pressing a touch-tone key in voice mode. Other common out-of-band messages are notifications from the modem that data was lost because the computer is sending data either too slow or too fast, or that the modem hears an unexpected dial-tone on the line (meaning the caller probably hung up), or that the extension handset was picked up or hung up.
This type of event is signalled with a DLE message, which is a single-character message preceded by a Data Link Escape code. DLE is a character sent from the modem to the computer whose definition is unrelated to either command or data mode, and which uses a specific ASCII code (0x10) which never occurs in any AT commands or responses, so that it can be isolated from the command/response stream on that merit alone. In these modes, whenever a DLE (0x10) is sent, the character following it has a special non-command and non-data meaning. For example, a DLE followed by the number 2 means the caller pressed the number 2 on his telephone keypad. This could happen in either command or data mode so long as the phone line is in use by the modem and someone is on the other end of the line.
The DLE character could appear in fax or audio data. To avoid misinterpreting a 0x10 data byte as a DLE "bit stuffing" is used. Stuffing is a common encoding scheme for modems and used to escape character in streams. In this case stuffing means two DLE's characters in a row are interpreted as one literal byte with value 0x10.
DLE is also used lightly in communication from the computer to the modem. One specific DLE event signals the end of a fax page, or the end of an audio file. That event returns the modem back into command mode. Unlike in standard dial-up data mode, dropping DTR isn't an appropriate way to resume command mode since a hangup is not desired, and an escape code with mandatory pauses isn't suitable either. Because of this, literal 0x10 bytes in data are doubled from the computer to the modem as well.
DLE is never used in standard modem-to-modem data modes such as the one used for dial-up Internet access, at least not by the modem itself. In these modes, DLE is passed over the line just like any other character. DLE (and DLE-escaped messages) are only used by a modem for fax and voice applications, when it is specifically placed in a fax or voice mode.
In telecommunications, an acoustic coupler is an interface device for coupling electrical signals by acoustical means—usually into and out of a telephone.
The Telephony Application Programming Interface (TAPI) is a Microsoft Windows API, which provides computer telephony integration and enables PCs running Microsoft Windows to use telephone services. Different versions of TAPI are available on different versions of Windows. TAPI allows applications to control telephony functions between a computer and telephone network for data, fax, and voice calls. It includes basic functions, such as dialing, answering, and hanging up a call. It also supports supplementary functions, such as hold, transfer, conference, and call park found in PBX, ISDN, and other telephone systems.
In computer science, an escape sequence is a combination of characters that has a meaning other than the literal characters contained therein; it is marked by one or more preceding characters.
On computers, a serial port is a serial communication interface through which information transfers in or out sequentially one bit at a time. This is in contrast to a parallel port, which communicates multiple bits simultaneously in parallel. Throughout most of the history of personal computers, data has been transferred through serial ports to devices such as modems, terminals, various peripherals, and directly between computers.
The Serial Line Internet Protocol (SLIP) is an encapsulation of the Internet Protocol designed to work over serial ports and router connections. It is documented in RFC 1055. On personal computers, SLIP has largely been replaced by the Point-to-Point Protocol (PPP), which is better engineered, has more features, and does not require its IP address configuration to be set before it is established. On microcontrollers, however, SLIP is still the preferred way of encapsulating IP packets, due to its very small overhead.
The Hayes command set is a specific command language originally developed by Dale Heatherington and Dennis Hayes for the Hayes Smartmodem 300 baud modem in 1981.
GeoPort is a serial data system used on some models of the Apple Macintosh that could be externally clocked to run at a 2 megabit per second data rate. GeoPort slightly modified the existing Mac serial port pins to allow the computer's internal DSP hardware or software to send data that, when passed to a digital-to-analog converter, emulated various devices such as modems and fax machines. GeoPort could be found on late-model 68K-based machines as well as many pre-USB Power Macintosh models and PiPPiN. Some later Macintosh models also included an internal GeoPort via an internal connector on the Communications Slot. Apple GeoPort technology is now obsolete, and modem support is typically offered through USB.
In telecommunications, in-band signaling is the sending of control information within the same band or channel used for data such as voice or video. This is in contrast to out-of-band signaling which is sent over a different channel, or even over a separate network. In-band signals may often be heard by telephony participants, while out-of-band signals are inaccessible to the user. The term is also used more generally, for example of computer data files that include both literal data, and metadata and/or instructions for how to process the literal data.
Null modem is a communication method to directly connect two DTEs using an RS-232 serial cable. The name stems from the historical use of RS-232 cables to connect two teleprinter devices or two modems in order to communicate with one another; null modem communication refers to using a crossed-over RS-232 cable to connect the teleprinters directly to one another without the modems. It is also used to serially connect a computer to a printer, since both are DTE, and is known as a Printer Cable.
Hayes Microcomputer Products was a U.S.-based manufacturer of modems. The company is known for the Smartmodem, which introduced a control language for operating the functions of the modem via the serial interface, in contrast to manual operation with front-panel switches. This smart modem approach dramatically simplified and automated operation. Today almost all modems use a variant of the Hayes command set.
XMODEM is a simple file transfer protocol developed as a quick hack by Ward Christensen for use in his 1977 MODEM.ASM terminal program. It allowed users to transmit files between their computers when both sides used MODEM. Keith Petersen made a minor update to always turn on "quiet mode", and called the result XMODEM.
Internet fax, e-fax, or online fax is the use of the internet and internet protocols to send a fax (facsimile), rather than using a standard telephone connection and a fax machine. A distinguishing feature of Internet fax, compared to other Internet communications such as email, is the ability to exchange fax messages with traditional telephone-based fax machines.
The Microcom Networking Protocols, almost always shortened to MNP, is a family of error-correcting protocols commonly used on early high-speed modems. Originally developed for use on Microcom's own family of modems, the protocol was later openly licensed and used by most of the modem industry, notably the "big three", Telebit, USRobotics and Hayes. MNP was later supplanted by V.42bis, which was used almost universally starting with the first V.32bis modems in the early 1990s.
Novation, Inc., is an early modem manufacturer whose CAT series were popular in the early home computer market in the late 1970s and early 1980s, notably on the Apple II. The Hayes Smartmodem 300, introduced in 1981, helped kill off Novation and many other early modem companies over the next few years.
NO CARRIER (capitalized) is a text message transmitted from a modem to its attached device, indicating the modem is not connected to a remote system.
A voice modem is an analog telephone data modem with a built-in capability of transmitting and receiving voice recordings over the phone line. Voice modems are used for telephony and answering machine applications. Similar to the Hayes command set used for data modems, in which the host PC commands the modem via a series of commands known as AT commands, there exists a well-defined set of common voice AT commands that are somewhat consistent throughout the industry.
Data Carrier Detect (DCD) or Carrier Detect (CD) is a control signal present inside an RS-232 serial communications cable that goes between a computer and another device, such as a modem. This signal is a simple "high/low" status bit that is sent from a data communications equipment (DCE) to a data terminal equipment (DTE), i.e., from the modem or other peripheral to a computer in a typical scenario. It is present on virtually all PC serial ports - pin 1 of a nine-pin (DE9) serial port, or pin eight over a 25-pin (DB25) port. Its purpose varies depending on the device connected, but the most specific meaning is to indicate when a modem is connected to another remote modem via telephone lines.
A modulator-demodulator or modem is a computer hardware device that converts data from a digital format into a format suitable for an analog transmission medium such as telephone or radio. A modem transmits data by modulating one or more carrier wave signals to encode digital information, while the receiver demodulates the signal to recreate the original digital information. The goal is to produce a signal that can be transmitted easily and decoded reliably. Modems can be used with almost any means of transmitting analog signals, from light-emitting diodes to radio.
Data Terminal Ready (DTR) is a control signal in RS-232 serial communications, transmitted from data terminal equipment (DTE), such as a computer, to data communications equipment (DCE), for example a modem, to indicate that the terminal is ready for communications and the modem may initiate a communications channel.
The Serial Input/Output system, universally known as SIO, was a proprietary peripheral bus and related software protocol stacks used on the Atari 8-bit family to provide most input/output duties for those computers. Unlike most I/O systems of the era, such as RS-232, SIO included a lightweight protocol that allowed multiple devices to be attached to a single daisy-chained port that supported dozens of devices. It also supported plug-and-play operations. SIO's designer, Joe Decuir, credits his work on the system as the basis of USB.