Node-Red is an app, which runs on top of NodeJs. Node-Red is usually run on cloud servers, but as more powerful CPUs are placed in IoT devices, it is only a matter of time before it can be supported locally. It already runs on Raspberry Pi and Intel Galileo.
Node-Red enables programmers to build systems much quicker.
A programmer can quickly get up and running by using simple drag-and-drop module functionality. However, it still has all the power of regular NodeJS, meaning the programmer can write regular code behind any of the module blocks, building up fully fledged production capabilities.
Node-Red is very easy to start using; it feels like drawing flowcharts that actually come alive. You don’t just design the system, it actually runs.
You could have any IoT device log straight to the cloud while also having cloud based servers do the same, both running Node-Red and piping to Logentries. For example, I did this with a cloud logging robot arm I built for fun.
We have been using the Logentries service for years now on a wide variety of devices and platforms. It’s great to have a central location to access and search all the logs from multiple projects in one place. As mentioned, I recently found Node-Red, which is a fantastic visual experience for wiring up Internet of Things devices on the net.
More about Node-Red
Node-Red runs on server instances providing the cloud computing for IoT or actually out on the devices themselves for edge-based activity. It is powered by NodeJs and it is possible to create modules or “nodes” to extend its capabilities. We created one such module and posted it on github for you to freely use. You can get started on this for free by using IBM’s Bluemix to get a free instance of Node-Red (or install locally) and a free trial of Logentries.
There is a huge benefit to having all these “things” out there logging to a central location on the cloud, since many of them are inaccessible for the manufacturers or administrators.
Watch the video tutorial below to see the installation process and watch the Node-Red Logentries module in action. Or dive right in and install the module yourself with just:
npm install node-red-contrib-logentries
Usage and guidance:
Once you have it installed, start Node-Red using the command:
Then with Node-Red running, drag the new module onto the worksheet:
Double clicking on the Logentries node allows you to set the configuration so the logs arrive in your account. First, get a Logentries Account and create a log using the following Token TCP type:
Then, navigate to that log and grab its “token code.” That token is what goes into the configuration of the Node-Red node.
Now, when your Node-Red flow sends logs to the cloud, they appear in the consolidated log account:
Another fun exercise is to see how easy it is to send a log of all the MQTT activity to logs for analyzing:
We hope you enjoy Node-Red, and please leave a message in the comments below if you have any questions or find this tool helpful.