From a4068b573f4ddbf2fe5ad7ac793c1304e098637f Mon Sep 17 00:00:00 2001 From: dacb Date: Tue, 16 Dec 2014 01:05:41 -0800 Subject: [PATCH] more updated documentation --- README.md | 34 ++++++++++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 4bdba44..74ebddd 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,7 @@ Absolutely transparent bridge for the ESP8266 This is really basic firmware for the ESP that creates a totally transparent TCP socket to ESP UART0 bridge. Characters come in on one interface and go out the other. The totally transparent bridge mode is something that has been missing and is available on higher priced boards. **Pros: ** + * It works. Do you already have a serial project to which you just want to add WiFi? This is your ticket. No more dealing with the AT command set. * You can program your Arduino over WiFi. Just hit the reset button and upload your sketch using avrdude's socket port, e.g. ``` @@ -20,7 +21,7 @@ avrdude -c avrisp -p m328p -P net:192.168.4.1:23 -F -U flash:w:mySketch.hex:i ``` #define CONFIG_DYNAMIC ``` -The dynamic configuration commands are: +Telnet into the module and issue commands prefixed by +++AT to escape each command from bridge mode. The dynamic configuration commands are: ``` +++AT # do nothing, print OK +++AT MODE # print current opmode @@ -33,8 +34,37 @@ The dynamic configuration commands are: +++AT RESET # software reset the unit ``` Upon success, all commands send back "OK" as their final output. Note that passwords may not contain spaces. For the softAP, the mode is fixed to AUTH_WPA_PSK. +Example session: +``` +user@host:~$ telnet 192.168.1.197 +Trying 192.168.1.197... +Connected to 192.168.1.197. +Escape character is '^]'. ++++AT MODE +MODE=3 +OK ++++AT AP +SSID=ESP_9E2EA6 PASSWORD= AUTHMODE=0 CHANNEL=3 +OK ++++AT AP newSSID password +OK ++++AT AP +SSID=newSSID PASSWORD=password AUTHMODE=2 CHANNEL=3 +OK ++++AT AP ESP_9E2EA6 +OK ++++AT AP +SSID=ESP_9E2EA6 PASSWORD= AUTHMODE=0 CHANNEL=3 +OK +^]c + +telnet> c +Connection closed. +``` +In order, this gets the current opmode. Good, it is 3 for STA + AP. Next, the current AP settings are retrieved. Next, the AP ssid is changed to newSSID and the authmode set to WPA and a password set. The AP settings are retrieved again to verify. Finally, the AP SSID is changed back to the original and by not using a password, the authmode is set to OPEN. + +**Cons:** -**Cons: ** * Unbuffered TCP writes. Each incoming UART character gets sent as a separate TCP packet. This could potentially impact performance, however, in my hands that hasn't been an issue.