Cómo usar Arduino para crear un servidor de serie a WiFi
#include?lt;WiShield.hgt;
#define?WIRELESS_MODE_INFRA1
#define?WIRELESS_MODE_ADHOC2
//?¿Inalámbrico? ¿configuración?parámetros?----------------------------------------
byte?local_ip[]=?{10,0,0,3}; //?IP?dirección?de?WiShield
byte?gateway_ip[]?=?{10,0,0, 1}; //?router?o?gateway?IP?dirección
byte?subnet_mask[]?=?{255, 255, 255, 0} ///?subnet?mask?for?the ?local?red
prog_char?ssid[]?PROGMEM=?{"cutedigi"};?//?max?32?bytes
unsigned?char?security_type?=? 0;//?0?-?abierto;?1?-?WEP;?2?-?WPA;?3?-?WPA2
//?WPA/WPA2?frase de contraseña
const?prog_char?security_passphrase[]?PROGMEM?=?{"big_secret"};//?max?64?characters
//?WEP?Claves de 128 bits
//?muestra?llaves?HEX
prog_uchar?wep_keys[]?PROGMEM?=?{?0x01,?0x02,?0x03,?0x04,?0x05,?0x06,?0x07, ?0x08,?0x09,?0,?0x0b,?0x0c,?0x0d, //Clave?0 0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00, ?0x00,?0x00,?0x00,0x00,//?Clave?1 0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,?0x00,? 0x00, 0x00, // Clave ?3
};
//?configurar?el?modo?inalámbrico
//?infraestructura?-?conectar ?a?AP
//?adhoc?-?conectar?a?otro?dispositivo?WiFi
unsigned?char?wireless_mode?=?WIRELESS_MODE_INFRA;
unsigned?char?ssid_len;
unsigned?char?security_passphrase_len;