Category: Raspberry Pi

Raspberry Pi single board computer

Booting from SSD – Raspberry Pi

A few weeks ago I purchased a USB 3.0 Solid State Drive (SSD). My intention was two-fold:

  • to add more storage to my Raspberry Pi and
  • to eventually use it as the boot disk for the Pi.

There are some advantages that come with booting from USB 3.0 SSD, most noticebly an increase in speed but also SSD’s are more reliable that micro SD cards and more cost effective on a $/Gbyte basis.

Early Raspberry Pi’s booted primarily from micro SD card. You wrote your operating system image to the card and inserted it into the Pi before booting up. Booting from a USB device was possible but involved a bit of MacGyvering. Since the introduction of the Pi 4B and the Pi 400, USB boot has been made easier.

I had been looking at this option for a while. I found numerous write-ups on the interwebs explaining how to accomplish the task. Some were more complicated than others. But it comes down to whether you have the most up to date Operating system (I have the new 64 bit “bullseye” installed) and up-to-date eeprom.

I found a set of instructions written by J. A. Watson at ZDNet called Booting my Raspberry Pi 4 from a USB device and it seemed to be the simplest and least confusing way to go about it. The author explained that your Pi4 must have bootloader eeprom firmware dated Sep 3 2020 or later. He also explained how to check this and I was able to confirm that mine was up to date. Watson also explained that you need to be running Raspberry Pi OS version 2020-08-20 or later, which I am with Bullseye.

So having confirmed both of the above, I decided to go ahead and make my SSD bootable. The process was simple. After running sudo apt update and sudo apt upgrade I used the SD Card Copier utility from my Pi’s Accessories menu and copied the contents of the bootable micro SD card currently installed in my Pi to the SSD.

When the copy process finished after a few minutes, I shut down the Pi using the sudo shutdown command from the terminal. Once the Pi shut down, I switched off the power supply and removed the SD card.

Now for the moment of truth. I made sure the SSD was powered on (it’s on a powered USB hub) and I powered up the Raspberry Pi. The boot process was smooth and I encountered no problems.

And I have noticed an increase in speed now that the Pi is running from SSD.

Homemade ADS-B antenna

I wasn’t really satisfied with the range of reception my ADS-B receiver was getting. With the kit antenna, I was receiving signals from aircraft up to about 50 nautical miles, but more reliably only really 30 miles. That was with the antenna situated inside my patio door. I found that moving it outside increased the range but it wasn’t a practical idea to have the patio door cracked open in March. I wanted a more permanent setup with even better reception.

After a bit of research on the interwebs, I decided to build myself a homemade “co-co” – coaxial collinear – antenna. I made my antenna based on a couple of YouTube videos and this excellent description at www.balarad.net

A collinear antenna consists of a number of equal length segments of coax cable joined by alternating the center conductor of one to outer sheath of the next. The ideal length of each conductor is calculated based on the frequency to be recieved (1090 MHz) and something called the coax velocity factor. Luckily there are calculators on-line like this one at jeroen.steeman.org

The videos and other resources I found had calculated the length for each antenna segment at either 116mm or 118 mm. So after careful consideration, I decided to split the different and go with 117mm. Fortunately, I had some unused RG6 coax cable which I was able cut into the required segments.

Assembling the collinear coax antenna

The antenna can have as many segments as you wish, but it seems that any more than 8 doesn’t offer a great deal of improvement. So I went with 8 segments. The photo above shows how the segments are joined with the center conductor of each inserted into the sheath of the next. A piece of electrical tape not shown here is placed between the conductors. Then each connection is wrapped with more electrical tape.

After assembling all 8 segments (the last one has an F-type fitting) the whole thing is inserted into a piece of 1/2″ ABS pipe about a meter in length. The top is capped and the fitting at the bottom is wrapped with electrical tape until it fits snug.

antenna mounted to deck

I mounted my new antenna outside on the corner of the wall of my deck and ran a 25 foot piece of RG6 coax cable into the house to the NooElec SMArtee SDR reciever on my Raspberry Pi 4B computer.

So was it worth it? Absolutely, my reception has gone from 30-50 nautical miles to 150-200 nautical miles. At times I have been receiving signals from over 100 aircraft. That’s a big jump form the 10-15 I was getting before.

My ADSB data is being fed to the flight tracking services of ADSB Exchange. If you check their website, you will see aircraft tracked by my ground station (and many others all over the world).

ADS-B antenna

Here’s a couple of screen captures that show the reception I had with the kit antenna (top) and with the new “co-co” antenna (bottom).

Reception with kit antenna
Reception with outdoor “co-co” antenna

Receiving ADS-B on my RPi

ADS-B is a signal that commercial aircraft transmit that indicates their speed, position and heading, among other things.

To receive it you need an RTL-SDR receiver and some decoding software. I recently bought at dongle from NooElec, the NESDR SMArtee. One end plugs into a USB port on the computer and the other end attaches to an antenna.

It came in a bundle with some cheap antennas for listening to broadcast radio as well as one that’s tuned to 1090 Mhz where the ADS-B broadcasts are located.

I installed software called dump1090 on my RPi 4B which decodes the signals from the aircraft and plots them on a map (see below). Pretty cool.

I also installed PiAware which connects to the FlightAware website and transmits the data received to them, which they use to track aircraft all over the world and display on their website. In exchange for feeding them data FlightAware offers a free premium subscription.

I had a problem with the PiAware installation and I don’t have it working properly yet, so I’m not able to connect to FlightAware. But I have noticed that my data is more up to date than what is displayed on the FlightAware website.

But you can see from the screen capture below that I am getting some good data from the aircraft in the area. We live in a busy air traffic area, so this should be interesting.

Pi OS 64 bit

Raspberry Pi’s new 64 bit operating system (OS) was released about a week ago. Today, I decided to upgrade my RPi 4B to the new 64 bit OS.

While the RPi 4B is a 64 bit machine, the previous version of Pi OS was 32 bit. I was having some issues with my 4B occasionally freezing up, especially when surfing the web with the Chromium browser. I installed Firefox-esr to see if it worked any better, but it was only available in ver. 78 and some sites didn’t render properly, notably Amazon.ca

After installing the new 64 bit Pi OS, I noticed a significant improvement. Performance wise, the RPi seems a bit faster, but most importantly the freeze-ups are non existent!

And I was able to install an up-to-date version of Firefox. Web browsing is greatly improved.

I will continue testing, but I think I’m going to be happy this version.

One of the reasons, I bought the RPi 4B was to try different Llinux distributions, known as “distros”. I will give some of the other 64 bit distros a try and I’ll post about the ones I like or don’t like.