Skip to Content
Node.js for Embedded Systems
book

Node.js for Embedded Systems

by Patrick Mulder, Kelsey Breseman
October 2016
Intermediate to advanced
266 pages
5h 45m
English
O'Reilly Media, Inc.
Content preview from Node.js for Embedded Systems

Chapter 8. Node.js Libraries for Hardware

In this chapter, we’ll continue programming hardware with JavaScript. By now, you have made some basic steps to set up hardware and a software toolchain. Let’s go beyond the blinking LED. This chapter begins by introducing a library to communicate with an embedded device over a serial port.

Next, after sending and reading bytes from a device, it is time to look into representations of components in JavaScript. For this, the library Johnny-Five will get you going.

Finally, this chapter closes with some ideas and instructions on using your new knowledge to experiment in a variety of directions.

Most examples will still work with a simple Arduino Uno. But with a board that supports embedded Linux, you can run the examples inside an embedded device too. As for components, the Seeed Studio Grove Kit should cover most of the examples for now. The Grove Kit shield lets you quickly connect components such as buttons and outputs to your base board.

Note

The Johnny-Five Inventor’s Kit includes a set of hardware with tutorials that explain how to use Tessel 2 with Johnny-Five. You can see some experiments using Johnny-Five on the Tessel 2 (and associated hardware kit) in the “Experiment Guide for the Johnny-Five Inventor’s Kit”.

You’ll also see some examples that are based on the LibMRAA library. Don’t be confused by its name—it does not (yet) have a meaning. What’s important is that this library provides bindings for JavaScript to low-level pin ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Distributed Systems with Node.js

Distributed Systems with Node.js

Thomas Hunter
Mastering Node.js - Second Edition

Mastering Node.js - Second Edition

Sandro Pasquali, Kevin Faaborg

Publisher Resources

ISBN: 9781491928981Purchase bookErrata Page