Dynamic languages for embedded devices? [closed]

ぃ、小莉子 提交于 2019-12-05 01:47:40

问题


I need to deploy a dynamic language to a small embedded Linux device, and have difficulty finding the right one: I want to build a small web-application with this language (with a small framework like Sinatra or Camping ) and write some scripts for maintenance.

I would prefer Ruby, as I have some experience in it, but after several days of trying to cross-compile it, I could only build the barebone interpreter, without the libs (miniruby). The problem with it is, that it's just Too Damn Large: more than 1 MB stripped!

What language are you using, and how difficult was it to get it working?


回答1:


I don't use it personally but lua has a very small footprint.




回答2:


Dynamic languages are very, very hard to minify. Perhaps tinypy will give you some inspiration for squeezing out more.




回答3:


I am investigating this myself, and I have found some interesting candidates:

  • eLua - An implementation of Lua specifically for embedded devices.
  • p14p - Python on a chip.
  • Forth - Good old Forth, what more can I say?



回答4:


I'm using ruby 1.8.7 on a Techbase NPE GPRS modem. It has a 180MHz ARM processor, and has a lot of services already on it (eg Apache, embedded PostgreSQL). Works fairly well, but you need to be aware of a few issues with ruby on it (eg Timeout can cause ruby to SegFault).

Planning to move up to ruby1.9 later in the year...



来源:https://stackoverflow.com/questions/2714557/dynamic-languages-for-embedded-devices

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!