PyMite: where to start?

135 views
Skip to first unread message

Giorgio Zoppi

unread,
Feb 29, 2012, 8:55:25 AM2/29/12
to python-o...@googlegroups.com
Which controllor do you recomment to start? Are Fusion Asics supported?
Giorgio.


--
Quiero ser el rayo de sol que cada día te despierta
para hacerte respirar y vivir en me.
"Favola -Moda".

Dean Hall

unread,
Feb 29, 2012, 9:04:26 AM2/29/12
to python-o...@googlegroups.com
Without knowing your experience with microcontrollers, I recommend the mbed (mbed.org) with the LPC1768. I'm not familiar with Fusion Asics and I can't recall anyone offering a port, so I'd say it's not supported. However, porting the PyMite VM is very easy. There are only 7 C functions necessary to make a port and you can usually copy them from another platform and make minor adjustments.

One more thing: use code from the mercurial repository. The releases are very old and have known defects; many of which have been fixed.

!!Dean

> --
> You are subscribed to the "python-on-a-chip" (or p14p for short) Google Group.
> Site: http://groups.google.com/group/python-on-a-chip

Giorgio Zoppi

unread,
Feb 29, 2012, 9:15:33 AM2/29/12
to python-o...@googlegroups.com
Hi Dean,
Thanks. with PyMite you can do ADC and generate PWM for a motor for
example? PyMite has enough resources for a basic restful service?
Giorgio

Dean Hall

unread,
Feb 29, 2012, 9:19:54 AM2/29/12
to python-o...@googlegroups.com
At this time, only the mbed and PIC24/dsPIC ports have wrappers for microcontroller peripherals. Other ports can only do basic VM operations and read/print over a UART.

About your second question: it's not the PyMite VM that has the resources (RAM), it's the microcontroller. Lastly, I don't know what you mean by "resful service." Sounds like web development of which I have no experience. Although some others on this list have tried to serve pages from a microcontroller with an ethernet interface.

!!Dean

Giorgio Zoppi

unread,
Feb 29, 2012, 9:26:12 AM2/29/12
to python-o...@googlegroups.com
2012/2/29 Dean Hall <dwha...@gmail.com>:

> At this time, only the mbed and PIC24/dsPIC ports have wrappers for microcontroller peripherals.  Other ports can only do basic VM operations and read/print over a UART.
Ok thanks.

> About your second question: it's not the PyMite VM that has the resources (RAM), it's the microcontroller.  Lastly, I don't know what you mean by "resful service."  Sounds like web development of which I have no experience.  Although some others on this list have tried to serve pages from a microcontroller with an ethernet interface.

Yes. I will try.
Gracias,
Giorgio

Giorgio Zoppi

unread,
Mar 18, 2012, 3:05:42 PM3/18/12
to python-o...@googlegroups.com
Dear Dean,
I tried the current mercurial but i have this error:

../../vm/libpmvm_desktop64.a(float.o): In function `float_op':
/home/jo/python-on-a-chip/src/vm/float.c:145: undefined reference to `fmodf'
/home/jo/python-on-a-chip/src/vm/float.c:146: undefined reference to `powf'
collect2: ld returned 1 exit status

What happens if you need some realtime checks from the
microcontroller? For example boundaries situation, when an application
should be runtime otherwise crash the device who is going to control?
Giorgio.

Dean Hall

unread,
Mar 18, 2012, 3:45:55 PM3/18/12
to python-o...@googlegroups.com
The error looks like the math library was not linked. The output you've copied suggests you're running Linux and compiling for a 64-bit desktop. If you're not 64-bit, change the build command to ("make PLATFORM=desktop"), but that still won't fix this issue.

As you can see in src/platform/desktop64/Makefile on line 36, the command to link the math library exists. So I need more information. Please copy the entire text starting from the prompt where you type $make... until the error causes the exit.

!!Dean

Reply all
Reply to author
Forward
0 new messages