Micropython as Arduino killer

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
User avatar
philwilkinson40
Posts: 59
Joined: Tue Nov 14, 2017 3:11 am
Location: Perth, Australia

Re: Micropython as Arduino killer

Post by philwilkinson40 » Sun Dec 09, 2018 4:58 am

pythoncoder wrote:
Sun Dec 02, 2018 7:42 am
philwilkinson40 wrote:
Tue Nov 27, 2018 12:16 pm
...
As for libraries, I think we all know that this is an area Micropython could improve. They tend to be scattered across github and the best option to find what you need is usually to search, then if needed post, in this forum!
Perhaps this interest is a trigger to pull together the libraries in a single place.
Phil
There is a distinction between official libraries and user-contributed ones. Official libraries are in one GitHub repo and bug reports can be raised there for attention by the MicroPython maintainers.

Obviously they can't be responsible for user contributed libraries which are indeed scattered around GitHub. Issues inevitably need to be raised there for attention by the author.

It's a few years since I used Arduino but my recollection is that the problem is largely fixed by the Wiki. That had pointers to user contributed libraries and was a great resource. I found it worked fine.

For some reason the MicroPython wiki is rather little-used. Some time ago I offered to remove the outdated content but Damien wasn't keen on the idea. It would be good if more library authors used it to promote their work.
Sorry Peter, I should have made my point regarding libraries clearer. Arduino IDE has a library manager which allows users a great interface to select modules. This creates a natural focal point where (nearly all) new libraries get loaded into and users can easily get immediate access to them. Of course Micropython does not have a single IDE, so this is not a fair comparison. I just wanted to make a comparison for users of Arduino coming to Micropython; they may find the number of libraries appear small, however many more exist (you just need to search to find them).

stijn
Posts: 335
Joined: Thu Apr 24, 2014 9:13 am

Re: Micropython as Arduino killer

Post by stijn » Sun Dec 09, 2018 8:46 am

philwilkinson40 wrote:
Sun Dec 09, 2018 4:58 am
Arduino IDE has a library manager which allows users a great interface to select modules.
Yeah they did that very well.

But MicroPython can theoretically have that as well via pip or upip. I think it's not yet in a state to use it as such though? It for sure works for modules in micropython-lib, but I'm not sure there's proper documentation both for users and library publishers, or how it's supposed to work with libraries which include C code.

kevinkk525
Posts: 411
Joined: Sat Feb 03, 2018 7:02 pm

Re: Micropython as Arduino killer

Post by kevinkk525 » Sun Dec 09, 2018 8:53 am

upip sounds great and should work perfectly for beginners. It should be better documented. The load of questions on this forum from newbies that don't even know how to load a library to their device is a bit too high.

Later on, nobody uses upip on esp8266 as you quickly run out of RAM with bigger modules like uasyncio.

bitninja
Posts: 115
Joined: Thu Sep 15, 2016 4:09 pm
Location: Spring, Texas

Re: Micropython as Arduino killer

Post by bitninja » Mon Dec 10, 2018 5:59 pm

You bring up a good point about frozen modules. I think we should focus on situations that do not require that modules be frozen into the firmware... and make that as painless as possible. upip is great for this, but I think there may be cases where it may not work... for instance, what about platforms without network access?

As a fallback, there probably should be a documented, manual process for installing a module.

pfalcon
Posts: 1155
Joined: Fri Feb 28, 2014 2:05 pm

Re: Micropython as Arduino killer

Post by pfalcon » Tue Dec 11, 2018 10:50 am

bitninja wrote:
Mon Dec 10, 2018 5:59 pm
As a fallback, there probably should be a documented, manual process for installing a module.
Why? Only cowards read the docs. http://docs.micropython.org/en/latest/r ... kages.html
Awesome MicroPython list
Pycopy - A better MicroPython https://github.com/pfalcon/micropython
MicroPython standard library for all ports and forks - https://github.com/pfalcon/micropython-lib
More up to date docs - http://pycopy.readthedocs.io/

Online
User avatar
Roberthh
Posts: 1468
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: Micropython as Arduino killer

Post by Roberthh » Tue Dec 11, 2018 12:00 pm

Ît cannot be said often enough:
The documentation of Micropython is good. It is reccomended for everyone to read it COMPLETELY even twice or thrice, to have an impression, what can be expected where is what. Thanks a lot to everyone who contributed, especially Paul, Damien, and Peter.

bitninja
Posts: 115
Joined: Thu Sep 15, 2016 4:09 pm
Location: Spring, Texas

Re: Micropython as Arduino killer

Post by bitninja » Tue Dec 11, 2018 5:46 pm

I agree the documentation is good... for MicroPython. The documentation you find for any particular module though will depend on the developer. If we are talking about helping new users find and add functionality, they will not find a homogeneous experience each time.

User avatar
pythoncoder
Posts: 3455
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: Micropython as Arduino killer

Post by pythoncoder » Wed Dec 12, 2018 1:19 pm

In addition to the approach to cross-installing pointed out by Paul, there is also micropip. This avoids the need to install the Unix build of MicroPython: you can download the package to your PC and copy it to the device by any means.

Micropip may be found here.
Peter Hinch

bitninja
Posts: 115
Joined: Thu Sep 15, 2016 4:09 pm
Location: Spring, Texas

Re: Micropython as Arduino killer

Post by bitninja » Wed Dec 12, 2018 4:03 pm

pythoncoder wrote:
Wed Dec 12, 2018 1:19 pm
Micropip may be found here.
Nice!
pythoncoder wrote:
Sun Dec 02, 2018 7:42 am
For some reason the MicroPython wiki is rather little-used. Some time ago I offered to remove the outdated content but Damien wasn't keen on the idea. It would be good if more library authors used it to promote their work.
I'd be willing to work on the wiki if anyone thinks it would be useful.

User avatar
mattyt
Posts: 224
Joined: Mon Jan 23, 2017 6:39 am

Re: Micropython as Arduino killer

Post by mattyt » Wed Dec 12, 2018 11:33 pm

pythoncoder wrote:
Wed Dec 12, 2018 1:19 pm
In addition to the approach to cross-installing pointed out by Paul, there is also micropip. This avoids the need to install the Unix build of MicroPython: you can download the package to your PC and copy it to the device by any means.
I somehow hadn't come across micropip before; that's really helpful, thanks Peter!
bitninja wrote:
Wed Dec 12, 2018 4:03 pm
I'd be willing to work on the wiki if anyone thinks it would be useful.
I'd certainly appreciate having up-to-date information on the wiki...so yes, I for one would think it would be useful. Worth noting that we also have the 'dev' wiki that also needs attention if we're going to keep it maintained...

One of the other tasks I need to do in the next week or two is to link to a bunch of useful MicroPython peripheral drivers; There's a start on the wiki and I am planning to extend it.

Post Reply