Node.js Learning Path: Unit 6 – Your First Node Program

Hey everyone! If you want to learn Node.js, then check out my Node.js Learning Path, which you can find only at IBM Developer.

Unit 6 simulates a real project, where you are brought in to finish an application called The Shopping List, that was only partially completed by another developer.

Here’s what you’ll learn in Unit 6:

  • The application’s business requirements in the form of user stories
  • How to run the application’s functional tests, so you know when your code works (and when it doesn’t) – in other words, Behavior-Driven Development (BDD)
  • The application’s data model
  • How to load the application’s data – from the Open Grocery Database Project – into a SQLite database
  • How to write, configure, and run REST services using Node
  • How to use the VSCode debugger to interactively debug your code

Unit 6 also has a quiz (are you seeing a theme here?), and a video to help you get your computer setup to run the functional tests:

Ready to dive into your first Node application? Then click here to jump right to Unit 6.

Want to take the entire course? Then click here to start at the beginning, with Unit 1.

Either way, have fun, good luck, and thanks for reading!

–jsp

Node.js Learning Path: Unit 5 – The Event Loop

Hey everyone! If you want to learn Node.js, then check out my Node.js Learning Path, which you can find only at IBM Developer.

The Event Loop is the key to Node’s scalability.

Unit 5 of the LP is about the Event Loop, and in it you’ll learn stuff like:

  • The phases of the Event Loop
  • How to write code that runs in the various phases (so you know when your code will run)
  • The Node Events API
  • Node Streams

There’s a quiz to help you deepen your understanding of the material, and a video too:

Ready to dive into the Node Event Loop? Then click here to jump right to Unit 5.

Want to take the entire course? Then click here to start at the beginning, with Unit 1.

Either way, have fun, good luck, and thanks for reading!

–jsp

Node.js Learning Path: Unit 4 – Basic Concepts

Hey everyone! If you want to learn Node.js, then check out my Node.js Learning Path, which you can find only at IBM Developer.

Unit 4 of the LP gives you an introduction to the basic concepts you need to know when working with Node. Stuff like:

  • Sychronous versus asynchronous programming
  • Node’s module system, npm, and using third-party packages
  • Load testing using Apache bench, and loadtest
  • The Pyramid of Doom (I’m not making this up)

And lots more. I’ll even show you how to create a Node module (something you’ll do a LOT, trust me).

There’s a quiz to help you deepen your understanding of the material, and a video too:

Ready to dive into Node.js concepts? Then click here to jump right to Unit 4.

Want to take the entire course? Then click here to begin with Unit 1.

Either way, have fun, good luck, and thanks for reading!

–jsp

Process Substitution and SHA256 Checksum

Hey everyone!

When you verify the SHA256 checksum of a downloaded file you can copy the checksum from the website, paste it into an editor, run the shasum -a 256 command, paste the checksum into that same editor and compare them by eye.

Or, use the diff command and process substitution to do it, and never have to trust your eyeballs again (you should still keep them open while driving though).

I put together this video to show how easy it is to do this. Enjoy!

Thanks for reading!

–jsp

 

Node.js Learning Path – Unit 3: Node.js Architecture

Hey everyone! If you want to learn Node.js, then check out my Node.js Learning Path, which you can find only at IBM Developer.

Unit 3 of the Learning Path starts with an overview of the Node.js architecture: the Node API, the Node Core, the Event Loop, and the JavaScript engine (Chrome’s V8 engine).

You’ll learn about ECMA Script (ES), and how the different versions get their names (Q: is it ES6 or ES2015? A: Yes).

You’ll learn the key to Node’s impressive scalability (spoiler alert: non-blocking I/O via the Event Loop), and even write some code using the Node Read-Eval-Print-Loop (REPL).

You’ll also get a tour of Node’s package manager, npm.

There’s even a video (just when you thought it couldn’t get any better):

Click here to start your Node journey, or here to jump right to Unit 3 of the Node Learning Path.

Thanks for reading!

–jsp

Node.js Learning Path – Unit 2 – Install Node

Hey everyone! If you want to learn Node.js, you should check out my Node.js Learning Path, which you can find only at IBM Developer.

Unit 2 of the LP shows you how to install the software you need, like:

When you’ve completed Unit 2 you’ll have the software on your computer you need to complete the Learning Path.

Ready to install Node? Then click here.

Thanks for reading!

–jsp

Node.js Learning Path – Unit 1

Hey everyone! If you want to learn Node.js, you should check out my Node.js Learning Path, which you can find only at IBM Developer.

Unit 1 is the overview, where I answer the question: “Why Node?” and show you a detailed outline of the Learning Path.

The Learning Path has two major parts:

  • Part One: Learn Node – Units 1-9
  • Part Two: Apply What You’ve Learned – Units 10-14

The Learning Path will be published unit-by-unit over the next several weeks.

Ready to start your Node.js journey? Then Click here.

Thanks for reading!

–jsp

 

Blockchain: Can this be done with a database?

Greetings, all! IBM Code recently published a blog post of mine of the same title as this post on the IBM Code Blog.

This is a good question. I mean, isn’t Blockchain just a new kind of database? Well, yes, and no. It’s a database in the sense that it is a data store. But it’s not like any traditional database I’ve ever worked with (and I’m talking about relational databases, mostly).

The first question to answer in this dialogue is: What is a “Database”? Once we answer that question we can get the discussion centered around the topic at hand, which is why Blockchain cannot be done with a database.

Then, we have to answer this question: What is the Blockchain, anyway? After all, if we don’t really know what we mean by “Blockchain” (not that we don’t; we just need to all get on the same page w/r/t to the term Blockchain) how can we really talk about what it is and is not?

As I explain in the IBM Code post, the attributes of blockchain that distinguish it from a traditional (relational) database are that it is:

  • Distributed across boundaries of trust
  • Visible to all participants
  • An immutable ledger
  • Always appended
  • A dis-intermediation enabler

That’s a lot, I know. So be sure to check out the full post on the IBM Code Blog.

Thanks for reading, and happy Blockchaining!

What? That’s a word.

–jsp

IoT and the Smart Home, Series Overview

Hey everyone! Steve Perry here.

Do you like DIY projects? If so, make sure to check out my IoT Smart Home series at IBM developerWorks.

It is made up of three installments, which guide you through a DIY smart home project from start to finish.

Part 1 – Setup the hardware

In Part 1 I give you an overview of the project, including a complete parts list, and three videos that show you how to setup your Raspberry Pi 3, give you a quick tutorial of how to use a solderless breadboard, and how to setup the 433MHz receiver and transmitter modules on the breadboard.

Part 2 – Setup the software

In Part 2 I show you how to download, build, and use the software you’ll need to run on your Raspberry Pi to communicate with the Raspberry Pi, called WiringPi, and 433Utils,  how to use the WiringPi gpio utility, and show you how to capture the 433MHz encoding signals sent from the IoT device remote controls using a program you’ll build from 433Utils called RFSniffer.

Part 3 – Control the smart home

In Part 3 I show you how to setup your Watson IoT platform app that acts as the MQTT broker, how to build, test, and run the software that runs on the Raspberry Pi to control the smart home devices, and how to build and run the Android app that controls the system from your mobile phone.

Oh, there will be videos

Each part of the tutorial has three videos to let you see what I did to build the project, to help deepen your understanding of the technology, and to give you a jump start when you build the project for yourself.

In future posts, I’ll expand on each of these. I’m excited, and I hope you are too.

Get started with Part 1

To get started, check out Part 1, and order your parts. The entire project costs about 125USD, including the Raspberry Pi 3, and a 16GB micro SD flash drive. Not bad, IMO.

If you already have a Raspberry Pi 3 and 16GB (or larger) micro SD card, and want to get started, check out the video below, where I show you how to download and flash the Raspbian Stretch image onto the micro SD card and setup your Pi.

Thanks for reading!

–jsp