From f9e0e0cc61bd27ea6f9aa6ae20083692918189e3 Mon Sep 17 00:00:00 2001 From: dnc40085 Date: Sat, 9 May 2015 04:17:35 -0700 Subject: [PATCH] Added examples to description of wifi.sta.config() --- app/modules/wifi.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/app/modules/wifi.c b/app/modules/wifi.c index bf3a20c7..64330f34 100644 --- a/app/modules/wifi.c +++ b/app/modules/wifi.c @@ -418,6 +418,26 @@ static int wifi_station_getconfig( lua_State* L ) * bssid: MAC address of Access Point you would like to connect to. * Returns: * Nothing. + * + * Example: + --Connect to Access Point automatically when in range + wifi.sta.getconfig("myssid", "password") + + --Connect to Access Point, User decides when to connect/disconnect to/from AP + wifi.sta.getconfig("myssid", "mypassword", 0) + wifi.sta.connect() + --do some wifi stuff + wifi.sta.disconnect() + + --Connect to specific Access Point automatically when in range + wifi.sta.getconfig("myssid", "mypassword", "12:34:56:78:90:12") + + --Connect to specific Access Point, User decides when to connect/disconnect to/from AP + wifi.sta.getconfig("myssid", "mypassword", 0) + wifi.sta.connect() + --do some wifi stuff + wifi.sta.disconnect() + * */ static int wifi_station_config( lua_State* L ) {