开发者

Fast interpreted language for memory constrained microcontroller

I'm looking for a fast interpreted 开发者_如何学JAVAlanguage for a microcontroller.

The requirements are:

  • should be fast (not crucial but would be nice)
  • should be light on data memory (small overhead <8KB, excludes program variable space)
  • preferably would be small in program size and the language would be compact
  • preferably, human readable (for example, BASIC)

Thanks!


Some AVR interpreters:

  1. http://www.cqham.ru/tbcgroup/index_eng.htm
  2. http://www.jcwolfram.de/projekte/avr/chipbasic2/main.php
  3. http://www.jcwolfram.de/projekte/avr/chipbasic8/main.php
  4. http://www.jcwolfram.de/projekte/avr/main.php
  5. http://code.google.com/p/python-on-a-chip/
  6. http://www.avrfreaks.net/index.php?module=Freaks%20Academy&func=viewItem&item_id=688&item_type=project
  7. http://www.avrfreaks.net/index.php?module=Freaks%20Academy&func=viewItem&item_id=626&item_type=project
  8. http://www.avrfreaks.net/index.php?module=Freaks%20Academy&func=viewItem&item_id=460&item_type=project


This is a bit generic: there are many kinds of Microcontrollers, and thanks to technologies like Jazelle, it is possible to run hardware-accelerated Java on Microcontrollers. (if... your microcontroller supports it)

For a generic answer: Forth is commonly referenced. But really, you need to be far more specific with your question.


Micro-controllers come in a vast variety of architectures. There are small 8-bit families, 32-bit families with simple architectures and 32-bit families with MMU support, suitable for running a modern OS. If you don't state which family you are targeted at, it is impossible to answer your question.

Anyway, for 8-bit families the best you can get is a BASIC variant. See Bascom for example. Note that this would be a compiler version of the "interpreted" language. If you actually want to have a runtime or an interpreter that will execute your code, then you most probably need to install an operation system in your microcontroller.


There were a variety of interpreted languages for small micros back in the late 1970's and 1980's. They seem to have mostly fallen out of fashion. I'd like to have a p-code based C compiler for the PIC18 that could coexist nicely with my other C compiler; for much of my code I'd be willing to accept a 100-fold slowdown for a 50% space reduction (so long as I could keep the important stuff in native code). I would think that would be achievable, but I'm not about to implement such a thing from scratch myself.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜