ESP8266 Support WIKI

User Tools

Site Tools


setup-windows-compiler-esp8266

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
setup-windows-compiler-esp8266 [2015/04/10 19:56]
admin
setup-windows-compiler-esp8266 [2018/02/17 19:49]
dcm684 Emphasized prebuilt download
Line 3: Line 3:
 ===== Visual Studio IDE ===== ===== Visual Studio IDE =====
  
-This document will allow you to develop native ​'C' ​firmware applications for the ESP8266 using Windows. You can setup your development environment using Microsoft ​DevStudio ​IDE. Using the accompanying serial terminal and flash writer application,​ you will be able to edit compile, link, flash and run without ever needing to leave the IDE. +This document will allow you to develop native C/C++ firmware applications for the ESP8266 using Windows. You can setup your development environment using Microsoft ​Visual Studio ​IDE. Using the accompanying serial terminal and flash writer application,​ you will be able to edit compile, link, flash and run without ever needing to leave the IDE. You can download [[https://​www.visualstudio.com/​free-developer-offers/​|Microsoft Visual Studio Comunity]] for free. If you want to setup environment manually ​(more controlplease refer to Toolset installation sectionOtherwise ​you can use [[http://bbs.espressif.com/viewtopic.php?f=7&t=3577|ESP8266 Wizard]].
- +
-==== Connecting the board ==== +
- +
- +
-The ESP8266 runs on 3.3V and is NOT 5V TOLERANT, so you cannot just connect it to an ArduinoAs the chip can draw up to 300mA when transmitting,​ you will need a good power supply. If in doubt, use a large capacitor ​(>100uf) to regulate the supply, near the chipFailure to do so will result in instability. +
- +
-Since the firmware is uploaded through the serial interface, ​you will typically ​use a USB to serial adapter. Here is the one I use: +
- +
-[[http://www.ebay.ca/itm/​FT232RL-USB-Serial-TTL-level-5V-3-3V-Module-Converter-Adapter-Arduino-/​181140044590?pt=LH_DefaultDomain_0&hash=item2a2cc9bb2e|FT232RL Adapter]] +
- +
-Make sure you get one that works at 3V or with a 3V/5V switch, like this one. +
- +
-{{ :​esp8266b3.png?​nolink |}} +
-//ESP-01 Hardware connections//​ +
- +
-To get the chip into firmware update mode, the chip needs to be reset while GPIO0 is held low and GPIO2 is held high. The above circuit uses the USB-serial adapter'​s DTR line to pull GPIO0 low and reset the chip via a small capacitor. GPIO0 needs to be held down for about 15ms after reset for the chip to go into firmware update mode. After that, GPIO0 needs to be released, as the bootloader then reconfigures GPIO0 as an output. All of this is handled automatically by the flash tool.+
  
 +You can also use a [[http://​visualgdb.com/​|third-party plugin]] to [[http://​visualgdb.com/​tutorials/​esp8266/​|setup building and debugging automatically]].
  
 ==== Toolset installation ==== ==== Toolset installation ====
Line 28: Line 13:
  
 This particular version of the toolset is designed to work under Windows 7 or 8, 32 or 64bit. ​ This particular version of the toolset is designed to work under Windows 7 or 8, 32 or 64bit. ​
- +You can **[[http://​gnutoolchains.com/​esp8266/​|download]]** ​pre-built ESP8266 toolchain that contains Python and the ESP8266 SDK. Alternatively you can gather the necessary components manually:
-Here is step by step guide:+
  
   * Create a directory to put all your ESP stuff in. I put mine in **E:​\ESP8266**,​ but obviously yours will be different.   * Create a directory to put all your ESP stuff in. I put mine in **E:​\ESP8266**,​ but obviously yours will be different.
Line 35: Line 19:
   * You need **[[http://​pyserial.sourceforge.net/​|PySerial]]**.   * You need **[[http://​pyserial.sourceforge.net/​|PySerial]]**.
   * Get **[[http://​www.mingw.org/​|minGW]]**. In the package manager, choose **mingw-developer-toolkit** and **mingw-base**. This will give you **make.exe** and some important utilities, like **mkdir.exe** that the makefiles will need.   * Get **[[http://​www.mingw.org/​|minGW]]**. In the package manager, choose **mingw-developer-toolkit** and **mingw-base**. This will give you **make.exe** and some important utilities, like **mkdir.exe** that the makefiles will need.
-  * Get the **[[https://​github.com/​espressif/​esp_iot_rtos_sdk/​archive/​master.zip|sdk]]**. Install it under your chosen directory. Mine is in **E:​\ESP8266\esp_iot_rtos_sdk-master**.+  * Get the **[[https://​github.com/​espressif/​esp_iot_rtos_sdk/​archive/​master.zip|sdk]]**. Install it under your chosen directory. Mine is in **E:​\ESP8266\esp\_iot\_rtos\_sdk-master**.
   * Download the missing libraries for the SDK: **[[https://​github.com/​espressif/​esp_iot_rtos_sdk_lib/​archive/​master.zip|FreeRTOS libraries for SDK]]**. Add them to the **E:​\ESP8266\esp_iot_rtos_sdk-master\lib** directory.   * Download the missing libraries for the SDK: **[[https://​github.com/​espressif/​esp_iot_rtos_sdk_lib/​archive/​master.zip|FreeRTOS libraries for SDK]]**. Add them to the **E:​\ESP8266\esp_iot_rtos_sdk-master\lib** directory.
   * Get the **[[https://​drive.google.com/​file/​d/​0B1kVUQJ3na10RkhtRDE1UFZBVzg/​view?​usp=sharing|pre-built compiler]]**. Stick it in your chosen directory. Mine is in **E:​\ESP8266\xtensa-lx106-elf**.   * Get the **[[https://​drive.google.com/​file/​d/​0B1kVUQJ3na10RkhtRDE1UFZBVzg/​view?​usp=sharing|pre-built compiler]]**. Stick it in your chosen directory. Mine is in **E:​\ESP8266\xtensa-lx106-elf**.
Line 84: Line 68:
 [[http://​www.esp8266.com/​viewtopic.php?​f=9&​t=820|Eclipse IDE for ESP8266]] [[http://​www.esp8266.com/​viewtopic.php?​f=9&​t=820|Eclipse IDE for ESP8266]]
  
 +===== Arduino IDE =====
 + Go to Arduino site and download the IDE 
 +Unzip it wherever ​
 +Go to the ESP8266 libraries and follow the easy install
 +Lots of programms for you to try
  
 +[[http://​www.arduino.cc/​en/​Main/​Software|http://​www.arduino.cc/​en/​Main/​Software]]
 +https://​github.com/​esp8266/​Arduino
setup-windows-compiler-esp8266.txt · Last modified: 2018/02/25 04:12 by dcm684