Library to use a wifly module: RN 131 C/G
Dependents: RN-XV_simple_server
Diff: Wifly.cpp
- Revision:
- 5:9890eb81f730
- Parent:
- 4:06ca04e2e279
- Child:
- 7:c6cf9ae117b1
--- a/Wifly.cpp Fri Aug 12 14:46:42 2011 +0000 +++ b/Wifly.cpp Fri Aug 12 15:12:57 2011 +0000 @@ -8,12 +8,12 @@ Wifly::Wifly( PinName tx, PinName rx, PinName _reset, char * ssid, char * phrase, - bool wpa, char * ip, char * netmask, bool dhcp, int baudrate, int bits,Serial::Parity parity, - int stop_bits): wifi(tx, rx), reset_pin(_reset) + bool wpa, char * ip, char * netmask, bool dhcp, int baudrate): + wifi(tx, rx), reset_pin(_reset) { wifi.baud(baudrate); reset_pin = 1; - wifi.format(bits, parity, stop_bits); + wifi.format(8, Serial::None, 1); this->wpa = wpa; this->phrase = phrase; this->ssid = ssid; @@ -28,11 +28,12 @@ Wifly::Wifly( PinName tx, PinName rx, PinName _reset, char * ssid, char * ip, char * netmask, int channel, - int baudrate, int bits,Serial::Parity parity,int stop_bits): wifi(tx, rx), reset_pin(_reset) + int baudrate): + wifi(tx, rx), reset_pin(_reset) { wifi.baud(baudrate); reset_pin = 1; - wifi.format(bits, parity, stop_bits); + wifi.format(8, Serial::None, 1); adhoc = true; this->ssid = ssid; this->ip = ip;