Hi all… I’ve vritten these code:
if ( 0L == inet_addr(config->srvip)) {
printf( "ApriSocket: Errore di conversone della stringa di indirizzo: %s
", config->srvip);
return 0;
}
//if ( tcp_open( socket, 0, inet_addr(config->srvip), (word ) config->portasrv, NULL) == 0L ) {
for ( ntent = 1 ; ntent < 4 ; ntent++ ) {
printf( "ApriSocket: tentativo di connessione %d/3 su: ", ntent);
if ( statomodem == PPPCONNG ) {
printf( "GPRS
");
if ( tcp_extopen( socket, IF_PPP2, 0, inet_addr(config->srvip),
(word ) config->portasrv, NULL, socketbuff, 4096 ) == 0 ) {
printf( "ApriSocket: non sono riuscito a connettermi: %d%s!
", sock_error( socket, 0), sockerr( socket));
return 0;
}
} else {
printf( "SAT
");
if ( tcp_extopen( socket, IF_PPP1, 0, inet_addr(config->srvip),
(word ) config->portasrv, NULL, socketbuff, 4096 ) == 0 ) {
printf( "ApriSocket: non sono riuscito a connettermi!: %d%s!
", sock_error( socket, 0), sockerr( socket));
return 0;
}
}
and when it executes:
tcp_extopen( socket, IF_PPP2, 0, inet_addr(config->srvip),
(word ) config->portasrv, NULL, socketbuff, 4096 )
the board freeze and totally block.
On same hardware the result is different!!! Why???