News for hackers. Stuff that matters.
Re:Python-on-a-chip by jey on Wednesday June 09, 2010 @10:09PM (#1418942)
What's the motivation for this?
Re:Python-on-a-chip by coderdude on Wednesday June 09, 2010 @10:19PM (#1418963)
The ability to use Python (instead of C, C++, or some flavor of assembly) on small chips and microcontrollers.
Re:Python-on-a-chip by jey on Wednesday June 09, 2010 @11:54PM (#1419085)
That doesn't really answer the question. Why would one want to do that, and why's that worth the trouble?

"What's the motivation to make a chip that runs Python?" "To be able to run Python on a chip."

Re:Python-on-a-chip by rbanffy on Thursday June 10, 2010 @12:07AM (#1419104)
A computer nerd is a person who uses a computer in order to use a computer.

It's easier to do complicated things in a language like python than with C++. And it will never let you dereference a null pointer.

Re:Python-on-a-chip by coderdude on Thursday June 10, 2010 @12:13AM (#1419112)
Write once/run anywhere would be a motivation. By the looks of it you wouldn't be able to literally run just any script on the chips that you bring over from a desktop machine, but the amount of tweaking would be minimal I think.

Being able to use Python's standard library on a chip would be useful. It's a dynamic language so you can do things you couldn't do with C. It's type-safe and easy as all hell to use. The usual motivations for using Python apply here. It just uses more resources and is understandably slower to execute.

Re:Python-on-a-chip by viraptor on Thursday June 10, 2010 @12:45PM (#1420667)
Some objections:

Write once/run anywhere would be a motivation. - "Run anywhere" is not true for most desktop programs and definitely not true for embedded stuff. When you're at 64k, you usually don't even reuse stuff like display handling, because your PCB layout is different enough that you'd have to rewrite the i/o layer anyways. Or because you a specific way to get the data. Or...

I can't imagine much reasonable code reuse outside of standardised platforms like Arduino. Much less any "run anywhere" programs.

It's a dynamic language so you can do things you couldn't do with C - There's nothing in language X, that you cannot do in C.

Since it seems to be a google project, I guess they're just trying to create something that can be pushed onto Android, much like their own Java VM.

Re:Python-on-a-chip by dfox on Thursday June 10, 2010 @08:31AM (#1419822)
Running python VM on these platforms is certainly better than running there VM for some flavor of BASIC as is often done. Primary motivation for both is probably same as for dynamic languages on normal computers: easier programming.
Re:Python-on-a-chip by kwantam on Thursday June 10, 2010 @03:01PM (#1421229)
I'm not trying to pick a fight here, nor am I claiming you're wrong as such, but I think you have to actually justify the claim that programming a microcontroller in Python is "certainly better" than doing so in BASIC. An overwhelming number of microcontroller applications are extremely simple bits of control code; there's certainly an argument to be made that _not_ carrying around the trappings of a high-level language like Python is better.

"Better for x," it would seem, is the only type of argument that will be tenable. So, what's an application for a microcontroller that will actually make use of Python's various advantages over BASIC?

Re:Python-on-a-chip by gte910h on Thursday June 10, 2010 @09:25AM (#1419935)
Memory protection, ease of development, fantastic libraries and clarity all come to mind.
Re:Python-on-a-chip by xkenneth86 on Wednesday June 09, 2010 @10:51PM (#1419006)
Yeah! It's really awesome.