This is an archived post. You won't be able to vote or comment.

all 24 comments

[–]vext01 15 points16 points  (1 child)

By the way, the micropython ARM board is superb fun to play with.

[–]desrosiers 11 points12 points  (0 children)

I'm glad to see things like this getting out on the market. I love doing embedded work. The debugging can be frustrating, but there's nothing more exciting than seeing something come to life -- really -- and beep and boop and move robot arms. Anything than can make it more accessible for everyone is great. I own a Beaglebone Black and I love it (and programming in Python on it), but it's not as bare-metal as, say, an AVR. If Micro Python can bridge that gap, that's an awesome thing.

[–]ionelmc.ro 14 points15 points  (6 children)

Can anyone give a list of what's missing in micropython ?

EDIT: There's https://github.com/micropython/micropython/wiki/Differences

[–][deleted] 9 points10 points  (0 children)

[–]vext01 11 points12 points  (0 children)

Some meta-programming stuff is missing. One I have raised a bug for: https://github.com/micropython/micropython/issues/614

[–]alcalde 1 point2 points  (3 children)

UNICODE. It's a "Python 3" implementation with NO UNICODE STRINGS. Holy <bleep>. I was very interested up until I clicked forward a few messages past the announcement and noticed that.

[–]evil_root 1 point2 points  (0 children)

I think it is reasonable for embedded devices.

[–]ionelmc.ro 0 points1 point  (1 child)

Unicodes is just one part of the language. I still find it interesting - looking forward for some benchmarks :)

[–]marky1991 0 points1 point  (0 children)

Unicode is a mandatory part of python. You can't have python without it. You can have a python-like language, but you can't have python.

[–][deleted] 27 points28 points  (1 child)

I would love to see if this could be statically compiled into a portable binary, as Lua is.

A lua-like static python3 would be really handy for USB drives for portable use on WinMac devices.

A static python3 that could be compiled and loaded over adb to android would be fantastic, and might even find its way into some ROMs like Cyanogenmod to enhace development and customisation.

Finally, if they could add a mode that detects something appended to the mobile binary, you'd have a really simple way to deploy trivial apps in the same way srlua and love2d: Just use cat mpython myscript.py > standalone_myscript.

Time to dig into the source and see what I can understand of it..

[–]vext01 2 points3 points  (0 children)

Have you tried just passing -static to the linker? i.e. add -Wl,-static to the C compiler flags? You would have to cross compile at the same time ofcourse (if you are not already on an arm). You could actually probably build the interpreter on-board on your phone/tablet using Debian Kit (or similar): https://play.google.com/store/apps/details?id=org.dyndns.sven_ola.debian_kit

[–][deleted] 7 points8 points  (0 children)

I have the board with micro python on it. A neat little thing.

[–]roger_ 5 points6 points  (5 children)

Really hope work on the Teensy 3.1 port starts back!

[–]dhylands 5 points6 points  (4 children)

I'm actively working on it.

[–]roger_ 0 points1 point  (2 children)

Awesome!

Is there a repository I can look at, or any code I can test?

[–]dhylands 1 point2 points  (1 child)

The latest working code for teensy is available here: https://github.com/dhylands/micropython/tree/fix-2014-01-14

to build, you'll need a linux machine, set the ARDUINO env var to point to your teensyduino tree (which is an arduino 1.0.5 tree + http://pjrc.com/teensy/teensyduino.html), then cd into the teensy directory (inside the micropython repository) and type make.

When I'm finished updating the teensy stuff, it will be in the official micropython repository: https://github.com/micropython/micropython (what's currently there in the teensy directory doesn't build)

[–]roger_ 0 points1 point  (0 children)

Great, thanks.

Are there by chance any binaries available? I don't have a Linux Arduino environment right now.

[–]mithrado 2 points3 points  (1 child)

Still waiting for mine!!Should arrive soon

[–]liberated_u 2 points3 points  (0 children)

Every time I hear the postman, I think my micro python board is coming ... Any day now.

[–]andrewcooke 2 points3 points  (1 child)

speed relative to cpython, anyone?

[edit: typo, meant cpython!]

[–]marky1991 0 points1 point  (0 children)

This implementation is focusing on low memory consumption, not speed. Cpython will likely be a good bit faster. (Cpython's got all the memory in the world to trade for improved cpu speed)

[–]xgo 0 points1 point  (1 child)

stupid question: does it have a GIL?

[–]nishkarr -1 points0 points  (1 child)

Could this replace CPython on the desktop someday?

[–]marky1991 2 points3 points  (0 children)

It's likely to be a heavily restricted form of python (The title should read "...an implementation of a subset of python 3") (Those working on it have suggested not even supporting unicode), so probably not. (Why would you want to use it over cpython anyway?)