User`s manual

BL1600 System Development s 49
Miscellaneous Functions
int Dget
_
modem
_
command()
Deciphers Hayes-compatible modem command.
These are the modem commands.
0 "\nOK" // okay respond
1 "\nCONNECT" // connect at 300 bps
2 "\nRING" // ring detected
3 "\nNO CARRIER" // no carrier
4 "\nERROR" // command error
5 "\nCONNECT 1200" // connect at 1200 bps
6 "\nNO DIALTONE" // no dial tone
7 "\nBUSY" // line busy
8 "\nNO ANSWER" // no answer
9 "\nCONNECT 2400" // connect at 2400 bps
10 "\n" // just a line feed
A Hayes Smart Modem ( or compatible) is recommended. A NULL
modem is needed between the BL1600 and the modem.
Some modems may require that the RTS(4), CTS(5) and DTR(20) lines
on the modem side be tied together.
A NULL modem is not needed between COM1 and COM2 and
external modems.
RETURN VALUE: 1 if no modem command is matched.
void Drestart
_
z0modem()
Restarts the modem (during start of program or abnormal operation).
void Dz0modem
_
chk( char *buffer )
Checks buffer for valid modem commands. The function takes the
appropriate response to the modem command if it finds a valid modem
command.
RETURN VALUE: 0valid modem command; 1invalid modem
command.
void Dz0
_
circ
_
int()
Interrupt service routine for Z180 Port 0.
void Ddelay
_
1sec()
Creates a 1-second delay (approximately). If RUNKERNEL is defined,
suspend(40) is used.
void Ddelay
_
100ms()
Creates a 100 ms delay (approximately).