Connecting a Raspberry Pi Using an Ethernet Crossover Cable and Internet Connection Sharing

I’m preparing for an upcoming speaking engagement around the topic of using Node.js and the Raspberry Pi for IoT applications. While at home, I enjoy the luxury of being the owner of my network which provides complete freedom in network configuration. On the road, I will not have this luxury whether it is at a hotel or when speaking at the conference.

Raspberry PiHere’s the problem I am trying to solve. While on the road, I want to be able to connect my laptop to the Wi-Fi hotspot on my phone rather than utilizing the wireless network at the conference location which might be fraught with both security and reliability issues. I also want to be able to get my Raspberry Pi system on the Internet. Additionally, I need my Raspberry Pi and my laptop to reside on the same network so I can easily connect and share files back and forth. Finally, I need this to be easy and foolproof so I’m not sweating on stage and trying to tweak Raspbian network configuration settings in order to establish network connectivity.

How about you? You might also have a similar need if you are seeking to get your Raspberry Pi on the Internet at a hotel, university, or other venue such as a conference. I’m going to show you how you can get your Raspberry Pi on the network when you are not connected to your home network using an Ethernet crossover cable.

I have read a lot of guides on the Internet, but they involve way too many steps. Surely there must be a better way that requires minimal fuss? Absolutely! Let’s get started! Continue reading

Getting Started with YAML in Node.js using js-yaml


In this tutorial, we harness the power of YAML for use within Node.js. As described on the official YAML site, YAML (YAML Ain’t Markup Language) is a “human friendly data serialization standard for all programming languages”. YAML and JSON are closely related. In fact, all JSON syntax is valid YAML as of the YAML 1.2 spec, but not all YAML syntax is valid JSON. YAML is a superset of JSON. Continue reading

Node.js IoT: Logging Data That Is Out of This World

IoT loggingThe ability to log data is an important capability in IoT applications. In this tutorial, we learn how to use Node.js to log data by utilizing built-in Node modules. There are certainly excellent logging modules available including pino and Winston (see my Winston tutorial here); however, our goal today is to deepen our knowledge of Node by implementing some simple logging code ourselves in order to become better Node developers. Continue reading