Epson UB-E02 Specifiche Pagina 68

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 84
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 67
4-12 Programming Samples Rev. A
buf[11] = 0x00;
buf[12] = 0x00; // Parameter length
buf[13] = 0x00;
/* send a packet */
i = sendto(sock, buf, 14, 0, (struct sockaddr*)&addr, sizeof(addr));
/* receive packet */
fromlen = sizeof(addr);
len = recvfrom(sock, buf, MAXBUF, 0, (struct sockaddr*)&addr, &fromlen);
/* print receive packet */
if (len) {
if ((buf[10] == 0x00) && (buf[11] == 0x00))
for (i = 0; i < len; i++)
printf("%3d:%02Xh\n", i, buf[i] & 0xff);
}
/* close socket */
closesocket(sock);
return 0;
}
Vedere la pagina 67
1 2 ... 63 64 65 66 67 68 69 70 71 72 73 ... 83 84

Commenti su questo manuale

Nessun commento