55246|2

6040

帖子

205

TA的资源

版主

楼主
 

What's the deal with iot.js and JerryScript [复制链接]

Node.js will soon be running on tiny low power chips.

iot.js is a Node.js compatible runtime being written by Samsung. The project is still in active development, is open source and Apache Licensed. It hasn't yet had a stable release but has been in development for over a year. It is built on a new JavaScript VM called JerryScript (named after Jerry Mouse) that they are also working on. Node.js is built on V8, and iot.js is built on JerryScript. The major goal of iot.js is to run Node code on low power devices.
JerryScript doesn't have a logo yet, so I made one:
The current hardware requirements for iot.js are around 350KB ROM and 100KB RAM. This is a huge difference compared with V8, the VM that Node.js is built on, which is notoriously memory hungry and doesn't run on devices with less than 64MB of RAM (the lowest power device I've seen running it is the Arduino Yun).
As you can
链接已隐藏,如需查看请登录或者注册
and the
链接已隐藏,如需查看请登录或者注册
, iot.js is a Node.js compatible JS + C runtime that binds to JerryScript.
The first two officially supported devices are the STM32F4-Discovery and the Raspberry Pi 2:
The exciting thing about this stuff is that it makes low power hardware more accessible to coders like me who know JS and can install modules from NPM but don't want to deal with C and compiled language tooling and debugging headaches.
I've done a number of projects with the Arduino which can't run Node but has great battery life, and the Raspberry Pi which can run Node but has poor battery life and requires Linux sysadmin skills to operate effectively. The Raspberry Pi (or any Linux machine) is totally overkill for a lot of the projects I'm interested in doing (e.g. a computer that lives on my bicycle, or on that sits in my garden measuring soil moisture levels). Low power node.js seems like the sweet spot for me - I can leverage the Node + NPM ecosystem to deploy stuff to hardware that can potentially run for weeks on a single charge.
In the future they will work on support for other devices (according to
链接已隐藏,如需查看请登录或者注册
), including the Intel Edison and Samsungs recently announced Artik 1.
Perhaps the closest thing to iot.js is Espruino, who both develop a custom JavaScript runtime as well as manufacture development boards like the Espruino Pico. The major difference between iot.js and Espruino is that Espruino is not Node.js compatible. The Espruino boards use a family of chips (STM32F4) that iot.js supports, so it should be possible to run iot.js on Espruino hardware in the future.
In addition to JerryScript and Espruino there is also Duktape which is "an embeddable Javascript engine, with a focus on portability and compact footprint". There is a project called
链接已隐藏,如需查看请登录或者注册
that combines Duktape and LibUV, which in the future could form the basis of a Node.js compatible runtime build on top of Duktape.
It would be interesting to get the authors of JerryScript, Espruino and Duklove to sit down and talk to each other.
Another similar device is the ESP8266, which is a low power microcontroller with an integrated WiFi networking stack. They are really cheap - you can get ESP8266 development boards for around $8 from Amazon or the raw chips in bulk for around $2 a piece. However, with only 64KB of RAM and ROM it is not quite beefy enough to run iot.js. The closest thing you can get is Lua through a project called
链接已隐藏,如需查看请登录或者注册
or the
链接已隐藏,如需查看请登录或者注册
project.
I think a low power Node.js runtime is long overdue and am looking forward to the first stable iot.js release.

最新回复

搞起来,这个可以有。  详情 回复 发表于 2017-4-6 19:52
点赞 关注

回复
举报

7452

帖子

18

TA的资源

五彩晶圆(高级)

沙发
 
搞起来,这个可以有。

点评

感谢free叔叔支持!  详情 回复 发表于 2017-4-6 21:10
 
 

回复

6040

帖子

205

TA的资源

版主

板凳
 
freebsder 发表于 2017-4-6 19:52
搞起来,这个可以有。

感谢free叔叔支持!
 
 
 

回复
您需要登录后才可以回帖 登录 | 注册

随便看看
查找数据手册?

EEWorld Datasheet 技术支持

相关文章 更多>>
关闭
站长推荐上一条 1/10 下一条

 
EEWorld订阅号

 
EEWorld服务号

 
汽车开发圈

About Us 关于我们 客户服务 联系方式 器件索引 网站地图 最新更新 手机版

站点相关: 国产芯 安防电子 汽车电子 手机便携 工业控制 家用电子 医疗电子 测试测量 网络通信 物联网

北京市海淀区中关村大街18号B座15层1530室 电话:(010)82350740 邮编:100190

电子工程世界版权所有 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号 Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved
快速回复 返回顶部 返回列表