Book Image

Practical Node-RED Programming

By : Taiji Hagino
5 (1)
Book Image

Practical Node-RED Programming

5 (1)
By: Taiji Hagino

Overview of this book

Node-RED is a free and open source flow-based programming tool used to handle IoT data that allows programmers of any level to interconnect physical I/O, cloud-based systems, databases, and APIs to build web applications without code. Practical Node-RED Programming is a comprehensive introduction for anyone looking to get up to speed with the Node-RED ecosystem in no time. Complete with hands-on tutorials, projects, and self-assessment questions, this easy-to-follow guide will help you to become well versed in the foundations of Node-RED. You’ll learn how to use Node-RED to handle IoT data and build web applications without having to write complex code. Once you’ve covered the basics, you’ll explore various visual programming techniques and find out how to make sample flows as you cover web development, IoT development, and cloud service connections, and finally build useful real-world applications. By the end of this book, you’ll have learned how to use Node-RED to develop a real-world application from scratch, which can then be implemented in your business.
Table of Contents (19 chapters)
1
Section 1: Node-RED Basics
6
Section 2: Mastering Node-RED
11
Section 3: Practical Matters

Running the application

If everything is working, you should be able to open http://localhost:1880 in the browser and see the application.

Now, let's confirm that the ToDo application works by following these steps:

  1. Access http://localhost:1880 to open your ToDo application.

    If you get the Node-RED flow editor when you open localhost:1880, the setting httpAdminRoot is not enabled, so please check your settings.js file again.

    When you access this URL, the following screen should be displayed:

    Figure 9.21 – Open your ToDo application

  2. Any ToDo item is fine for this test, so enter any words as a sample task. Here, I typed Report my tasks:

    Figure 9.22 – Enter a sample ToDo item

  3. If you press the Enter key while entering a value in the text box, that value will be registered as a ToDo item. In the following screenshot, we can see that it looks like it has been registered in the application:

    Figure 9.23 – The ToDo item you entered has been registered...