Skip to content

Latest commit

 

History

History
89 lines (60 loc) · 7.83 KB

esp8266.md

File metadata and controls

89 lines (60 loc) · 7.83 KB

ESP8266

Espressif (樂鑫), Ai-Thinker (安可信) ??

Module ??

新手上路 ?? {: #getting-started }

ESP-01 ??

ESP-01S ??

安裝設置 {: #setup }

macOS ??

  • Getting Started with ESP8266 Development on the Mac | lost+found #ril

    • 作者是軟體開發人員,沒有硬體的經驗,希望能直接在 Mac 上開發;許多有用的資訊來自 Kolban’s book on the ESP8266 (free)

    • 由於 ESP-01 跟麵包板不太合 (breadboard-friendly) -- 不方便把針腳分別接出來? 作者找到一塊 breadboard adapter。

    • 由於 ESP-01 不是 plug-and-play development board,所以需要 USB --> UART adapter,作者選用基於 CP2102 chipset 的 adpater,因為 macOS 有不錯的驅動程式;一再強調,要接 3.3v 的電源,接到 5v 可能會燒掉 ESP。

    • Assembly 看到作者把 USB --> UART adapter、ESP8266 (breadboard) adpater、breadboard 3.3v/5v power supply 全接上了,電源並非由 USB --> UART adapter 供應。

      接線時注意 Connect the USB adapter TX0 (transmit) pin to the RXD (receive) pin on the ESP8266. 及 Connect the USB adapter RX1 (receive) pin to the TXD (transmit) pin on the ESP8266. 總是將 TX 與 RX 對接。

      Connect the CHPD (?) pin of the ESP8266 to the positive rail (3.3v) on your bread board. 與 Connect the GP0 pin of the ESP8266 to the positive rail (3.3v) on your bread board, in order to boot the device on power up. [gray] Note that you will connect this spin to ground when it comes time to image the device. 最讓人不解??

    • 作者採用 USB to UART Bridge VCP Drivers | Silicon Labs,尤其 driver 是 sign 過的,值得信任。接上電腦後就能看到 /dev/tty.SLAB_USBtoUART/

      $ ls -l /dev/tty.SLAB_USBtoUART
      crw-rw-rw-  1 root  wheel   21,   6 Nov 29 23:21 /dev/tty.SLAB_USBtoUART
      $ kextstat | grep -i silabs # kernel module
        418    0 0xffffff7f83811000 0x9000     0x9000     com.silabs.driver.CP210xVCPDriver (5.0.6) CB447773-056A-33AD-B00C-C66884C66223 <141 22 4 3>
      

      在 About This Mac > System Report... > Hardware > USB 下也可以看到 CP2102 USB to UART Bridge Controller

    • The ESP8266 comes PRE-CONFIGURED WITH FIRMWARE that allows you to communicate over the USB-serial interface to the device, and send simple commands from the old and venerable AT command set, from the old days of modem communications. 作者用 minicom -- sudo minicom -D /dev/tty.SLAB_USBtoUART,一開始 ESP 先不要接電源,待進到 minicom 後再接電,就會看到 Ai-Thinker Technology Co.,Ltd. ... ready 的字樣,下 AT 要回 OK

  • 1. Getting started with MicroPython on the ESP8266 — MicroPython 1.9.3 documentation 提到 "built-in USB-serial convertor to make the UART available to your PC"

  • IOT : Using ESP8266 Programmer CH340G Chip Adapter-PART 1 - CodeKrypt (2016-10-26) 一個 USB 轉接器,可以把 ESP-01 直接插上去;也是強調要用 3.3V #ril

  • USB-UART 3.3V converter for WiFi ESP-01 module (PDF) 也是 USB 轉接頭 #ril

  • Playing With a ESP8266 WiFi Module · William Durand (2015-03-17) VCC needs 3.3V #ril

  • Getting Started with ESP8266 Development on the Mac | lost+found (2016-07-17) 用 minicom #ril

  • USB TO Uart -friDay購物 使用 CH340 晶片,可以切換 3.3V 及 5V。

  • Trouble with connecting CP2102 with ESP8266 - Everything ESP8266 CP2102 供電不足? #ril

  • 有人說,把 ~/.screenrc 改成 bindkey "\015" stuff "\015\012" (把 CR 改成 CRLF),就可以連上了?

參考資料 {: #reference }

社群:

學習資源:

相關:

  • esptool - ESP8266 bootloader 燒錄工具
  • NodeMCU - 採用 ESP8266 微處理器
  • MicroPython - MicroPython 官方直接提供 ESP8266 的韌體