Chapter 6. Serial I/O, SNP & RTU Protocols
GFK-2222AD
April 2018
219
6.2.12
Autodial Function (4400)
This feature allows the CPU to automatically dial a modem and send a specified byte string.
To implement this feature, the port must be configured for Serial I/O. After the autodial function is
executed and the modem has established a connection, other serial I/O functions (Write bytes, Set Up
Input Buffer, Flush Input buffer, Read port status, Write port control, Read bytes, Read String, and Cancel
Operation) can be used.
Example
Pager enunciation can be implemented by three commands, requiring three COMMREQ command
blocks:
Autodial
:
04400 (1130h)
Dials the modem.
Write Bytes
:
04401 (1131h)
Specifies an ASCII string, from 1 to 250 bytes in length, to send from the serial port.
Autodial
:
04400 (1130h)
It is the responsibility of the application program to hang up the phone connection.
This is accomplished by reissuing the autodial command and sending the hang up
command string.
Autodial Command Block
The Autodial command automatically transmits an Escape sequence that follows the Hayes convention.
If you are using a modem that does not support the Hayes convention, you may be able to use the Write
Bytes command to dial the modem.
Examples of commonly used command strings for Hayes-compatible modems are listed below:
Command String
Length
Function
ATDP15035559999<CR>
16 (10h)
Pulse dial the number 1-503-555-9999
ATDT15035559999<CR>
16 (10h)
Tone dial the number 1-503-555-9999
ATDT9,15035559999<CR>
18 (12h)
Tone dial using outside line with pause
ATH0<CR>
5 (05h)
Hang up the phone
ATZ <CR>
4 (04h)
Restore modem configuration to internally saved values