In Part 1
One of the most useful reasons for providing your Raspberry Pi with a REST API is to expose its input and output ports via the Internet for remote monitoring and control. This will allow you to control your RPi’s inputs and outputs from the browser on any smartphone or PC wherever you are in the world.
So now we will do just this, extending our REST API implementation from part 1 to read and display digital input ports.
Microsoft has now released its Windows 10 operating system for a raft of single-board computers, including the Raspberry Pi 2, intended for powering the “Internet of Things”. Here’s how to bring Windows to your Pi.
If you have downloaded the gertboard software package gertboard_sw_20120725.zip from the farnell site at http://www.element14.com/community/docs … rd-techdoc on your Raspberry Pi 2, you’ll find it doesn’t work right away.
I started out in my software engineering life writing software for embedded real-time systems and communication stacks, so I often think of myself as an async native. I’ve written a lot of code in various languages, mostly not using event-driven programming models and design patterns, but hardware interrupts, callback functions, event loops and finite state machines – I still see these as reassuringly familiar features of my original habitat. Call it the baby duck syndrome.
Who is this post for?
Why install Node.JS on a Raspberry Pi ?
And so when I come up with an application where I want to use my Raspberry Pi as a micro web server, but one that needs more than the ability to serve static webpages, I right away think of Node.
Coming soon – how I built an NFC card reader on the Raspberry Pi with a web dashboard displaying NFC events detected in real time…
You sometimes need to find out the MAC address of your Raspberry Pi. For instance, you want to find it among the list of devices attached to your LAN, because you want your router’s DHCP service to assign your RPi a permanently dedicated IP address instead of letting the DHCP just assign it the next available IP address each time you start it up. Then you can SSH into the same IP address each time to log into your RPi from your PC or Mac knowing it will always be there, without having to search for the RPi on the network.
Some LANs are configured to allow access only for a white-listed devices by MAC address, so you’ll also need to know yours to be able to use such a LAN.