Node could bring JavaScript to the Internet of things

PaaS provider Structure sees Node.js and JavaScript offering an easier route than languages like C and C++ if it can overcome its footprint issues

Node could bring JavaScript to the Internet of things
Credit: Thinkstock

With the availability of boards like Raspberry Pi and Npm-based communications modules, Node.js is becoming more of an option for developers building applications for the Internet of things, an industry executive stressed on Thursday.

Speaking at the Node Community Convention in San Francisco, Charlie Key, CEO of IoT PaaS platform provider Structure, made the case for the server-side JavaScript platform in IoT. He sees it as appropriate even if it currently offers too large a memory footprint for some smaller IoT devices.

Key broke the IoT lifecycle into four parts -- collecting data, communicating, analyzing, and acting -- and noted that "when you look at Node.js and what JavaScript is capable of, it's actually capable of pretty much all these different pieces." Current IoT toolsets leveraging C and C++ are hard to learn and use, Key argued, because such low-level languages mean more development time and issues.

IoT-applicable boards, such as Intel Edison, BeagleBone Black, and Raspberry Pi, can accommodate Node.js now, even if smaller units like ARM-chip-based small microcontrollers cannot, thus giving Node.js an entry into IoT, Key explained. Node.js also gets a boost from Npm modules accommodating IoT communication protocols, such as MQTT, AMPQ, and HTTP. Node.js libraries like Johnny-Five and Cylon.js support IoT development as well.

Key sees Node.js expanding on the IoT as limitations fall. "The capability for the ARM chips will get better. So they'll allow a bigger footprint for things like Node," he said. "The other thing that I think is going to continue to happen is compilers for Node to these smaller languages and these smaller byte codes, basically running more compact code without having the full JavaScript engine on the actual chips themselves. That will allow us to still use a single programming technology to program these smaller chips."

Key noted Structure is not the only venture delving into putting JavaScript onto a smaller footprint. Samsung also has made a move in this space with its JerryScript JavaScript engine for the IoT. Samsung also has developed its IoT.js project, serving as a lightweight version of Node.js with JerryScript as an underpinning.

This story, "Node could bring JavaScript to the Internet of things" was originally published by InfoWorld.

To comment on this article and other CIO content, visit us on Facebook, LinkedIn or Twitter.
Download the CIO Nov/Dec 2016 Digital Magazine
Notice to our Readers
We're now using social media to take your comments and feedback. Learn more about this here.