WIFi
Dependencies: WiflyInterface mbed
Revision 0:cfdce53ce25b, committed 2014-10-09
- Comitter:
- mayu_hori
- Date:
- Thu Oct 09 22:53:43 2014 +0000
- Commit message:
- Wifi:; Version 1.0
Changed in this revision
diff -r 000000000000 -r cfdce53ce25b WiflyInterface.lib --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/WiflyInterface.lib Thu Oct 09 22:53:43 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/samux/code/WiflyInterface/#108340829acc
diff -r 000000000000 -r cfdce53ce25b main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Thu Oct 09 22:53:43 2014 +0000 @@ -0,0 +1,27 @@ +#include "mbed.h" +#include "WiflyInterface.h" + + + +Serial pc(USBTX, USBRX); + +/* wifly object where: +* - p9 and p10 are for the serial communication +* - p25 is for the reset pin +* - p26 is for the connection status +* - "mbed" is the ssid of the network +* - "password" is the password +* - WPA, WEP_128 or NONE is the security CAMBIAR EL WIFLY.H +*/ +// + +WiflyInterface wifly(D1, D0, D2, D3, "iPhone de Mayumi", "vs8uykp08iro", WPA) ; //WiflyInterface( PinName tx, PinName rx, PinName reset, PinName tcp_status,const char * ssid, const char * phrase, Security sec) +// mbed Application Board +//WiflyInterface wifly(p9, p10, p30, p29, "mbed", "password", WPA); + +int main() { + wifly.init(); // use DHCP + while (!wifly.connect()); // join the network + printf("IP Address is %s\n\r", wifly.getIPAddress()); + wifly.disconnect(); +} \ No newline at end of file
diff -r 000000000000 -r cfdce53ce25b mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Thu Oct 09 22:53:43 2014 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/552587b429a1 \ No newline at end of file