Home 0P3N Blog Micropython for Node MCU 8266
Ready to Start Your Career?
Create Free Account
By: mheboobkhan
February 9, 2018

Micropython for Node MCU 8266

By: mheboobkhan
February 9, 2018
By: mheboobkhan
February 9, 2018
 Hello guyz! Hope you all doing well, as we all know Python is an extraordinary emerging language.Which has a broad spectrum from CGI scripts to the embedded devices. As for embedded system we have a special version of the python called as MICROPYTHON . We can do many extraordinary things with this language , to explore this world of magic lets set our Node MCU in micropython mode .In this blog I am showing you a simple way to interact with micropython using 8266, there is an advanced way by using esplorer IDE. For now, we will use PuTTY for communicating with our node MCU .So let's start. For this , e will require the following software.1.Python 32.Putty3.Micropython firmware4.esptool (i will show how to install it in py3) I am considering you all have PY3 installed in your PC. So follow the steps below:>> Download>> Go to your python directory in my case its D:Python3Scripts>> Type on cmd cd  D:Python3Scripts then type following command>> pip install esptool

 Once its done it should look like this, then: >> We gotta install firmware on our node MCU>> Go to https://micropython.org/download site and download stable firmware, stable firmware best for the NOOBS like me :)>> then paste that file in the same directory D:Python3Scripts .>> Connect the Node MCU to the PC, note the COM port from devi manager.>> Then type following the cmd esptool.py --port COM4 --baud 11520 erase_flash to erase default LUA firmware.  

 >> Now type following esptool.py --port COM4 --baud 11520 write_flash --flash_size= detect -fm dio 0 esp8266-20171101-v1.9.3.bin>> Note here you have to adjust your port number 

>> Now open putty and set serial baud rate is equal to 115200 and you can run the python commands on this 

   So its done , We are ready to explore it , Happy hacking .....           
Request Demo

Build your Cybersecurity or IT Career

Accelerate in your role, earn new certifications, and develop cutting-edge skills using the fastest growing catalog in the industry