[Tutor] python links

Mark Alexiuk malexiuk at gmail.com
Mon Dec 17 03:32:53 CET 2007

Hi All,

I have no experience using Python in an embedded application (industrial
microcontrollers) but I'm sure it can be done and feel that Python offers
many advantages for new OOP developers over C++.

I would appreciate any suggestions on embedded processors compatible with
Python or some variant and what libraries people find useful, such as
UnitTest and Logging.

What follows are some links and excerpts I found looking for information on
this topic.



*Open Embedded*

OpenEmbedded is a tool which allows developers to create a fully usable
Linux base for various embedded systems.



*Embedded Python*

Some modern *embedded* devices have enough memory and a fast enough CPU to
run a typical Linux-based environment, for example, and running CPython on
such devices is mostly a matter of compilation (or cross-compilation) and

Devices which could be considered as "*embedded*" by modern standards and
which can run tuned versions of CPython include the following:


   [image: [WWW]] Gumstix <http://www.gumstix.org/>

   FIC [image: [WWW]] Neo1973 <http://wiki.openmoko.org/wiki/Neo1973> ( [image:
   [WWW]] Python on OpenMoko <http://wiki.openmoko.org/wiki/Python>)

See also PythonForArmLinux <http://wiki.python.org/moin/PythonForArmLinux>and
Open*Embedded* <http://wiki.python.org/moin/OpenEmbedded>.


Python compilers are available for some popular microcontrollers.
Pyastra[1]<http://pyastra.sourceforge.net/>compiles for all Microchip
PIC12, PIC14 and PIC16 microcontrollers.
PyMite[2]<http://pymite.python-hosting.com/wiki/>compiles for "any
device in the AVR family that has at least 64 KiB program
memory and 4 KiB RAM". PyMite also targets (some) ARM microcontrollers.
Notice that these embedded Python compilers typically can only compile a
subset of the Python language for these devices.



PyMite: A Flyweight Python Interpreter for 8-bit Architectures


*George Belotsky is a software architect who has done extensive work on high
performance Internet servers as well as hard real time and embedded systems.
His technology interests include C++, Python and Linux.*

SOURCE: http://pythonology.org/success&story=carmanah

*Embedding Python with Boost.Python Part 1 *

Python has been called a language optimized for development speed. This puts
it in contrast with compiled languages like C and C++, which can be called
languages optimized for execution speed. This contrast between Python and
C/C++ often fuels a development methodology in Python circles: code the
application in Python, profile the application, and rewrite the performance
critical parts in C or C++. This makes the topic of developing hybrid
systems by extending Python very well covered in various Python


*Java Embedded Python*
Jepp embeds CPython in Java. It is safe to use in a heavily threaded
environment, it is quite fast and its stability is a main feature and goal.

Some benefits of CPython over Java-based languages:

   - Using the native Python interpreter may mean a massive speed
   improvement over Java-based languages.
   - Python is mature so authors needn't fear the interpreter will
   suddenly change widely-used features.
   - Access to the high quality Python modules, both native and
   - Compilers and assorted Python tools are as mature as the language.
   - Python is an ideal language for your business logic. It is easy to
   learn, eminently readable and generally immune to programming gotchas.

SOURCE: http://jepp.sourceforge.net/


In the DePython  (Deeply Embeddable Python) project we have created a
stripped-down version of Python  that provides a platform for implementing
embedded systems in the Python language.  Specifically the DePython system
provides the following advantages of Javatm:

   - absolutely free, even for commercial use (including resale),
   - small footprint (<200K)
   - easy maintenance of software: objects and methods can be replaced
   - reference counting garbage-collection giving more deterministic

Currently DePython runs on a Hitachi SH1 evaluation board with some extra
hardware.  The SH1 is a 32 bits RISC micro-controller running at 16Mhz.  T
he evaluation is equipped with 256Kb of RAM, 64Kb of ROM, two RS-232 ports,
and a number of I/O ports.

SOURCE: http://www.tucs.fi/magazin/output.php?ID=2000.N2.LilDeEmPy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20071216/2c8bfbe5/attachment.htm 

More information about the Tutor mailing list