Sample ESP on Arduino for FlexiBoard V0.1.
It is working for me!
Some new steps and findings. Not sure what they are all . . . some may appear below . . . but here is what I have working.
View attachment FB_ESP_ARDUINO.zip
One sketch for TEENSY :: FB_ESP_FullProxy
One sketch for ESP :: FB_myWebServer
My Arduino 1.6.12 Tools menu looks like this with a stock 4MB ESP-12E:
If all the tools are installed per prior post you should be able to compile the FB_myWebServer.
Install and use TYQT - it shows you the COM# port easily and has a button to disable 'Serial' for Proxy Upload through Teensy.
{ Icon under Menu Bar labeled "Serial" is highlighted blue when Serial is monitored - CLICK that to disable Serial, Click again when not blue to enable - note hovering mouse highlights so move the mouse away to see this. }
Upload FB_ESP_FullProxy to your Teensy.
To SERIAL WIRE through Teensy :: PROGRAM on USB enter "P" ( Upper Case P ) - it will remind of this:
<<<PGoing to PGM MODE.
no more commands accepted:: RESTART TEENSY AFTER PROGRAM UPLOADED !!!!!
!!!!! >>>> DISABLE SERIAL MONITOR <<<<<<<<< !!!!!
>>>
You will need to enable 'Serial' in TYQT to see the output.
Restart the Teensy - TYQT has a "Reset" icon for this!
When Teensy comes up I do an "I" ( Upper Case I) - this will reset the ESP unit and have it Spew out the startup INFO like WiFi.localIP().
NOTE: The first time this may indicate something like this:
wifi config not set/found
General config applied
Wait for WiFi connection.
cannot connect to: MYSSID
Can not connect to WiFi station. Go into AP mode.
Soft AP started IP address: 192.168.4.1
I used my phone and connected to the AP 192.168.4.1 in this case and entered a device name and my WiFi SSID and Password - this is then stored on the ESP module in SPIFFS! I also told it to do NTP TIME and gave it my locale - the ESP starts up with LOCAL TIME KNOWN! On saving this it tells you to restart ESP. If entered properly it will connect to your SSID and then tell you the local IP. You can do that from TEENSY with "I" command to restart the ESP and have it show the startup text.
The ESP startup text is stored and can be displayed at any time with 'i' ( lower case I ) - If the Teensy was online before the ESP it will have this captured, the "I" command forces the ESP restart and resets the first info received to have this work!
The USB "?" command shows you a command line summary. Somethings may work - Possibly not ESTOP - the few pins connected to Teensy all seem to have special meaning - most freeze or reset the ESP.
AFTER THE FIRST WIRED UPLOAD ( takes FOREVER! ) - if you got through the above and all is well - you can now QUIT and restart your IDE. On power up the "Tools / Port" should now show a network location. For your next ESP ARDUINO upload you can selected this port and it will OTA UPLOAD your code FOUR to SIX times faster over WiFi and there is no Need to set pins or disable serial or WAIT! As long as you have not put any faulting code in your ESP sketch! This is the value of ESTOP - if it works { may need an external wire run to another pin from a free GPIO if it there is a conflict on GPIO_15 }
Thanks to KurtE - I found that exectuting the IDE a second time gives a unique instance - you can open the TEENSY sketch in the first IDE then execute the IDE EXE again ( not open a second sketch ) and the two will maintain unique TEMP directories and TOOLS settings and can be used alternatively!
ALWAYS WATCH the TOOLS settings for the ESP - if the MEMORY SPLIT on SPIFFS/CODE is ever changed you have to repeat too much of the above!
ALSO : YMMV: - for some reason my computer is trying to execute the .gz files on the ESP server - rather than having the ESP server run them and open the other pages! I have not found or tried the fix for this - it used to work. The alternative is to use the SPIFFS WRITE tool from your PC to flash over a directory contents to populate the ESP, or Manually upload the files USING BUILT IN FTP - but in either case the uncompressed source files are needed. I'm not sure what is going on here - there was a UTILITY HTML and other tools to adjust the CONFIG - now they are all .gz files I cannot use. I pulled them off and extracted them once and wrote them back - but I deleted what looked like duplicate .gz files and now the device won't start the webpage for me - so they must not have been duplicates. This was NOT like this before? There was a utility and an INDEX.html file that ran really cool stuff. I'll have to get back to this.
This is just posted here for now. Frank post questions/comments - or if it works put it on GitHub.