Turning a Raspberry Pi computer into an air monitoring station with a few add-ons
Pimoroni’s Enviro+ Raspberry Pi hat lets you start to measure the quality of air around your home.
http://www.zdnet.com/

Before diving into my hands-on dialog, here are a couple of links that contain interesting and useful information about the new Raspberry Pi 4 and Raspbian Buster operating system:

From these three references you should be able to find all the technical and commercial details about the Raspberry Pi 4. The Raspberry Pi 4 Starter Kit that I ordered arrived Thursday afternoon, as promised. The contents are pretty basic, but enough to at least get going:

    pistarter.jpg

    Raspberry Pi 4 Starter Kit.


    Image: Pi-Shop.ch

  • Raspberry Pi 4 Model B, with 2GB memory
  • 15W USB-C power supply
  • Raspberry Pi 4 Case
  • 16MB micro-USB class 10 SD card, preloaded with NOOBS software
microhdmi.jpg

Micro-HDMI to HDMI Adapter,

The glaring omission here is any kind of micro-HDMI cable or adapter. There are still no such cables in stock at the Pi-Shop (which probably also explains why there wasn’t one included in this starter kit), so I had also ordered an adapter.

There is a limitation when using the micro-HDMI adapter, which is perhaps not obvious from just looking at these pictures. Because the two micro-HDMI connectors are relatively close together on the board, it is not possible to use two adapters side by side – there’s just not enough room for the HDMI heads of both of them.

Otherwise everything looks very good. It all fits together nicely – it seems to me that the Pi 4 board is a bit more snug in the case than the previous generations, so you have to be careful that the mounting holes in the board seat properly on the pegs in the case.

The micro-SD card in the kit is preloaded with NOOBS. For those who aren’t familiar with loading/installing Raspbian, NOOBS is basically a way of distributing Raspbian on a specially formatted/partitioned SD card so that it is easy to add other operating systems alongside it. There is no difference in Raspbian itself between the NOOBS distribution and the Raspbian-only distribution. The NOOBS card also contains LibreElec, which is a stripped-down version of Linux with the Kodi media center software installed.

The down side of the NOOBS distribution is that it boots much more slowly than a Raspbian-only installation. It looks around to see what other operating systems are installed, and it delays a bit to give you time to interrupt the boot process so that you can add or remove other operating systems. I don’t run anything other than Raspbian on most of my Pi systems, so I don’t use SD cards in NOOBS format any more.

The way to get Raspbian-only installed is to go to the Raspberry Pi Downloads page and get one of the Raspbian images.  There are three to choose from:

  • Raspbian Buster Lite: A minimal text-only (CLI) version.
  • Raspbian Buster with Desktop: Includes the Raspbian Pixel graphical desktop
  • Raspbian Buster with Desktop and Recommended Software: Includes the Pixel desktop and some additional larger software packages.

If you don’t have any specific reason to do otherwise, the best choice here is probably the Raspbian+Pixel image (the one in the middle). If you need/want the text-only image you will definitely know that, while one of the largest and most important parts of the Raspbian+Pixel+More image is the Wolfram/Mathematica software, and that isn’t ready for this version of Raspbian yet, so it is not there anyway. As Simon says in the post linked above, when Mathematica is ready it will be announced and available for easy download and installation.

The Raspbian+Pixel image is just over 1GB in size (expands to about 3.8GB), while Raspbian+Pixel+More image is just under 2GB (expands to about 5.3GB). For either of them, once you have downloaded the image you need to unzip it and copy it to a micro-SD card. Although the text-only image might still fit on a 4GB card (I haven’t tried in a while), the GUI images require at least an 8GB card. If you have a Linux system available to do this, the all-in-one command line is something like this:

    unzip -p 2019-06-20-raspbian-buster.zip | dd bs=4M of=/dev/sdX iflag=fullblock oflag=direct status=progress

Replace /dev/sdX in this command with the device name of your SD card.

If you don’t have a Linux system available, the Raspbian Installation Guide contains instructions for Windows and MacOS.

You can then put the micro-SD card in the Raspberry Pi 4 and boot it up!

During the first boot the root filesystem will be expanded to fill the free space on the SD card, and the Pi will then automatically reboot. All of this happens without you having to do anything. During the boot sequence you will get your first look at how much faster the Pi 4 is than previous models; for example, the Pixel desktop startup screen, which used to be visible for quite some time during boot, flashes past so quickly that if you blink you might miss it (literally). The entire boot process takes less than a minute, and you will then have the (new) Raspbian Pixel desktop:

2019-07-12-095513-1680x1050-scrot.png

Raspbian Buster Pixel Desktop


Image: J.A. Watson

Wow, is that nice – and fast!

welcome.png

Image: J.A. Watson

The ‘Welcome to Raspbian’ window will be in the center of the screen, where you should click “Next” to start the first-boot configuration process. Be aware that if you are not using a US-Ascii keyboard, it has not been configured yet so the keys are not going to produce what you expect. You can detour here, ignoring the Welcome window, and go to the Pixel menu (click on the raspberry at the top left of the screen), then Preferences, then Raspberry Pi Configuration, and on the Language tab choose the correct layout.

country.png

Image: J.A. Watson

When you click on Next in the Welcome screen, you will get the Country selection window. This sets the location, language and timezone for the installed system, and the location setting will also determine the WiFi characteristics. Again, it does not configure the keyboard.

password.png

Image: J.A. Watson

Once that is done, click Next again to proceed to the next configuration screen.

The password screen is as simple as it looks – just enter the password twice (for confirmation), and click Next.

networks.png

Image: J.A. Watson

The next screen allows you to select a wireless network; if the network you choose requires a password, you will be prompted for it. Of course you can skip this step, and configure a wireless network later if you want. If you have a wired network connection available, it would be a good idea to use it for the moment, while you get through the software update procedure.

error.png

Image: J.A. Watson

Once the network is configured, the installation process will proceed into the Raspbian software update process. Unfortunately at this point it runs into a problem which is actually an unexpected side effect of the fact that Raspbian Buster was released before the final release of Debian Buster, which it is based on.

When a Debian release changes from “testing” to “stable”, as Buster just did, some of the repository names change. Because this Raspbian release was built before that change took place, it still has the old names in place, so when it finds the change it isn’t happy. There’s nothing you can do about it at this point, just click “OK” and let the window disappear. I’ll show you how to fix this problem in just a minute.

apt.png

Image: J.A. Watson

After the error window is gone, you will get a window which says Raspbian is up to date (of course it’s not), and asks if you want to reboot. Click “Later” on this window, so the first-run configuration process will be completed. Then start a terminal window (click on the terminal icon in the title bar), and run “sudo apt update”.

It is important to use the “apt” command here, not “apt-update”, because apt recognizes the repository change, and asks you if you want to accept the new repository information, while apt-get just complains about the problem and exits, pretty much as the first-run process did. There are other ways to fix this problem, but this is the easiest one that I know of.

After accepting the change from apt, follow that with “sudo apt dist-upgrade” to download and install all the latest Raspbian updates. Once that is done you have actually completed everything that was supposed to be done in the first-run process, so you are now really ready to reboot.

SEE: How to build a successful developer career (free PDF)

At this point the Raspberry Pi 4 is connected, configured, and running the latest Raspbian release, with all the latest updates. I will work with it over the weekend, try to get some better ideas about what is good (and perhaps not so good) about it, and write more. Have fun!

P.S. One last, quick note, because I’ve already come across one thing in the “not so good” (very irritating) category. It appears that if I leave the Pi 4 sitting idle for some time, it first goes into screen-saver mode, where the console is blanked, and you can continue working by just moving the mouse or touching the keyboard.  

But it you leave it untouched for a while longer (I don’t have a clear idea of how long yet), it seems to go into some sort of suspend/hibernate/whatever mode from which I have not been able to awaken it. Power-cycling seems to be the only solution – and that’s definitely not good…



Author:

Source link: Raspberry Pi 4 Model B and Raspbian Buster: How to set up your board

DEIXE UMA RESPOSTA

Por favor digite seu comentário!
Por favor, digite seu nome aqui

Esse site utiliza o Akismet para reduzir spam. Aprenda como seus dados de comentários são processados.