Noduino Quantum
(→Turtorial) |
(→Turtorial) |
||
第167行: | 第167行: | ||
* [[ESP32 RFID]] MFRC522 RFID (SPI interface), Using the Arduino IDE to compile and upload... | * [[ESP32 RFID]] MFRC522 RFID (SPI interface), Using the Arduino IDE to compile and upload... | ||
* [[ESP32 ADC]] ESP32 Onchip SAR ADC Turtorial | * [[ESP32 ADC]] ESP32 Onchip SAR ADC Turtorial | ||
+ | * [[ESP32 Partical]] Sharp GP2Y1010AU0F Particle Sensor support | ||
* [[ESP32 SSD1306]] OLED Screen Turtorial (I2C interface) | * [[ESP32 SSD1306]] OLED Screen Turtorial (I2C interface) | ||
2016年12月4日 (日) 00:31的版本
目录 |
1 Overview
- CP2102 USB to UART Chip
- ESP32 Bluetooth and WiFi SoC
- 40MHz Crystal (±10ppm, ±10ppm)
- 16MB SPI Flash
- 5V - 12V Power Supply
- FreeRTOS
- UART Baud rate is 115200
2 Flash mode
We use two types of 16MB SPI flash:
- Winbond W25Q128xxxx, Support mode: QIO / QOUT / DIO / DOUT; 80MHz / 40MHz
- MXIC 25L128xxx, Support mode: DIO / DOUT; 80MHz / 40MHz
3 Pin Map
We place the PIN map on the back of the board:
You guys can refer to this doc for more details: http://www.espressif.com/sites/default/files/documentation/esp32_chip_pin_list_en_0.pdf
4 Quick Start
4.1 USB2UART
Quantum use the CP2102 USB to UART chip, you need to install the driver firstly. Accessing following url to get your driver:
The default baud rate is 115200
4.2 Arduino
We have pushed the support of Quantum board into arduino-esp32. Following steps to try the arduino quickly:
- Install Arduino IDE
- Go to Arduino IDE installation directory:
$ cd /PATH/TO/Arduino $ cd hardware $ mkdir espressif $ cd espressif $ git clone git://github.com/espressif/arduino-esp32.git esp32 $ cd esp32/tools $ python get.py
- Restart Arduino IDE
Example: ESP32 RFID
4.3 ESP IDF
4.3.1 Linux
Please refer to: https://github.com/icamgo/esp-idf/blob/master/docs/linux-setup.rst
Simple steps:
$ sudo apt-get install git wget make libncurses-dev flex bison gperf python python-serial $ wget https://dl.espressif.com/dl/xtensa-esp32-elf-linux32-1.22.0-59.tar.gz $ mkdir -p toolchain $ tar zxf xtensa-esp32-elf-linux32-1.22.0-59.tar.gz -C toolchain $ export PATH=$PATH:`pwd`/toolchain/xtensa-esp32-elf/bin $ $ git clone --recursive git://github.com/icamgo/esp-idf.git $ export IDF_PATH=`pwd`/esp-idf $ cd esp-idf/examples/09_onchip_sensor $ make menuconfig $ make flash
4.3.2 MAC OS
Please refer to: https://github.com/icamgo/esp-idf/blob/master/docs/macos-setup.rst
4.3.3 Windows
Please refer to: https://github.com/icamgo/esp-idf/blob/master/docs/windows-setup.rst
4.4 Auto Reset
You need to press the RST buttom after uploading the firmware into flash. If you guys do not like to do this please patch the /path/to/esp-idf/components/esptool_py/esptool/esptool.py :
diff --git a/esptool.py b/esptool.py index 755f4cb..ff92c91 100755 --- a/esptool.py +++ b/esptool.py @@ -197,6 +197,12 @@ class ESPLoader(object): + '\xc0' self._port.write(buf) + def reset_to_app(self): + self._port.setDTR(False) + self._port.setRTS(True) + time.sleep(0.05) + self._port.setRTS(True) + """ Calculate checksum of a blob, as it is defined by the ROM """ @staticmethod def checksum(data, state=ESP_CHECKSUM_MAGIC): @@ -1421,7 +1427,6 @@ def dump_mem(esp, args): sys.stdout.flush() print 'Done!' - def write_flash(esp, args): """Write data to flash """ @@ -1503,6 +1508,7 @@ def write_flash(esp, args): if args.verify: print 'Verifying just-written flash...' verify_flash(esp, args, header_block) + esp.reset_to_app() def image_info(args):
Then Quantum can reset to run your app automatically after uploading the firmware into flash
5 Turtorial
- ESP32 Smartconfig Support WeChat Airkiss by default
- ESP32 JTAG Using a FT2232H breakout board to debug the kernel/core through JTAG/OpenOCD/GDB
- ESP32 Boot
- ESP32 RTC External Wakeup
- ESP32 RFID MFRC522 RFID (SPI interface), Using the Arduino IDE to compile and upload...
- ESP32 ADC ESP32 Onchip SAR ADC Turtorial
- ESP32 Partical Sharp GP2Y1010AU0F Particle Sensor support
- ESP32 SSD1306 OLED Screen Turtorial (I2C interface)
6 Peripherals
- ESP32 GPIO
- ESP32 I2C
- ESP32 SPI
- ESP32 CAN
- ESP32 I2S
- ESP32 RMII
- ESP32 Onchip Sensor read the onchip Temperature sensor and Hall sensor
- ESP32 ADC ESP32 Onchip SAR ADC
- ESP32 PWM LED PWM Controller
- ESP32 RMT IR Remote Controller
- ESP32 TSL2561 TSL2561 Digital Luminosity/Lux/Light Sensor (I2C interface)
- ESP32 BH1750 BH1750 Digital Light Sensor (I2C interface)
- ESP32 BMP180 BMP180 Barometric Pressure/Temperature/Altitude Sensor (I2C interface)
- ESP32 BMP085 BMP085 Barometric Pressure/Temperature/Altitude Sensor (I2C interface)
- ESP32 SHT2x SHT2X Digital Humidity & Temperature Sensor (I2C interface)
- ESP32 DHT21 DHT21(AM2301) Digital Temperature & Humidity Sensor
- ESP32 DHT11 DHT11 Digital Humidity & Temperature Sensor
- ESP32 PT1000 Using a 18-bit ADC MCP3421 (I2C interface)
- ESP32 Partical Sharp GP2Y1010AU0F Particle Sensor support
- ESP32 PCF8563 PCF8563 I2C RTC Chip (I2C interface)
- ESP32 SSD1306 OLED Screen (I2C interface)
- ESP32 RFID MFRC522 RFID (SPI interface)
7 ESP32 Arch
ESP32 block diagram:
ESP32 use two LX6 core which ISA is xtensa.
- Xtensa LX6 Core: http://ip.cadence.com/uploads/533/Cadence_Tensillica_Xtensa_LX6_ds-pdf
- Xtensa Instruction Set Architecture: http://0x04.net/~mwk/doc/xtensa.pdf
We plan to write the document of the xtensa architecture like the MIPS or SPARC
The Xtensa instruction set is designed to meet the diverse requirements of dataplane processing.
This 32-bit architecture features a compact 16- and 24-bit instruction set with modeless switching for maximum power efficiency and performance.
The base instruction set has 80 RISC instructions and includes a 32-bit ALU, up to 64 general-purpose 32-bit registers, and six special-purpose registers.
Using this instruction set, you can expect significant code size reductions that result in higher code density and better power dissipation.
8 Hardware
9 Reference
- For more information please refer to