Denso Power Net Terminal BHT-7500 Especificaciones Pagina 425

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 560
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 424
416
main: Main program
on error goto Err.TCP Prepare for error interrupt (To Err.TCP
at the time of error occurrence)
.
.
.
open "COM3:" as #hCom3% Open a wireless communications device
.
.
.
Use the OPEN "COM3:" statement
sock.stts% = 1 Set "1" to socket processing number
.
.
.
call "socket.fn3" 41 interface% Connect TCP/IP communications pathway
(system settings)
.
.
.
Use SOCKET.FN3 function #41
sock.stts% = 2 Set "2" to socket processing number
.
.
.
call "socket.fn3" 26 family%,type%,protocol%,sockfd% Generate socket
.
.
.
Use SOCKET.FN3 function #26
sock.stts% = 3 Set "3" to socket processing number
.
.
.
call "socket.fn3" 3 sockfd%,family%,port%,serv.addr$ Connect socket
.
.
.
Use SOCKET.FN3 function #3
sock.stts% = 4 Set "4" to socket processing number
.
.
.
.
.
.
return
Err.TCP: Error interrupt processing
Control transferred to this step if an
error occurs
err.code% = ERR Get error number
err.line% = ERL Get error line number
resume Sock.Err RESUME statement to transfer control from
error interrupt processing to socket error
processing routine
Sock.Err: Socket error processing routine
print " ERR : " ; hex$( err.code% ) Display error number
print " ERL : " ; hex$( err.line% ) Display error line number
if sock.stts% >= 3 then If OK until socket generation,
call "socket.fn3" 28 sockfd% close socket
endif
if sock.stts% >= 2 then If OK until connection of TCP/IP
communications pathway
call "socket.fn3" 43 interface% disconnect the pathway
endif
if sock.stts% >= 1 then If OK until opening the wireless device
close #hCom3% close the device
endif
goto main To main program
Vista de pagina 424
1 2 ... 420 421 422 423 424 425 426 427 428 429 430 ... 559 560

Comentarios a estos manuales

Sin comentarios