Thanks for your help, but I'm having problems with your sugestion too. The 
palmtop isn't reseting, but I can't communicate with the modem. Is  
0x8000(Cradle Port) the correct port to communicate with the modem?

MdmInfoPtr ModemInfo=(MdmInfoPtr)MemPtrNew(sizeof(MdmInfoType));
if(SrmOpen(0x8000,57600,&gRefNum)!=0){
        FrmCustomAlert(ErroAlert,"Erro"," "," ");
        SrmClose((UInt16)gRefNum);
}else{
   ModemInfo->portID            = gRefNum;
   ModemInfo->initialBaud       = 57600;
   ModemInfo->cmdTimeOut        = mdmDefCmdTimeOut;
   ModemInfo->dtWaitSec         = -1;
   ModemInfo->dcdWaitSec        = -1;
   ModemInfo->volume            = mdmVolumeLow;
   ModemInfo->pulse             = true;
   ModemInfo->hwHShake  = true;
   ModemInfo->autoBaud  = true;
   ModemInfo->connectBaud       = 0;
   Erro=MdmDial(ModemInfo,NULL,"ATZH&F0&R1&S1&C1&D2E1L3","37187997");
   switch(Erro){
        case 0:
                FrmCustomAlert(ErroAlert,"Conex�o Ok."," "," ");
        break;
        case mdmErrNoTone:
                FrmCustomAlert(ErroAlert,"Erro: mdmErrNoTone"," "," ");
                SrmClose((UInt16)gRefNum);
        break;
        case mdmErrNoDCD:
                FrmCustomAlert(ErroAlert,"Erro: mdmErrNoDCD"," "," ");
                SrmClose((UInt16)gRefNum);
        break;
        case mdmErrBusy:
                FrmCustomAlert(ErroAlert,"Erro: mdmErrBusy"," "," ");
                SrmClose((UInt16)gRefNum);
        break;
        case mdmErrUserCan:
                FrmCustomAlert(ErroAlert,"Erro: mdmErrUserCan"," "," ");
                SrmClose((UInt16)gRefNum);
        break;
        case mdmErrCmdError:
                FrmCustomAlert(ErroAlert,"Erro:mdmErrCmdError"," "," ");
                SrmClose((UInt16)gRefNum);
        break;
case mdmErrNoModem:
                                                                
MemSet(Mensagem,sizeof(Mensagem),0);
                                                                
StrPrintF(Mensagem,"Erro: Modem n�o Encontrado(0x%x)",gRefNum);
                                                                
FrmCustomAlert(ErroAlert,Mensagem," "," ");
                                                                
SrmClose((UInt16)gRefNum);
                                                        break;
                                                        default:
                                                                
FrmCustomAlert(ErroAlert,"TimeOut Esgotado."," "," ");
                                                                
SrmClose((UInt16)gRefNum);
                                                        break;
                                                }
                                        }
                    }


_________________________________________________________________
Chegou o novo MSN Explorer. Instale j�. � gratuito! 
http://explorer.msn.com.br


-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to