SECTION 6
Conversions and Interfaces
PEN*KEY
R
6200/6300 Hand-Held Computer Programmer’s Reference Guide 6-9
4. Update the modem configuration strings. There are specific modem strings
that must be used with different modems. The following strings are
recommended. They are subject to change.
"
NOTE:
String constants in C/C++ must use \\ to specify a \.
AMP 14.4
= ‘AT&FE0V0Q0X4W0&S1&C1&D2&Q5&KS0=0’
AMP/ADAPTER
= ‘AT&FE0V0Q0X1W0&S1&C1&D2&Q5&KS0=0F5’
AMP/CELLULAR
= ‘AT&FE0V0Q0&S1&C1&D2&K0)M1:E0@M18\N2*H1S7=90’
MICROCOM 28.8
= ‘AT&FE0V0Q0X4W0&S1&C1&D2&M0&R\QS0=0’
MICROCOM/ADAPTER
= ‘AT&FE0V0Q0X1W0&S1&C1&D2&M0&R\QS0=0%M1’
MICROCOM/CELLULAR
= ‘AT&FE0V0Q0&S1&C1&D2\Q)M1:E0@M18\N2*H2S7=90’
EPSON 14.4
= ‘AT&FE0V0Q0X4W0&S1&C1&D2&Q5&KS0=0’
EPSON/ADAPTER
= ‘AT&FE0V0Q0X1W0&S1&C1&D2&Q5&KS0=0’
EPSON/CELLULAR
= ‘AT&FE0V0Q0&S1&C1&D2&K0)M1:E0@M18\N2*H2S7=90’
IBM 28.8
= ‘AT&FE0V0Q0X4W0&S1&C1&D2&Q5&KS0=0’
IBM/ADAPTER
= ‘AT&FE0V0Q0X1W0&S1&C1&D2&Q5&KS0=0+MS=2’
IBM/CELLULAR
= ‘AT&FE0V0Q0&S1&C1&D2&K0)M1:E0@M18\N2*H1S7=90’
"
NOTE:
If the NORAND Norlib C++ library is used, skip the next step, as it is handled automatically.
5. Change communication routines to report errors caused by
NGENMOD.SYS. It is recommended that communication routines be
enhanced to recognize and report that a session failed due to
NGENMOD.SYS disabling the modem, to help the user know how to
resolve the problem. The easiest way to recognize that NGENMOD.SYS
has disabled the modem is to check if port power has been turned off:
int ApmGetPower (int iDevice)
{
int iV;
asm mov bx,iDevice
asm mov ax,0x530c
asm int 0x15
asm jc Error
asm mov iV,cx
return iV;
Error:
return –1; /* –1 indicates an error. */
}
// When a timeout error occurs, this function is called to
// determine if the modem card was disabled by NGENMOD.SYS.
// It sets a flag to indicate communications should be
// aborted.
void check_port(void)
{
if (POWER_OFF == ApmGetPower( DEVIC com_port))
{
abort_tcom = TRUE;
}
}
6. Conversions and
Interfaces