Why Micropython?

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
Post Reply
robertcarell
Posts: 4
Joined: Thu Aug 12, 2021 10:13 pm

Why Micropython?

Post by robertcarell » Thu Aug 12, 2021 10:20 pm

Hi,

I have worked on python and used it in Raspberry Pi and I have recently learnt about this micropython.

So, I want to know what is it about and why a developer needs to use it?

When we have python and Arduino C, as Arduino is used for ESP8266 or NodeMCU but here I have seen that people are using micropython for ESP8266.

Thanks.

doublevee
Posts: 75
Joined: Mon Jul 02, 2018 11:09 pm

Re: Why Micropython?

Post by doublevee » Fri Aug 13, 2021 6:47 am

I will let one of the very many technical members reply with details, but I can tell you from my own experience that developing on microcontrollers using Micropython allows for much easier development and fast results.

I am not a programmer or a developer, but I have previously programmed simple programs onto micros using assembler and a little bit of C. The complexity and level of effort required meant I didn’t have the time to commit to such a task.

Fast forward a few years and Micropython has totally changed that and opened up a whole new area for people that would not normally program micro controllers, and definitely not with the scope and complexity that is covers.

Development is very fast as it’s all interpreted at run time and so debugging is easy and fast. Complex tasks have been extracted to such a high level that a few lines of code achieves a great deal.

Micropython is not fast in real world terms, but it is so powerful that the trade off in speed is more than acceptable. You can also drop into C or assembler if needed in parts as well.

In short, I have managed to achieve amazing results and develop a product using MP that I myself would have been unable to do otherwise.

The support on here is superb as well. For hobbyists and fast product development and potentially quick proof of concepts, I can’t see how it can be beaten.

The explosion in hugely capable micros and MP is a very attractive pairing for most.

User avatar
scruss
Posts: 360
Joined: Sat Aug 12, 2017 2:27 pm
Location: Toronto, Canada
Contact:

Re: Why Micropython?

Post by scruss » Fri Aug 13, 2021 4:50 pm

doublevee's answer is really good.
robertcarell wrote:
Thu Aug 12, 2021 10:20 pm
… Arduino is used for ESP8266 or NodeMCU
You know that horrible delay you get in the Arduino IDE while it compiles the code then uploads the huge binary to the ESP8266? You don't get that with MicroPython. Upload the image once, then the Python code are uploaded as tiny files. You can even save and run them directly from any editor like Thonny virtually instantly. It's a much nicer environment for experimenting than in Arduino. You get a REPL, either via serial or wifi.

Since ESP8266s are cheap, why not try it?

robertcarell
Posts: 4
Joined: Thu Aug 12, 2021 10:13 pm

Re: Why Micropython?

Post by robertcarell » Thu Aug 19, 2021 1:09 am

Thanks guys for such detailed responses. I am going to try micropython on Esp8266.

Post Reply