Raspberry Pi 400 | Blathering

I am not one of those individuals who gets the new fancy hardware because I am an Internet nobody and that is just fine by me (as I sulk, rocking back and forth in the corner). That doesn’t mean I am not without my opinions.

Raspberry Pi 400 Kit

I watched a video early in the morning about the Pi 400 on Retro Recipes from the perspective of using it as a kind of retro machine, like an ultimate emulation machine in a compact size. The marketing on the box says it is a “complete personal computer built into a compact keyboard” which interestingly like the Commodore 64 of years past.

Granted, that is a much larger keyboard in comparison but for the time, it was rather compact when compared to its contemporaries of similar performance. The back of the Pi 400 has all the typical ports exposed on a standard Pi 4 so you have available all that was previously available but in a different form factor.

Specifications

This isn’t, by any stretch, an amazingly high performing computer but it is also no slouch. It features a Broadcom BCM2711 quad-core Cortex-A72 (ARM v8) 64-bit SoC @ 1.8GHz processor, 4GB of DDR4 RAM, wireless networking, dual-display output through 2 micro HDMI ports for 4K video playback, MicroSD Card slot for whatever operating system you plan to run, 2x USB 3.0 ports, 1x USB 2.0 port USB-C for power a Gigabit Ethernet port and finally a 40-pin GPIO header so all the fun of the Raspberry Pi is exposed.

It is claimed to have an operating temperature from 0°C to +50°C ambient. I am quite sure that going above 50°C would likely cause some kind of thermal throttling.

Essentially, this is a Pi 4 in a different package with the intent to be manufactured until 2026. That is an incredible length of time.

Design

This machine has the footprint of 286 mm × 122 mm × 23 mm. If you are metric shy, that is 11-¼” x 4-⅜” x ⅞” That makes this machine quite small and indeed compact. According to Perifractic Retro Recipes. The design is solid with just a bit of sponginess on the Enter key, “5% from perfect” was the claim

Picture taken from Retro Recipes Pi 400 video

It is quite obvious with the internals, that this is a completely different design than the standard Pi 4.

Picture taken from Retro Recipes Pi 400 video
Picture taken from Retro Recipes Pi 400 video

I am pleasantly surprised to see this elegantly simple designed board on the interior, not just a Pi 4 with connector wires to the back. It does look like reliability was a factor in the design and manufacturing of this equipment.

I am not sure how many times one would plan on getting to the internals of this computer, as everything for which you need access is on the back, I am concerned about cooling. The CPU is heat taped to the metal shield so that should help with thermal dissipation. I know that some early Pi 4s did have serious issues with getting too hot. That makes me a bit concerned and therefore, I would be interested in seeing what some stress testing would yield on this machine.

Possible Uses

If you have any interest in developing things on single board computers, this is absolutely a great way to work on something to rapidly test it out. Since there isn’t the mess of parts and pieces as you would more likely have with a standard Raspberry Pi, here you plug in the power, the monitor, and whatever you are working on to the back of the Pi4. Admittedly, unless you are developing to deploy this on the Pi 4, some of the specifics may not work on early versions of the Pi. I can’t say for sure but I do know that there are different images for different Pis.

I see a strong propensity for this device to become the “Ultimate Retro Arch machine” that you keep in your living room or video game den. With the keyboard, sturdy case and available USB ports on the back, it would be cost effectively simple to play all the games of yester-year on this without putting at risk of damage, the real hardware. Specifically, I am thinking for those times I do play retro-games with my kids, I do worry just a bit for the safety of my machines.

Although I think there is a better argument for an old netbook, I do think that this would be a great choice for a child’s first computer. It would, perhaps be better, to have them sit properly at a desk and do their typing tutor there or a nice little work station to learn and explore, taking advantage of the GPIO on the back, making wonderful electronics creations which leads me to my last point.

As an inspiration education tool for children or adults. Lets be fair here, this is a toy for an adult, just as much as it is for a child. This is a super cool kit that is more than just an educational tool for youngest of populations. This is a great tool for any age to learn and dig into it that has the vulnerable bits protected. This frees up any apprehension of getting all the right pieces and not having some collection of things that looks like a science experiment, dominating a desktop or workbench. The GPIO pins on this device are shielded from an accidental drop or scoot that might short something out. This is a much safer way to conduct reckless mad-scientist like electronics experimentation

What I Like

The kit looks like the way to go. It has a retail of $100 (though I can’t find anyone selling it at this time) which comes with an official power supply, mouse, HDMI cable and perhaps, most importantly, a beautiful manual that is loaded with pages of all kinds of informative educational excitement. This is essentially an educational tool that comes with a real manual like the days of old. For me, the manual is key. Thumbing through the pages documentation, running my fingers down the inner spine of the book encourage it to stay open and explore all that it has to offer. There is something about that smell of a freshly bound book that makes an experience real and memorable (I realize, I am dreaming here).

The build quality looks more than adequate. I would absolutely gauge my expectations around the $100 mark and wouldn’t try to compare this with a modern Dell Latitude in fit, function and performance. That would be completely ridiculous. Based on other reviews, they keyboard looks to be just 5% from perfect which is more than adequate for me and especially more than adequate as an educational tool.

All the connections are on the back, like in good all-in-one Commodore 64 fashion and is nicely shrouded to protect against accidental shorting of pins or parts on the board. It doesn’t protect against everything but would protect against most accidental clumsiness.

Perhaps most important of all, this is spearhead into he inspiration of future generations to develop and create solutions. It is that first computer you can feel good about giving a child that he or she can take the time to learn and create. This is the beginning of something that is far better than having them plunk away on a phone or tablet being entertained like mindless automatons. This can be used to just just consume but to create and give to the world in which we live.

What I Don’t Like

The case uses clips to hold it together as opposed to screws. I am aware that screws do cause significant increases in manufacturing cost, so I understand the decision to forego case screws. That just happens to be my preference.

There are some incompatibilities between the Pi 400 and the Pi 4. Though I believe it has largely been worked out and since it is Linux that is running on top of the hardware, I am quite certain, through the magic of configuration files, kernel modules can be turned on and off based on the underlying hardware platform.

Since this is an ARM based system, anything that is built to run on top of it is likely to be unique for this specific ARM platform. ARM tends to lack standards across the architecture, which I believe is holding back the wide spread adoption of ARM (among other things). It is at least one reason I don’t just run out and by ARM devices.

Worst of all, I can’t seem to find any place that has them for sale. It looks like it’s sold out! So, all I can do at this point is kick my feat up, dream and wonder about all the fun I could be having with this… until my goldfish-like attention span drifts me off to another intellectual curiosity.

Final Thoughts

This is a great little piece of kit that is essentially a STEM course in a box. The design, the look and from what I can tell by other reviews, build quality are top notch, especially at this price point of $100 for the kit and $70 for the computer/keyboard itself.

I don’t have an immediate use for such a device but I can say that I would love to get my hands on one and play with it. Test it out and see what it can do. I do think it would make for a great Retro Arch machine. Even better would be to run openSUSE on this with all the Retro goodness and even for some productivity.

I think the best use of this particular machine is in education. The cost is low enough that you could buy for a whole classroom without breaking the bank and inspire future generations to develop and create wonderful solutions for the next generation of challenges.

Lastly, why 400? Should I have been making parallels to the Atari 400 as opposed to the Commodore 64? The keyboard on the Atari 400 was awful…

References

Retro Recipes Pi 400 Video
https://www.raspberrypi.org/products/raspberry-pi-400/
Raspberry Pi 400 Specifications
http://www.retroarch.com/
https://www.opensuse.org/

Blathering | Raspberry Pi to Monitor Air Quality with an Arduino based Thermostat

Arduino Test Board.jpg

I’d like to call myself a tinkerer, but I don’t tinker enough hold that badge. I do like to look at other projects and see what is out there for things to make my life more efficient. My target is to make my home, work for me, to automate every aspect that is feasible that has real value to me that will make life a little more efficient and have a bit better resolution on the control of the world around me. One area that needs some work is the HVAC (Heating, Ventilation and Air Conditioning) controls. I have been pondering this for a while and I think I have a good project plan to make my house work for me just a little bit better.

This is just a blathering of a project to come. If you have any thoughts or suggestions, think that this is ridiculous and a waste of time, fire those off too. I’m open. It may not change my mind but it is always worth listening to a dissenting opinion.

Project Goal

I want a home thermostat and environmental control system that is under my control and doesn’t babble off to a cloud someplace. I want it to be intelligent enough to manage the room temperatures, know if a window is open in the house, adjust the dampers in my ducting to cycle air between the floors differently depending on the time of year. I want it to be aware of the current outdoor weather as well.

Why Weather Aware?

Weather Station.jpgI want the system to know how humid it is inside and outside of the house. Much of the summer in Michigan, I don’t need to have the air conditioning on, but I do want to keep the humidity down inside of the house. I also prefer my windows open to closed, so it would be nice if I could have my thermostat would know if windows are open. There is no reason to dehumidify the house when my windows are open.

Targeted Features

The Arduino portion can handle a lot of the functions I am targeting but there is another angle, I am interested in knowing what the pollution is inside the house. I have only dug into this a little bit but the Enviro Raspberry Pi Accessory is able to measure indoor air quality, humidity, pressure, light and noise levels. This could even tell me how effective my filter is too and find the most cost effective filter that does the job. It would allow me to run a Design of Experiments to test and maximize the cleanliness of the air in my home. I don’t know the extent of the on board air quality sensor but it could really do the job.

The Plan

Thermostat.jpgConfigure and build the Arduino thermostat, that is robust, reliable and extensible to control the HVAC system. Once I can do that reliably, I’ll add more sensors to it, window sensor, temperature sensors of different rooms, duct pressure at the blower, then I can start to add automated dampers in the system to control temperature leveling in the house more precisely. Also, to shunt airflow to unused rooms in the house as well during extreme weather conditions. I want to have all the data, inputs, outputs, status and so forth to be accessible on my network so that at any point in time from any computer terminal, I can look at my “environmental system” status. Of course, it will somehow be running openSUSE Linux, someplace. Either a Raspberry Pi running openSUSE or better yet, something x86 based. It’ll be incredibly, joyously nerdy.

Next Steps

For now, I am still gathering information, parts lists and so forth. The first step in this chain will be to replace the thermostat with an Arduino Smart Thermostat that will have better functionality. Once that is working and I have a good understanding of how to manipulate it. I will start to add sensors to it. From there, I’ll figure out my greatest need to further improve efficiency and add the functionality needed.

References

Enviro Raspberry Pi Accessory to Monitor Air Quality at FOSSBYTES.com

Arduino Smart Thermostat

JohnsonControls.com equipment dampers and louvers

RasberryPi Info Center

Rpi3_boardI have a RaspberryPi that is doing absolutely nothing. I got it to dink around with it but it just hasn’t been all that useful to me. I much prefer the x86 platform for, pretty much everything. Not so recently, my church expressed a need for a slideshow like machine for things, events, announcements, pictures and the like. Since I have a Pi3 doing absolutely nothing this sounded like a great fit.

Project Requirements

  • Low or no maintenance device that just rotates through a selection of pictures and a given interval
  • Add and remove content from the directory without the slide show software either skipping or borking
  • Be able to FTP into the Pi to drop pictures onto it.

I downloaded Rasbpian and to play along with the written recommendations, I downloaded the image writer, Etcher.

The Etcher AppImage is built against 32 bit architecture so some additional software was required for openSUSE Tumbleweed on a 64 bit architecture

sudo zypper install libXtst6-32bit libXss1-32bit gconf2-32bit

To start out, I needed to make sure I could remotely access this Pi through Secure Shell. I checked the status of the service

systemctl status ssh

I’m going to pause here just to say, Systemd rocks. What a great service for controlling services on Linux via the terminal. It makes using the terminal on different distributions quite comfortable.

The service was “dead” so I started and enabled the ssh service

sudo systemctl start ssh
sudo systemctl enable ssh

After much searching about, I landed on feh as the application to play a slideshow.

sudo apt-get install feh

To test it out, I needed to transfer some pictures to the Pi. Using my favorite file manager, Dolphin.

File Transfer to RPi

After the files had transferred. Ran a test command to see if it worked

feh -Y -x -q -D 5 -B black -F -Z -r /home/pi/Pictures/

And it worked smashingly… except if I added pictures it wouldn’t automatically update the images displayed and eventually, after taking away too many pictures the application borked. Upon scanning through the man pages…

man feh

I discovered an option,

-R, --reload int

This would allow for reloading the directory at a specified interval, int, in seconds. I set it for 15 seconds and gave it another series of successful tests, adding and removing images remotely.

feh -Y -x -q -D 5 -B black -F -Z -R 15 -r /home/pi/Pictures/

An explanation of the options:

-Y : Hide the mouse pointer

-x : Create borderless window

-q : quite, don’t report non-fatal errors

-D : Delay between slides

-B : background for transparent images “black” is the value

-F : Fullscreen

-Z : Zoom pictures to screen size in full screen

-R : Reload the file list, after a period of time in seconds

-r : Recursively expand any directories in the path

It all behaved just as I had hoped it would, so much so that I had that natural dose of endorphins for this little success. It was good to see that the Pi was doing just what I needed it to do.

Add FTP Service

Since it is likely there will be a Windows machine accessing the Pi, I wanted to make adding and removing images is as simple as possible. The best solution, I find, is to set up an ftp server. I tried using sftp but that is not something the Windows file manager can do.

I decided that I would go with proftp as that is the one for which I am most familiar.

sudo apt-get install proftpd-basic

Checked the status of the server, post install

systemctl status proftpd

The service reported that it was running and active. Should that not be the case for you simply run this to start and enable the service:

sudo systemctl start ssh
sudo systemctl enable ssh

Since this is an internal ftp server on a RaspberryPi with no need for multiple users. The default “pi” user was adequate and I used those credentials for ftp access.

Autostart Slideshow on Boot

I didn’t want to have to have anyone fiddle with the Pi should it lose power. It just needs to work. A script was necessary.

Created the folder bin in the home directory, because, that is just where I like to stick my scripts.

mkdir ~/bin

Changed Directory into that folder

cd ~/bin

Created script with all the right bits in my slideshow

nano slideshow.sh

Copy and paste this into the nano editor

#!/bin/bash

feh -Y -x -q -D 8 -B black -F -Z -R 120 -r /home/pi/Pictures/

Save it: Ctrl+o, Enter

Exit nano: Ctrl+x

Next you have to make the script executable

chmod +x slideshow.sh

Now it is possible to run the command in terminal

Since I want this thing to basically just be an appliance where you plug it in and it just does its thing. I need to make this script run when the RaspberryPi starts up.

To do this, I will use my trusty nano editor to edit the desktop startup

nano ~/.config/lxsession/LXDE-pi/autostart

Scroll to the bottom of this script and add this to the very end:

@/home/pi/bin/slideshow.sh

Save and Exit

Reboot the machine to test.

sudo systemctl reboot

Success.

Disable Screen Blanking

As I was testing the slide show program, I discovered that the screen blanks out after a period of time. That is an unacceptable state for this device. Sure, it makes it energy star compliant but it makes it real hard for people to see information from it. The fix is easy, though, it would have been easier if it was a point and click option in Raspbian.

Back in the terminal:

sudo nano /etc/lightdm/lightdm.conf

Look for the heading

[Seat:*]

At the end of that rather large block of “options” add this line:

xserver-command=X -s 0 -dpms

Reboot the machine and test to see if it performs as expected. For me, this worked exactly as expected and I now call the project complete

Syncthing Addition

In order to keep things a bit simpler for the interested parties. I added Syncthing to the RaspberryPi. Just Syncthing, not the GTK GUI. The problem with the setup was that the browser would open up and cover up the slideshow, which, do an average observer could look like an error. The solution, was another autostart modification:

nano ~/.config/lxsession/LXDE-pi/autostart

I added this line:

@/usr/bin/syncthing/binary -no-browser

Now, should the RaspberryPi be rebooted, the Syncthing WebGUI will not sit in front of feh.

Final Thoughts

I am very glad the Internet exists with so many others describing how they solved their problems. I feel like I cheated because I was able to pick different solutions and mash them up to satisfy my requirements for a properly fitting and robust solution.

RPi3_slideshow

With rebooting the machine, I am rather impressed by how quickly the system goes from off to playing the slide show. A testiment to the work of the RaspberryPi folks hard work.

This was my first RaspberryPi experience and after completing the project, I am mostly happy with the whole process but ultimately, I think I would have preferred setting this all up on an x86 based machine. There were numerous little unique Pi niggles that I found annoying that kind of reminded me of noodling around in Linux circa 2005. At the same time, it was kind of a nice throwback to the last decade in working through a myriad of challenges to have a properly working computer.

For the technical adventurous, I highly recommend playing around with Raspberry Pi devices. It is certainly a great little hobby machine to perform special tasks. At the end of this project, I can think of several other things that I would like to do with a Raspberry Pi or similar device to solve other problems that come to mind.

References

Instructables Easy Raspberry Pi Screensaver Slideshow

Raspbian Download

Etcher

feh – Linux man page

How to Disable the Blank Screen on Raspberry Pi (Raspbian)

ProFTP.org

Geek3D.com Disable the Blank Screen on RaspberryPi