ESP8266 详解
ANTIBili_MC
2018年07月15日 12:34

ESP8266 Overview | Espressif Systems

32 位 Tensilica 处理器

ESP8266EX 内置超低功耗 Tensilica L106 32 位 RISC 处理器,CPU 时钟速度最高可达 160 MHz,支持实时操作系统 (RTOS) 和 Wi-Fi 协议栈,可将高达 80% 的处理能力留给应用编程和开发。

低功耗

ESP8266EX 专为移动设备、可穿戴电子产品和物联网应用而设计,通过多项专有技术实现了超低功耗。ESP8266EX 具有的省电模式适用于各种低功耗应用场景。

高度集成

ESP8266EX 集成了 32 位 Tensilica 处理器、标准数字外设接口、天线开关、射频 balun、功率放大器、低噪放大器、过滤器和电源管理模块等,仅需很少的外围电路,可将所占 PCB 空间降低。

射频 balun:巴伦是平衡不平衡转换器的英文音译,原理是按天线理论,偶极 天线属平衡型天线,而同轴电缆属不平衡传输现,若将其直接连接, 则同轴电缆的外皮就有高频电流流过(按同轴电缆传输原理,高频电 流应在电缆内部流动,外皮是屏蔽层,是没有电流的),这样一来, 就会影响天线的辐射(可以想象成电缆的屏蔽层也参与了电波的辐射)。 因此,就要在天线和电缆之间加入平衡不平衡转换器,把流入 电缆屏蔽层外部的电流扼制掉,也就是说把从振子流过电缆屏蔽层外 皮的高频电流截断。要达到这样的目的有很多种办法,一种是高频开 路法,在电缆屏蔽层外皮四分之一波长处接一个四分之一波长的套筒 (等于效四分之一波长的开路线),因四分之一波长开路线对该频率 视为开路,达到截断高频电流的作用,这种办法,工作带宽窄,频率 低时四分之一波长套筒就显得很长,适合大功率高频率使用。另一种 是抵消法,想办法使流入的电流大小相等方向相反而互相抵消,应用 较多的用磁环三线绕的平衡不平衡转换器就属这种,这种频带较宽, 使用但大功率时受磁环磁饱和的限制,适合低频率小功率使用。再一 种是变压器法,通过高频变压器实现平衡不平衡转换,原理就像推挽 输出变压器一样,把双向平衡电流变换成但向不平衡电流。变压器可 采用磁心或空心绕成,适用大功率使用。还有一种是抑制法,振子经 过一高频扼流圈接电缆屏蔽层外皮,阻止高频电流流向电缆屏蔽层外 皮,此法比较简单,就是把电缆绕十圈左右,绕在磁环上更好,空心 也没关系,一般是频率低绕多几圈,频率高小绕几圈。但抑制效果没 有前述几种好,因此前面几种多用于专业应用,这种业余应用较多。 要记住的是我们只是截断屏蔽层外皮的高频电流,并不是截断流向屏 蔽层的所有高频电流(要这样的话把振子和电缆皮断开就得了),高 频电流是在屏蔽层的里面流的。形象一点可以把电缆想象成水管,本 来应该是水都在水管里流,如不加巴伦,水不单在水管里流,而且有 一部分还流到管子的外皮。巴伦的作用就是防止跑、冒、滴、漏,迫 使水都在水管里流,难言之隐,一用了之! 倒v天线的制作, 一是要求架设得尽量高,二是架设的地方要尽 量开阔,三是尽量远 离干扰源架设。 天线振子hf用一般的电源线(俗称花线)就行,有绝缘皮或裸铜 线都影响不大,线选粗一点可提高机械强度和辐射效率(效果并不十 分明显,理论上的事),通过修剪振子的长度使天线与电缆匹配(这 一步效果是很明显的,值得认真去做)。 vhf可用铝管或铜管,管子 的大小视机械强度而定,当然是粗一点有利。                                                    

他的来历是这样的,由于其完成由单端传输变换为差分传输之间的变换,所以称为平衡-不平衡变换器即Balance-Unbalance,但是英文太长就缩写为了: Balun,音译为巴伦,于是得名.

低噪声放大器: 噪声系数很低的放大器。一般用作各类无线电接收机的高频或中频前置放大器,以及高灵敏度电子探测设备的放大电路。

Tensilica 处理器:Tensilica 是一个迅速成长的公司,公司主要产品是在专业性应用程序微处理器上, 为现今高容量嵌入式系统提供最优良的解决方案。 公司成立于1997年7月。

美国泰思立达(Tensilica)日前推出了完成定制作业的钻石系列标准处理器内核系列(Diamond Standard Processor Core)”。该公司过去提供的是可追加指令集的Xtensa系列处理器内核,一直在开拓与英国ARM和美国MIPS科技等公司标准处理器内核不同的市场。

两种途径扩大亚洲潜在客户

随着该系列处理器内核的上市,Tensilica创始人、总裁兼首席执行官Chris Rowen表示“将与ARM和MIPS在市场上展开正面交锋”。Rowen介绍,此次的钻石系列虽说产品架构基本上与Xtensa相同,但将根据特定用途定制后,再提供给客户。过去的Xtensa已被北美和日本高级客户所采用,而钻石系列的目标是在日本以外的亚洲其他地区,在短时间内就需要解决方案的客户。

此次发布的系列包括从面积紧凑的低功耗通用控制器到高性能DSP等6款现货供应的可综合内核。钻石系列标准处理器拥有一套经过优化的软件开发工具和广泛的工业界合作伙伴的支持。用户可以直接从Tensilica公司或者通过其不断增加的ASIC和Foundry合作伙伴那里获得钻石系列标准处理器内核。

该公司将利用钻石系列标准处理器内核,通过两种途径扩大其潜在客户。首先,钻石系列标准处理器内核将由领先的ASIC和Foundry提供商分销,Tensilica从而可以接触到更广泛潜在客户;其次,Tensilica通过提供针对其他竞争的处理器内核更低价格、高性能和低功耗的组合扩充潜在客户拥有量。

Chris Rowen指出,“几年前,Tensilica还是一个年轻的公司,处理器结构尚未经验证,我们还不能开始这个产品线。如今,我们在众多市场领域拥有超过80家稳定客户群,而且主流的设计者一直要求其ASIC提供商提供Tensilica的处理器。对于新的ASIC和Foundry分销渠道来说,钻石系列标准处理器内核最为理想。基于Tensilica现有的上百个设计,我们相信预先配置好的这些内核是满足市场的多种主要应用领域的需求的。”

钻石系列以低功耗、低价格为优势

Tensilica公司关注到手机、打印机以及其他消费和通信类设备中SoC量产所带来的Xtensa内核的显著出货量。在此类设备中,Tensilica公司处理器内核不仅能够完成传统的RISC控制功能,还能实现高性能、低功耗的计算功能,在此之前,这些计算功能仅能依靠开发高风险、复杂的RTL(寄存器传输级)逻辑模块来实现。

此次发布6种内核中,4类为控制器类,将与ARM内核直接竞争。其余2类则为DSP类内核。据介绍,钻石系列相对于ARM内核的优点在于“低耗电量和低价格”。比如,钻石系列控制器类低端产品(108Mini)的授权费为7.5万美元,“约为同等性能ARM内核的1/3”。另外,控制器类高端产品(570T)的耗电量据称约为同等性能的ARM1136JF的1/3。

对Tensilica来说,进入“用户不做定制的内核”市场是一项重大举措。目前,宣布支持该内核的ASIC厂商包括美国NEC电子。

https://www.espressif.com/sites/default/files/documentation/esp-wroom-02d_esp-wroom-02u_datasheet_en.pdf

The ESP8266EX integrates a Tensilica L106 32-bit RISC processor, which achieves extra-

low power consumption and reaches a maximum clock speed of 160 MHz. The Real-Time

Operating System (RTOS) and Wi-Fi stack allow 80% of the processing power to be

available for user application programming and development. The CPU includes the

interfaces as below:

Programmable RAM/ROM interfaces (iBus), which can be connected with memory

controller, and can also be used to visit flash.

Data RAM interface (dBus), which can connected with memory controller.

AHB interface which can be used to visit the register.

性能稳定

ESP8266EX 的工作温度范围大,且能够保持稳定的性能,能适应各种操作环境。

The ESP8266 is a low-cost Wi-Fi microchip with full TCP/IP stack and microcontroller capability produced by Shanghai-based Chinese manufacturer, Espressif Systems.[1]

The chip first came to the attention of western makers in August 2014 with the ESP-01  module, made by a third-party manufacturer, Ai-Thinker. This small  module allows microcontrollers to connect to a Wi-Fi network and make  simple TCP/IP connections using Hayes-style  commands. However, at the time there was almost no English-language  documentation on the chip and the commands it accepted.[2]  The very low price and the fact that there were very few external  components on the module which suggested that it could eventually be  very inexpensive in volume, attracted many hackers to explore the  module, chip, and the software on it, as well as to translate the  Chinese documentation.[3]

The ESP8285 is an ESP8266 with 1 MiB of built-in flash, allowing for single-chip devices capable of connecting to Wi-Fi.[4]

The successor to these microcontroller chips is the ESP32.

Contents

  • 1 Features

  • 2 PinOut of Version-01

  • 3 SDKs

  • 4 Espressif modules

  • 5 Ai-Thinker modules

  • 6 Other boards

  • 7 See also

  • 8 References

  • 9 External links

Features

 ESP-01 wireframe.

  • Processor: L106 32-bit RISC microprocessor core based on the Tensilica Xtensa Diamond Standard 106Micro running at 80 MHz†

  • Memory:

    • 32 KiB instruction RAM

    • 32 KiB instruction cache RAM

    • 80 KiB user data RAM

    • 16 KiB ETS system data RAM

  • External QSPI flash: up to 16 MiB is supported (512 KiB to 4 MiB typically included)

  • IEEE 802.11 b/g/n Wi-Fi

    • Integrated TR switch, balun, LNA, power amplifier and matching network

    • WEP or WPA/WPA2 authentication, or open networks

  • 16 GPIO pins

  • SPI

  • I²C (software implementation)[5]

  • I²S interfaces with DMA (sharing pins with GPIO)

  • UART on dedicated pins, plus a transmit-only UART can be enabled on GPIO2

  • 10-bit ADC (successive approximation ADC)

† Both the CPU and flash clock speeds can be doubled by  overclocking on some devices. CPU can be run at 160 MHz and flash can be  sped up from 40 MHz to 80 MHz.[citation needed] Success varies chip to chip.[citation needed]  

PinOut of Version-01

 esp v-1 pinout

The Pinout is as follows for the 1st basic module,

  1. VCC, Voltage (+ 3.3 V (upto 3.6 V it can handle))

  2. GND, Ground (0 V)

  3. RX, Receive data bit X

  4. TX, Transmit data bit X

  5. CH_PD, Chip Power Down

  6. RST, Reset

  7. GPIO 0, General Purpose Input-Output No. 0

  8. GPIO 2, General Purpose Input-Output No. 2

SDKs

In late October 2014, Espressif Systems released a software development kit (SDK) for programming the chip directly which removed the need for a separate microcontroller.[6]  Since then, there have been many official SDK releases from Espressif;  Espressif maintains two versions of the SDK – one that is based on FreeRTOS and the other based on callbacks.[7]

An alternative to Espressif's official SDK is the open source ESP-Open-SDK[8] that is based on the GCC  toolchain. ESP8266 uses the Cadence Tensilica L106 microcontroller and  the GCC toolchain is open-sourced and maintained by Max Filippov.[9] Another alternative is the "Unofficial Development Kit" by Mikhail Grigorev.[10][11]

Other SDKs (mostly open source) include:

  • NodeMCU – A Lua-based firmware.

  • Arduino  – A C++ based firmware. With this core, the ESP8266 CPU and its Wi-Fi  components can be programmed like any other Arduino device. The ESP8266  Arduino Core is available through GitHub.

  • Sming - An actively developed asynchronous C/C++ framework with superb performance and multiple network features.

  • PlatformIO (https://platformio.org/platforms/espressif8266) – A cross-platform IDE and unified debugger which sits on top of Arduino code and libraries.

  • MicroPython – A port of MicroPython (an implementation of Python for embedded devices) to the ESP8266 platform.

  • ESP8266 BASIC – An open source basic interpreter specifically  tailored for the internet of things. Self hosting browser based  development environment.

  • Zbasic for ESP8266 – A subset of Microsoft's widely used Visual  Basic 6 which has been adapted as a control language for the ZX  microcontroller family and the ESP8266.

  • Espruino – An actively maintained JavaScript SDK and firmware, closely emulating Node.js. Supports a few MCUs, including the ESP8266.

  • Mongoose OS – An open source Operating System for connected products. Supports ESP8266 and ESP32. Develop in C or JavaScript.[12]

  • ESP-Open-SDK – Free and open (as much as possible) integrated SDK for ESP8266/ESP8285 chips.

  • ESP-Open-RTOS – Open source FreeRTOS-based ESP8266 software framework.

  • Zerynth – IoT framework for programming ESP8266[13] and other microcontrollers in Python.

Espressif modules

This is the series of ESP8266-based modules made by Espressif:

NameActive pinsPitchForm factorLEDsAntennaShieldedDimensions (mm)NotesESP-WROOM-02[14] 181.5 mm2×9 castellatedNoPCB traceYes18 × 20FCC ID 2AC7Z-ESPWROOM02.ESP-WROOM-02D[15] 181.5 mm2×9 castellatedNoPCB traceYes18 × 20FCC ID 2AC7Z-ESPWROOM02D. Revision of ESP-WROOM-02 compatible with both 150-mil and 208-mil flash memory chips.ESP-WROOM-02U[15] 181.5 mm2×9 castellatedNoU.FL socketYes18 × 20Differs from ESP-WROOM-02D in that includes an U.FL compatible antenna socket connector.ESP-WROOM-S2[16] 201.5 mm2×10 castellatedNoPCB traceYes16 × 23FCC ID 2AC7Z-ESPWROOMS2.

In the table above (and the two tables which follow), "Active pins"  include the GPIO and ADC pins with which you can attach external devices  to the ESP8266 MCU. The "Pitch" is the space between pins on the  ESP8266 module, which is important to know if you are going to  breadboard the device. The "Form factor" also describes the module  packaging as "2 × 9 DIL", meaning two rows of 9 pins arranged "Dual In  Line", like the pins of DIP ICs. Many ESP-xx modules include a small  on-board LED which can be programmed to blink and thereby indicate  activity. There are several antenna options for ESP-xx boards including a  trace antenna, an on-board ceramic antenna, and an external connector  which allows you to attach an external Wi-Fi antenna. Since Wi-Fi  communications generates a lot of RFI (Radio Frequency Interference),  governmental bodies like the FCC like shielded electronics to minimize  interference with other devices. Some of the ESP-xx modules come housed  within a metal box with an FCC seal of approval stamped on it. First and  second world markets will likely demand FCC approval and shielded Wi-Fi  devices.[citation needed]

Ai-Thinker modules

 Ai-Thinker ESP8266 modules (ESP-12F, black color) soldered to breakout boards (white color)

This is the first series of modules made with the ESP8266 by the third-party manufacturer Ai-Thinker and remains the most widely available.[17]  They are collectively referred to as "ESP-xx modules". To form a  workable development system they require additional components,  especially a serial TTL-to-USB adapter (sometimes called a USB-to-UART  bridge) and an external 3.3 volt power supply. Novice ESP8266 developers  are encouraged to consider larger ESP8266 Wi-Fi development boards like  the NodeMCU  which includes the USB-to-UART bridge and a Micro-USB connector coupled  with a 3.3 volt power regulator already built into the board. When  project development is complete, those components are not needed and  these cheaper ESP-xx modules are a lower power, smaller footprint option  for production runs.

In the Notes column, Flash memory sizes apply to the given module  and all those below it in the table. Exceptions which apply to a single  module are shown in ().

NameActive pinsPitchForm factorLEDsAntennaShieldedDimensions (mm)NotesESP-0160.1 in2×4 DILYesPCB traceNo14.3 × 24.8512 KiB FlashESP-01S60.1 in2×4 DILYesPCB traceNo14.4 × 24.7(1 MiB Flash)ESP-01M161.6 mm2×9 edge connectorNoPCB traceYes18.0 × 18.0Uses ESP8285 (1 MiB built-in flash)ESP-0260.1 in2×4 castellatedNoU.FL socketNo14.2 × 14.2 ESP-03102 mm2×7 castellatedNoCeramicNo17.3 × 12.1 ESP-04102 mm2×4 castellatedNoNoneNo14.7 × 12.1 ESP-0530.1 in1×5 SILNoU.FL socketNo14.2 × 14.2 ESP-0611various4×3 diceNoNoneYes14.2 × 14.7Not FCC approved.ESP-07142 mm2×8 pinholeYesCeramic + U.FL socketYes20.0 × 16.0Not FCC approved.ESP-07S142 mm2×8 pinholeNoU.FL socketYes17.0 × 16.0FCC and CE approved.ESP-08102 mm2×7 castellatedNoNoneYes17.0 × 16.0Not FCC approved.ESP-0910various4×3 diceNoNoneNo10.0 × 10.0 ESP-1032 mm1×5 castellatedNoNoneNo14.2 × 10.0 ESP-1161.27 mm1×8 pinholeNoCeramicNo17.3 × 12.1 ESP-12142 mm2×8 castellatedYesPCB traceYes24.0 × 16.0FCC and CE approved.[18] ESP-12E202 mm2×8 castellatedYesPCB traceYes24.0 × 16.04 MiB flash.ESP-12F202 mm2×8 castellatedYesPCB traceYes24.0 × 16.0FCC and CE approved. Improved antenna performance.ESP-12S142 mm2×8 castellatedYesPCB traceYes24.0 × 16.0FCC approved.[19] ESP-13161.5 mm2×9 castellatedNoPCB traceYesW18.0 × L20.0Marked as "FCC". Shielded module is placed sideways, as compared to the ESP-12 modules.ESP-14222 mm2×8 castellated +6NoPCB traceYes24.3 × 16.2

Other boards

The  reason for the popularity of many of these boards over the earlier  ESP-xx modules is the inclusion of an on-board USB-to-UART bridge (like  the Silicon Labs' CP2102 or the WCH CH340G) and a Micro-USB connector,  coupled with a 3.3 volt regulator to provide both power to the board and  connectivity to the host (software development) computer – commonly  referred to as the console. With earlier ESP-xx modules, these two items  (the USB-to-Serial adaptor and the regulator) had to be purchased  separately and be wired into the ESP-xx circuit. Modern ESP8266 boards  like the NodeMCU  are easier to work with and offer more GPIO pins. Most of the boards  listed here are based on the ESP-12E module, but new modules are being  introduced seemingly every few months.

NameActive pinsPitchForm factorLEDsAntennaShieldedDimensions (mm)NotesBolt IoT140.1 in2×14 DILYesPCB traceYes30 × 40Comes with an onboard SD card and features like Lib-Discovery and Fail Safe Mode. Has its own cloud for IoT.Olimex MOD-WIFI-ESP8266[20] 20.1 inUEXT moduleYesPCB traceNo?Only RX/TX are connected to UEXT connector.Olimex MOD-WIFI-ESP8266-DEV[21] 200.1 in2×11 DIL + castellatedYesPCB traceNo33 × 23All available GPIO pins are connected, also has pads for soldering UEXT connector (with RX/TX and SDA/SCL signals).NodeMCU DEVKIT140.1 in2×15 DILYesPCB traceYes49 × 24.5Uses the ESP-12 module; includes USB to serial interface.Adafruit Huzzah ESP8266 breakout[22] 140.1 in2×10 DILYesPCB traceYes25 × 38Uses the ESP-12 module.SparkFun ESP8266 Thing[23] WRL-13231120.1 in2×10 DILYesPCB trace + U.FL socketNo58 × 26FTDI serial header, Micro-USB socket for power, includes Li-ion battery charger.KNEWRON Technologies smartWIFI[24] 120.1 in2×20 DILYes 1 RGBPCB traceYes25.4 × 50.8CP2102 USB bridge, includes battery charger, micro-USB socket for  power and battery charging, 1 RGB LED and USER / Reflash button.DoIT ESPduino[25]120.1 inArduino UnoYesPCB traceYes53.4 × 68.6Uses the ESP-WROOM-02 (ESP-13) module and Mini-USB port. Fully compatible with Arduino Uno shields.WeatherPlus - SwitchDoc Labs[26]26+Grove0.1 inCustomYesPCB traceYes86.0 × 50.0Uses the AI Thinker Model ESP8266MOD (ESP-13) module and FTDI for  Programming and Mini-USB port for power. Fully compatible with Adafruit  Huzzah software.  Includes BMP280 Barometer, ADS1115 and Grove I2C  connectors.   Plugs for Anemometer/Wind Vane/Rain Bucket.WeMos[27] D1[28]120.1 inArduino UnoYesPCB traceYes53.4 × 68.6Uses the ESP-12F module and Micro-USB socket. Discontinued in favor of WeMos D1 R2.WeMos[27] D1 R2[29] 120.1 inArduino UnoYesPCB traceYes53.4 × 68.6Uses ESP-12F module and has Micro-USB socket.WeMos[27] D1 mini[30] 120.1 in2×8 DILYesPCB traceYes25.6 × 34.2Uses ESP-12S module and has Micro-USB socket.WeMos[27] D1 mini Lite[31] 120.1 in2×8 DILYesPCB traceYes25.6 × 34.2Based on the ESP8285, an ESP8266 with 1 MiB flash built-in; has Micro-USB socket.WeMos[27] D1 mini Pro[32] 120.1 in2×8 DILYesCeramic and U.FL socketYes25.6 × 34.2Uses ESP8266EX chip; has Micro-USB socket, U.FL antenna connector, and 16 MiB flash.ESPert ESPresso Lite[33] 160.1 in2×8 DILYesPCB traceYes26.5 × 57.6Uses the ESP-WROOM-02 module. Produced in limited quantity as beta version.ESPert ESPresso Lite V2.0[34] 240.1 in2×10 DILYesPCB traceYes28 × 61Improved version of ESPresso Lite.In-Circuit ESP-ADC[35] 180.1 in2×9 DILNoU.FL socketYes22.9 × 14.9Uses ESP8266EX chip.Watterott ESP-WROOM02-Breakout[36] 140.1 in2×10 DILYesPCB traceYes40.64 × 27.94Uses the Espressif ESP-WROOM-02 module.Geek Wave Solution IOT WROOM-02 Dev. Board[37] 200.1 in?YesPCB traceYes93.80 × 80.02Development board with Espressif ESP-WROOM-02 module and four relays.