In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-04 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article will explain in detail how to build a MicroPython environment for you. The content of the article is of high quality, so the editor will share it for you as a reference. I hope you will have some understanding of the relevant knowledge after reading this article.
1. Introduction: I heard that there is a MicroPython who can run directly on the single-chip microcomputer, which makes me very interested. Looking up, MicroPython is a streamlined and efficient implementation of the Python 3 language, including a small portion of the Python standard library, optimized to run in microcontrollers and restricted environments. This is good, so you can combine Python with hardware. two。 Environment introduction 2.1. The hardware spent 26 yuan on a treasure to buy a small board, which is really cheap.
Add another Micro USB cable, one end connected to the board and the other plugged into the computer. 2.2. Software 1) PC Windows system, Python 2.7environment or Python 3.4and later, PuTTY serial port tools 2) build MicroPython environment on the board 3. Step 1 of setting up the environment: connect the USB cable to the computer and the board, and the PC identifies a virtual serial port. If the installation is unsuccessful, you will need a driver for CP2102. Step 2: install esptool, this tool is used to communicate with the ESP32 board to achieve MicroPython firmware burning, read and write memory and other functions. Itself it is open source, the project is located in https://github.com/espressif/esptool installation, what I use here is: pip install esptool remarks: esptool itself is based on Python, so before installation, you need to install Python on your computer, no longer described here, will not own Baidu, my computer installed Python 2.7. Step 3, execute the following instruction esptool.py-port COM3 erase_flash under the Windows DOS window to achieve the function of erasing all ESP32 Flash. Note: you need to change COM3 to the corresponding string of slogans on your computer. Step 4, download the latest stable version of firmware https://micropython.org/download/esp32/ from the following URL and execute: esptool.py-- chip esp32--port COM3 write_flash-z 0x1000 esp32-idf3-20191220-v1.12.bin the above process of downloading firmware will take some time. Running Hello World is equivalent to installing a Python environment for the ESP32 chip, just not that it is not a standard version of Python, because it runs on a microprocessor and is called MicroPython. Now it's time for Hello World. Step 1: connect the board through a serial debugging assistant, you can use tools such as PuTTY. Step 2: we can print out the Hello World. Directly tap the code: print ("Hello World!") Then as soon as I got back to the car, the result came out!
On how to build the MicroPython environment to share here, I hope that the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.