Johnny Five Tutorial: Learn How to Interface with Electronic Devices using JavaScript

Johnny Five is a fantastic library that allows developers to communicate with electronic devices using JavaScript. While devices like Arduino are typically programmed in the Arduino Language, Johnny Five enables us to interface with Arduino using JavaScript, particularly in Node.js. Setting up your Arduino to work with Johnny Five To get started, follow these steps: Download the Arduino IDE from http://arduino.cc/en/main/software. Connect your Arduino board to a USB port on your computer....

Johnny Five: How to Use a REPL for Embedded Development

This post is part of the Johnny Five series. See the first post here. When working with Johnny Five, it’s important to understand the concept of a REPL (Read-Evaluate-Print-Loop). The REPL allows us to interactively write and execute code in the terminal. To start using the REPL, create a repl.js file with the following code: const { Board } = require("johnny-five"); const board = new Board(); In this example, we’ll be using an LCD circuit that we created in a previous lesson....

Using Johnny Five to Receive Input from an Electronic Device

This blog post is part of the Johnny Five series. If you haven’t read the first post yet, you can find it here. In this post, we will explore how to receive data from an electronic device using Johnny Five. Specifically, we will use a water level sensor to monitor the level of coffee in a cup. This will help us determine if we need to refill our cup to sustain our programming endeavors....

Working with an LCD Screen: A Johnny Five Guide

LCD screens are versatile components that can be used in a variety of projects. In this guide, we will learn how to work with an LCD screen using the Johnny Five library. Let’s get started! Getting Familiar with the LCD Screen The LCD screen we will be using is the 1602A model, which has 16 pins. Here is how it should be wired: Pin 1: 0V Pin 2: Potentiometer (backlight control) Pin 3: 5V Pin 4: Arduino Pin 7 Pin 5: 0V Pin 6: Arduino Pin 8 Pin 11: Arduino Pin 9 Pin 12: Arduino Pin 10 Pin 13: Arduino Pin 11 Pin 14: Arduino Pin 12 Pin 15: 5V Pin 16: 0V Wiring the LCD Screen To control the backlight, connect the middle pin of the potentiometer to the LCD screen, the left pin to 0V, and the right pin to 5V....