Author Archives: Helen Lynn

The Nest Box: DIY Springwatch with Raspberry Pi

via Raspberry Pi

Last week, lots and lots of you shared your Raspberry Pi builds with us on social media using the hashtag #IUseMyRaspberryPiFor. Jay Wainwright from Liverpool noticed the conversation and got in touch to tell us about The Nest Box, which uses Raspberry Pi to bring impressively high-quality images and video from British bird boxes to your Facebook feed.

Jay runs a small network of livestreaming nest box cameras, with three currently sited and another three in the pipeline; excitingly, the new ones will include a kestrel box and a barn owl box! During the spring, all the cameras stream live to The Nest Box’s Facebook page, which has steadily built a solid following of several thousand wildlife fans.

A pair of blue tits feeds their chicks in a woolly nest

The Nest Box’s setup uses a Raspberry Pi and Camera Module, along with a Raspberry Pi PoE HAT to provide both power and internet connectivity, so there’s only one cable connection to weatherproof. There’s also a custom HAT that Jay has designed to control LED lights and to govern the Raspberry Pi Camera Module’s IR filter, ensuring high-quality images both during the day and at night. To top it all off, he has written some Python code to record visitors to the nest boxes and go into live streaming mode whenever the action is happening.

As we can see from this nest box design for swifts, shown on the project’s crowdfunding profile, plenty of thought has evidently been put into the design of the boxes so that they provide tempting quarters for their feathered occupants while also accommodating all the electronic components.

Follow The Nest Box on Facebook to add British birds into your social media mix — whatever you’ve got now, I’ll bet all tomorrow’s coffees that it’ll be an improvement. And if you’re using Raspberry Pi for a wildlife project, or you’ve got plans along those lines, let us know in the comments.

The post The Nest Box: DIY Springwatch with Raspberry Pi appeared first on Raspberry Pi.

Growth Monitor pi: an open monitoring system for plant science

via Raspberry Pi

Plant scientists and agronomists use growth chambers to provide consistent growing conditions for the plants they study. This reduces confounding variables – inconsistent temperature or light levels, for example – that could render the results of their experiments less meaningful. To make sure that conditions really are consistent both within and between growth chambers, which minimises experimental bias and ensures that experiments are reproducible, it’s helpful to monitor and record environmental variables in the chambers.

A neat grid of small leafy plants on a black plastic tray. Metal housing and tubing is visible to the sides.

Arabidopsis thaliana in a growth chamber on the International Space Station. Many experimental plants are less well monitored than these ones.
(“Arabidopsis thaliana plants […]” by Rawpixel Ltd (original by NASA) / CC BY 2.0)

In a recent paper in Applications in Plant Sciences, Brandin Grindstaff and colleagues at the universities of Missouri and Arizona describe how they developed Growth Monitor pi, or GMpi: an affordable growth chamber monitor that provides wider functionality than other devices. As well as sensing growth conditions, it sends the gathered data to cloud storage, captures images, and generates alerts to inform scientists when conditions drift outside of an acceptable range.

The authors emphasise – and we heartily agree – that you don’t need expertise with software and computing to build, use, and adapt a system like this. They’ve written a detailed protocol and made available all the necessary software for any researcher to build GMpi, and they note that commercial solutions with similar functionality range in price from $10,000 to $1,000,000 – something of an incentive to give the DIY approach a go.

GMpi uses a Raspberry Pi Model 3B+, to which are connected temperature-humidity and light sensors from our friends at Adafruit, as well as a Raspberry Pi Camera Module.

The team used open-source app Rclone to upload sensor data to a cloud service, choosing Google Drive since it’s available for free. To alert users when growing conditions fall outside of a set range, they use the incoming webhooks app to generate notifications in a Slack channel. Sensor operation, data gathering, and remote monitoring are supported by a combination of software that’s available for free from the open-source community and software the authors developed themselves. Their package GMPi_Pack is available on GitHub.

With a bill of materials amounting to something in the region of $200, GMpi is another excellent example of affordable, accessible, customisable open labware that’s available to researchers and students. If you want to find out how to build GMpi for your lab, or just for your greenhouse, Affordable remote monitoring of plant growth in facilities using Raspberry Pi computers by Brandin et al. is available on PubMed Central, and it includes appendices with clear and detailed set-up instructions for the whole system.

The post Growth Monitor pi: an open monitoring system for plant science appeared first on Raspberry Pi.

Tracking the Brecon Beacons ultramarathon with a Raspberry Pi Zero

via Raspberry Pi

On my holidays this year I enjoyed a walk in the Brecon Beacons. We set out nice and early, walked 22km through some of the best scenery in Britain, got a cup of tea from the snack van on the A470, and caught our bus home. “I enjoyed that walk,” I thought, “and I’d like to do one like it again.” What I DIDN’T think was, “I’d like to do that walk again, only I’d like it to be nearly three times as long, and it definitely ought to have about three times more ascent, or else why bother?”

Alan Peaty is a bit more hardcore than me, so, a couple of weekends ago, he set out on the Brecon Beacons 10 Peaks Ultramarathon: “10 peaks; 58 kilometres; 3000m of ascent; 24 hours”. He went with his friend Neil and a Raspberry Pi Zero in an eyecatching 3D-printed case.

A green 3D-printed case with a Raspberry Pi sticker on it, on a black backpack leaning against a cairn. In the background are a sunny mountain top, distant peaks, and a blue sky with white clouds.

“The brick”, nestling on a backpack, with sunlit Corn Du and Pen y Fan in the background

The Raspberry Pi Zero ensemble – lovingly known as the brick or, to give it its longer name, the Rosie IoT Brick or RIoT Brick – is equipped with a u-blox Neo-6 GPS module, and it also receives GPS tracking info from some smaller trackers built using ESP32 microcontrollers. The whole lot is powered by a “rather weighty” 20,000mAh battery pack. Both the Raspberry Pi and the ESP32s were equipped with “all manner of additional sensors” to track location, temperature, humidity, pressure, altitude, and light level readings along the route.

Charts showing temperature, humidity & pressure, altitude, and light levels along the route, together with a route map

Where the route crosses over itself is the most fervently appreciated snack van in Wales

Via LoRa and occasional 3G/4G from the many, many peaks along the route, all this data ends up on Amazon Web Services. AWS, among other things, hosts an informative website where family members were able to keep track of Alan’s progress along windswept ridges and up 1:2 gradients, presumably the better to appreciate their cups of tea and central heating. Here’s a big diagram of how the kit that completed the ultramarathon fits together; it’s full of arrows, dotted lines, and acronyms.

Alan, Neil, the brick, and the rest of their gear completed the event in an impressive 18 hours and one minute, for which they got a medal.

The brick, a small plastic box full of coloured jumper leads and other electronics; the lid of the box; and a medal consisting of the number 10 in large plastic characters on a green ribbon

Well earned

You can follow the adventures of this project, its antecedents, and the further evolutions that are doubtless to come, on the Rosie the Red Robot Twitter feed. And you can find everything to do with the project in this GitHub repository, so you can complete ultramarathons while weighed down with hefty power bricks and bristling with homemade tracking devices, too, if you like. Alan is raising money for Alzheimer’s Research UK with this event, and you can find his Brecon Beacons 10 Peaks JustGiving page here.

The post Tracking the Brecon Beacons ultramarathon with a Raspberry Pi Zero appeared first on Raspberry Pi.

A low-cost, open-source, computer-assisted microscope

via Raspberry Pi

Low-cost open labware is a good thing in the world, and I was particularly pleased when micropalaeontologist Martin Tetard got in touch about the Raspberry Pi-based microscope he is developing. The project is called microscoPI (what else?), and it can capture, process, and store images and image analysis results. Martin is engaged in climate research: he uses microscopy to study tiny fossil remains, from which he gleans information about the environmental conditions that prevailed in the far-distant past.

microscoPI: a microcomputer-assisted microscope

microscoPI a project that aims to design a multipurpose, open-source and inexpensive micro-computer-assisted microscope (Raspberry PI 3). This microscope can automatically take images, process them, and save them altogether with the results of image analyses on a flash drive. It it multipurpose as it can be used on various kinds of images (e.g.

Martin repurposed an old microscope with a Z-axis adjustable stage for accurate focusing, and sourced an inexpensive X/Y movable stage to allow more accurate horizontal positioning of samples under the camera. He emptied the head of the scope to install a Raspberry Pi Camera Module, and he uses an M12 lens adapter to attach lenses suitable for single-specimen close-ups or for imaging several specimens at once. A Raspberry Pi 3B sits above the head of the microscope, and a 3.5-inch TFT touchscreen mounted on top of the Raspberry Pi allows the user to check images as they are captured and processed.

The Raspberry Pi runs our free operating system, Raspbian, and free image-processing software ImageJ. Martin and his colleagues use a number of plugins, some developed themselves and some by others, to support the specific requirements of their research. With this software, microscoPI can capture and analyse microfossil images automatically: it can count particles, including tiny specimens that are touching, analyse their shape and size, and save images and results before prompting the user for the name of the next sample.

microscoPI is compact – less than 30cm in height – and it’s powered by a battery bank secured under the base of the microscope, so it’s easily portable. The entire build comes in at under 160 Euros. You can find out more, and get in touch with Martin, on the microscoPI website.

The post A low-cost, open-source, computer-assisted microscope appeared first on Raspberry Pi.

Argon ONE: a super case for your Raspberry Pi

via Raspberry Pi

The friendly people at Argon40, one of our Approved Resellers in Hong Kong, have an already-successful Kickstarter on the go for their Argon ONE Raspberry Pi case. I’ve got one of them on my desk at the moment. It’s a very pleasing object. “That’s quite nice,” enthuses Gordon, who isn’t very good at enthusing.

The Argon ONE: look at the shiny!

The Argon ONE is a nifty little aluminium-alloy case that offers well thought-through cable, power, and temperature management. We chatted to Joseph from Argon40 about the team’s development process, and he explained:

When we started the project, we initially designed the product to suit our needs based on our experiences of playing around with the Raspberry Pi. We wanted a case that is nice to look and at the same time has all the basic features that we loved about the Raspberry Pi: small footprint, access to GPIO, low power consumption. Then we looked into the nice-to-have stuff like good heat dissipation for better performance, a proper shut-down, and a form factor that is elegant but not extravagant.

Clicky magnets

What I find particularly satisfying about the Argon ONE is its GPIO access. It has a neat recess with clear pin labels and access to an inbuilt, colour-coded header that connects to your Pi’s GPIO pins. When you’re not using the pins, you probably want to keep them away from dust, spilled coffee, and the gross candy-corn M&Ms that Alex sometimes throws at you for literally no reason. The Argon ONE helps you out here: a cover fits perfectly over the GPIO recess, held in place by magnets that are just exactly strong enough for the job. Being a fidgeter, I find that this lends itself to compulsive clicking.

*click* *click* *click*

Injection moulding

We like the build quality here, especially at this price point (it’s HK$157, US$20, or GB£15, and early-bird pledges are cheaper). The Argon40 team was keen to use alumnium for the upper part of the case, for robustness and durability along with good looks; that proved a challenge, given that they wanted to keep the case affordable. “Fortunately, we found a factory that allowed us to do aluminum-alloy injection instead of going for the CNC option,” says Joseph.

“Have you tried turning if off and on again?”

The Raspberry Pi doesn’t have a power button, and we hear a lot from people who’d like it to. Happily, our community has come up with lots of ways to add one: this case, for example. Once you install Argon40’s shutdown script in Raspbian, pressing the case’s power button will run the script to shut the Pi down cleanly, then cut the power.

Find out more on Kickstarter — this campaign is well worth a look if you’re after a decent case. Back to Joseph for the last word, with which we heartily agree:

At the end of the day, our goal is for people to have their Raspberry Pis on top of their work desks, study tables, and workstations and in their living rooms, instead of keeping their barebones Pi tucked inside a drawer. Because as the saying goes, “Out of sight, out of mind,” which means that if they don’t see their Raspberry Pi, they won’t be able to tinker around with it or play with it to create projects.

The post Argon ONE: a super case for your Raspberry Pi appeared first on Raspberry Pi.

Take a photo of yourself as an unreliable cartoon

via Raspberry Pi

Take a selfie, wait for the image to appear, and behold a cartoon version of yourself. Or, at least, behold a cartoon version of whatever the camera thought it saw. Welcome to Draw This by maker Dan Macnish.

Dan has made code, instructions, and wiring diagrams available to help you bring this beguiling weirdery into your own life.

raspberry pi cartoon polaroid camera

Neural networks, object recognition, and cartoons

One of the fun things about this re-imagined polaroid is that you never get to see the original image. You point, and shoot – and out pops a cartoon; the camera’s best interpretation of what it saw. The result is always a surprise. A food selfie of a healthy salad might turn into an enormous hot dog, or a photo with friends might be photobombed by a goat.

OK. Let’s take this one step at a time.

Pi + camera + button + LED

Draw This uses a Raspberry Pi 3 and a Camera Module, with a button and a useful status LED connected to the GPIO pins via a breadboard. You press the button, and the camera captures a still image while the LED comes on and stays lit for a couple of seconds while the Pi processes the image. So far, so standard Pi camera build.

Interpreting and re-interpreting the camera image

Dan uses Python to process the captured photograph, employing a pre-trained machine learning model from Google to recognise multiple objects in the image. Now he brings the strangeness. The Pi matches the things it sees in the photo with doodles from Google’s huge open-source Quick, Draw! dataset, and generates a new image that represents the objects in the original image as doodles. Then a thermal printer connected to the Pi’s GPIO pins prints the results.

A 28 x 14 grid of kangaroo doodles in dark grey on a white background

Kangaroos from the Quick, Draw! dataset (I got distracted)

Potential for peculiar

Reading about this build leaves me yearning to see its oddest interpretation of a scene, so if you make this and you find it really does turn you or your friend into a goat, please do share that with us.

And as you can see from my kangaroo digression above, there is a ton of potential for bizarro makes that use the Quick, Draw! dataset, object recognition models, or both; it’s not just the marsupials that are inexplicably compelling (I dare you to go and look and see how long it takes you to get back to whatever you were in the middle of). If you’re planning to make this, or something inspired by this, check out Dan’s cartoonify GitHub repo. And tell us all about it in the comments.

The post Take a photo of yourself as an unreliable cartoon appeared first on Raspberry Pi.