Chris Scott and Edwin Jones are running a Raspberry Jam in the Seminar Room of Guildford Library on the 4th June. The event runs from 11am-4pm and you can get more information and register for free tickets here. The video above is of their first Jam in March.
Random Simpsons episode from a Raspberry Pi Zero
Some things just need to be made. This is obviously what Stephen Coyle must have thought when he created this simple Simpsons episode shuffler with a Raspberry Pi Zero. When you press the yellow (naturally) button on top, the Pi randomly selects an episode which it then plays. Read more here.
Two motor controller boards for the Raspberry Pi from 4tronix – review
This weekend has given me time to work my way through my ‘review pile’. I’m almost to the bottom of the pile now – just one book to go. In the meantime, however, I tried out two motor controller boards from 4tronix.
Introduction
At the moment, there is a certain saturation in the motor controller board (MCB) market. There are boards available in a variety of form-factors and from various vendors and re-sellers. So, what can a new motor controller board, or indeed two, have to offer?
To answer this question, I got hold of a couple of new MCBs from Gareth at 4tronix who are based in Derby. Gareth’s solution to the market saturation is to build boards that are simply loaded with features. It’s certainly a compelling argument, so let’s see what he’s come up with this time!
RoboHAT
First up is the RoboHAT. This is a full HAT-sized, pre-assembled board with the following features:
- A 5V switching regulator that allows the board to be powered, and to power the Pi, from a 7-10V source.
- Dual H-bridge chip to drive two DC motors (or two pairs)
- Six 5V level shifted GPIO inputs with 3-pin connectors.
- Four 5V level-shifted GPIO outputs with 3-pin connectors (capable of driving servos).
- 4-pin header for an ultrasonic distance sensor.
- I2C breakout connector.
- Mounting screws and spacers to attach the HAT to the Raspberry Pi.
That’s an awful lot of features, and an awful lot of motors, especially if you use all the outputs for servos.
Installing the HAT is just a case of plugging it in. It has an EEPROM which configures the necessary overlays and turns on I2C. The instructions are simple – download an installation script and run it. Included in the downloads is a Python library and several test scripts.
I used these test scripts to try the HAT out. I connected up a 4xAA battery pack, two DC motors and two servos and ran some of the scripts and off the motors went. Very simple, very well-featured and, for £24 (inc VAT), very good value. You can get hold of one from the 4tronix website.
Picon Zero
Second on the review pile was the Picon Zero. This is, surprisingly enough, a Zero-form-factor board. It is pre-assembled and has the following features:
- Two full H-bridge motor drivers capable of giving up to 1.5A per channel (2A max) in forward and reverse directions.
- Six general purpose 5V 3-pin output channels that can be set as digital, PWM, servo or WS2812 (aka neopixels).
- Four general purpose 5V 3-pin inputs that can be set to digital, analog or DS18B20 (digital temperature sensor).
- Extra GPIO pins broken out into headers.
- A header for I2C.
- Motors can be powered either from the Pi’s 5V power source or from an external battery pack.
In my opinion, the Picon Zero is actually the superior board in comparison to the RoboHAT. Yes, there is a bit more manual configuration to do (in the form of a manual apt-get installation of the I2C libraries) and yes it is smaller and has fewer power options. And no, it doesn’t power the Pi from the battery pack.
However, it has more output channels (and therefore can be used to control more servo motors) and, intriguingly, it has analog inputs. The option to set the outputs to digital, PWM, servo or WS2812 is terrific and the ability to simply power motors from the Pi’s 5V power source gives you a lot of flexibility to ‘just use it’ without messing about with a battery pack if your motors are low-powered.
I plugged in two micro metal gear DC motors and four (!) servos into the board and powered them all from the Pi’s 5V line with no trouble.
Like the RoboHAT, the Picon Zero has an installation script that downloads a library and several example scripts. Using these scripts made my motors turn and I had a lovely little display of spinny things with very little effort.
The price is £16 (inc VAT), which is very reasonable, and you can get hold of one from the 4tronix website or from The Pi Hut.
Conclusion
These two boards from 4tronix are excellent. Sure, they are a little more expensive than some (but not all) other options, but the number of features on the boards, and the sheer technical beauty of the board design, are great compensation for that. Honestly, if I was looking for a motor controller board that could control loads of motors, there really isn’t much competition and I have no hesitation in recommending them.
Analog adventures – the RasPiO Analog Zero – a quick preview
Today has been all about trying new things. I tried out a great UPS board from Germany and then moved on to a new board from Alex Eames over at RasPiO.
The Analog Zero is a Pi Zero-sized board that will work with any 40-pin Raspberry Pi. It comes as a kit, to be soldered together. It’s easy enough soldering, even for a beginner with a steady hand. The central part of the kit is an MCP3008 analog to digital converter chip which pushes into a socket that you solder on. The MCP3008 gives you eight analog inputs to use.
So, what can you do with an analog to digital converter? You can use analog inputs and read them on the Raspberry Pi. Analog inputs include potentiometers, gas sensors, temperature sensors… in fact, an awful lot of sensors! As you probably know, one of my pet projects is the Picorder – a box full of sensors. It uses the same MCP3008 chip as the Analog Zero. So, I took some sensors (a soil moisture sensor and a pulse sensor) out of that project and added a new potentiometer and hooked them up with jumper wires.
I then wrote a simple script using GPIO Zero (which has in-built support for a variety of analog-to-digital converters) to read the inputs. To my delight, it just worked! I got readings from 0 to 1 for both sensors and the potentiometer.
So, you might guess by now that I think a lot of the Analog Zero. It makes reading analog sensors a piece of cake!
How can you get hold of one? Well, I’ve spoken to Alex and you can expect to hear news concerning availability in the next 2-3 weeks. I’ll let you know as soon as I know how to get hold of the board. Until then, feast your eyes on my test set-up, complete with messy table!
The Pi Podcast – new episode out, covering new camera, Pi Wars, other Raspberry Pi news
This time, the guys give their views on the new Pi camera, an IKEA Lack table retro gaming console, Pi Wars 2017 (about which, more later I hope!) and various other pieces of news. They also interview OKtoshi about his Pi distro ROKOS which deals with all kinds of cryptocurrencies. Listen to the podcast now. I really recommend The Pi Podcast – it’s the only one out there after all and, after 21 episodes (!), the guys seem to have hit their stride and relaxed into it.
Raspberry Pi UPS HAT from S.USV – review
I was sent one of these HATs to get some feedback and a review. I’m free to say what I like.
Introduction
Today, I’m reviewing the S.USV HAT from German company S.Seprotronic GmbH. The HAT comes in two flavours – Basic and Advanced. They sent me the Advanced one but I will point out the differences between the two versions where appropriate.
Functionality
The HAT’s primary use is as a UPS (uninterruptible power supply). It comes with a 300mAh LIPO battery that you plug into the board via a standard connector. The HAT has a charging circuit built-in so when you’re not using the battery, it is being charged. On the Advanced version (but not the basic) there is a connector and some extra circuitry to allow you to provide between 7 volts and 24 volts of power as an alternate power source. This could come in very handy if you had a power source such as solar panels, for example. The HAT comes with an extended GPIO header so you can carry on using the GPIO and the board communicates with the Pi via I2C so it doesn’t take up any GPIO ports. The I2C is even configurable, so if you should find a hardware conflict, you can change the I2C address via software. There are various indicator LEDs on the board that tell you the status of the UPS and the battery. The board is well-designed, well-laid out and clean. There are two buttons: ‘off’ and ‘on/reboot’. These are not labelled on the board, which is a shame as it is difficult to remember which one carries out which function.
Software
For a 40-pin Pi, the HAT automatically configures the ‘overlays’ required for it to work. There are instructions on how to configure the Pi manually if you need to. There is a daemon to be downloaded from their website. It is a small download and the instructions to install the package are clear and simple: easily within the capabilities of anyone who can follow some simple steps. The daemon is configurable and you have control over automatic start-up, automatic shutdown and various other options such as how long to wait to shutdown safely after switching over to battery power. My favourite option here is to switch the automatic on-battery shutdown off entirely. There is a safety feature which means that, even with this option off, if the battery goes below 10% the Pi is shutdown safely. Configuring the daemon is done via the command line, but most people who are going to be using this board should be comfortable enough in that environment. I found the configuration/status facility to be excellent and clear. If you are required to restart the daemon, it clearly tells you that you need to do so. There is a real-time clock on-board too which automatically installs itself when you boot for the first time.
Conclusion
This is one of these things that “just works”. I should say that I experienced a couple of software-based problems:
- The ‘off’ button didn’t work.
- The automatic, scheduled shutdown didn’t work when I tried it out, but I have a feeling that I did something wrong!
Overall, I have to say I’m very impressed with this HAT. A lot of thought has obviously gone into the hardware With the advanced model, the extra power supply flexibility is very welcome and the inclusion of a LIPO battery as standard is great as it saves you having to source one yourself. There is even an option on their website to purchase a 3000mAh battery if you want a bigger margin for safety.
The instructions and manual are very good and I had no trouble following them.
The software, even though it is command-line based, is very good and I liked the amount of configuration options available.
The HATs are currently only available from their website. The basic model costs 30 Euros (£24) and the advanced model costs 55 Euros (£44). Postage is on top of that. I would say that the extra £20 for the additional power circuitry is worth it if that’s what you need to make your project work. There are a lot of components on this HAT, so I think the prices are reasonable for what you get.
Recommended if you need a UPS!