RaspberryPi – Getting Started

RaspberryPi
The way I see it, the RaspberryPi is a cross between a computer and a microcontroller. From the computer perspetive, its a Linux computer that enables most of the functionality you get on a normal computer.

RaspberryPi Computer
Running Ubuntu Linux on my PaspberryPi, I can browse the internet, read email and write simple documents. There are plenty of USB ports for a keyboard and mouse, and the HDMI port enables your monitor. I can also run a web server and write cocmputer programms. That’s what makes the Pi experience unique.

RaspberryPi Microcontroller
The RaspberryPi exposes 40 pins, many of them available as GPIO (general purpose input-output) pins. So, the Pi looks and acts a lot like a microcontroller. Even after accounting for the unavailable pins (Ground, Power, special functions, etc.), there’s still a lot of pins available for use. Tutorials-RaspberryPi.com has a great article on using 50 different sensors and components. You build a circuit and connect to the appropriate GPIO pin.

Once you have a circuit and sensor connected, you can use a variety of programming languages and techniques to read and write to the GPIO pins you’ve selected. Python is a popular language, but C, C++, assembler and a whole host of other alternatives are out there as well. The type of project is only limited by your imagination.

RaspberryPi Server
The Pi also provides services normally available on a server that you can leverage for more functionality. The best feature I found is installing and running a web server. I run Apache2 so that I can build and publish content that can be viewed on a web browser. Again, the level of complexity is up to you.

Setting up Apache, getting comfortable with a web server and putting up a Hello World page is a great start. You can display GPIO pin states or direct output from your sensors to a web page. I collected temperature sensor data, wrote it to a SQLite database and produced temperature charts on a RaspberryPi a few years back. That project morphed and is now hosted on an Amazon AWS server, but the important work and testing all started with a RaspberryPI.

Getting Started
On its own, a RasspberryPi can’t do much. You need an appropriate power supply for it to run. The RaspberryPi 4 uses a USB-C connector and requires 3A to boot. I recommend the CanaKit Raspberry Pi 4 Power Supply, which you can get on Amazon for about $10. A USB keyboard and USB mouse are next. I haven’t found any wired USB mouse or keyboard that didn’t work.

The last two items are a micro-SD card and a monitor. The SD card is where you install the operating system – think of it as the hard drive for the Pi. You need at least 8GB, but 16GB is my suggestion. For the monitor, the latest version (4B) comes with two mini-HDMI ports. So make sure you have an appropriate cable – probably a micro-HDMI to HDMI cable.

About Tim Porter

Tim retired after over 30 years in various technology roles. He's worked in application development, infrastructure, database management and network engineering. In his spare time, Tim also also dables in electronics and microcontroller programming.