Hackaday Prize Entry: A Cheap Robotic Microscope

The microscope is one of the most useful instruments for the biological sciences, but they are expensive. Lucky for us, a factory in China can turn out webcams and plastic lenses and sell them for pennies. That’s the idea behind Flypi – a cheap microscope for scientific experiments and diagnostics that’s based on the ever-popular Raspberry Pi.

Flypi is designed to be a simple scientific tool and educational device. With that comes the challenges of being very cheap and very capable. It’s based around a Raspberry Pi and the Pi camera, with the relevant software for taking snapshots, recording movies, and controlling a few different modules that extend the capabilities of this machine. These modules include a Peltier element to heat or cool the sample, a temperature sensor, RGB LED, LED ring, LED matrix, and a special blue LED for activating fluorescent molecules in a sample.

The brains behind the Flypi, [Andre Chagas], designed the Flypi to be cheap. He’s certainly managed that with a frame that is mostly 3D printed, and some surprisingly inexpensive electronics. Already the Flypi is doing real science, including tracking bugs wandering around a petri dish and fluorescence microscopy of a zebrafish’s heart. Not bad for a relatively simple tool, and a great entry for the Hackaday Prize.

Hackaday Links: July 24, 2016

Right now HOPE is dying down, and most of the Hackaday crew will be filtering out of NYC. It was a great weekend. The first weekend in August will be even better. We’re going to DEF CON, we’ll have people at VCF West, and a contingent at EMF Camp. If you’re going to EMF Camp, drop a line here. There will be Hackaday peeps wandering around a field in England, so if you see someone flying the Hackaday or Tindie flag, stop and say hi.

Raspberry Pi’s stuffed into things? Not all of them are terrible. The Apple Extended keyboard is possibly the best keyboard Apple ever produced. It’s mechanical (Alps), the layout is almost completely modern, and they’re actually cheap for something that compares well to a Model M. There’s also enough space inside the plastic to fit a Pi and still have enough room left over for holes for the Ethernet and USB ports. [ezrahilyer] plopped a Pi in this old keyboard, and the results look great. Thanks [Burkistana] for sending this one in.

We’ve been chronicling [Arsenijs] Raspberry Pi project for months now, but this is big news. The Raspberry Pi project has cracked 10k views on Hackaday.io, and is well on track to be the most popular project of all time, on any platform. Congrats, [Arsenijs]; it couldn’t happen to a better project.

A few months ago, [Sébastien] released SLAcer.js, a slicer for resin printers that works in the browser. You can’t test a slicer without a printer, so for the last few months, [Sébastien] has been building his own resin printer. He’s looking for beta testers. If you have experience with resin printers, this could be a very cool (and very cheap) build.

Anyone going to DEF CON? For reasons unknown to me, I’m arriving in Vegas at nine in the morning on Wednesday. This means I have a day to kill in Vegas. I was thinking about a Hackaday meetup at the grave of James T. Kirk on Veridian III. It’s about an hour north of Vegas in the Valley of Fire State Park. Yes, driving out to the middle of the desert in August is a great idea. If anyone likes this idea, leave a note in the comments and I’ll organize something.

Hackaday Prize Entry: An Internet Of Things Microscope

For their entry into the Citizen Scientist portion of the Hackaday Prize, the folks at Arch Reactor, the St. Louis hackerspace, are building a microscope. Not just any microscope – this one is low-cost, digital, and has a surprisingly high magnification and pretty good optics. It’s the Internet of Things Microscope, and like all good apparatus for Citizen Scientist, it’s a remarkable tool for classrooms and developing countries.

When you think of ‘classroom microscope’, you’re probably thinking about a pile of old optics sitting in the back of a storage closet. These microscopes are purely optical, without the ability to take digital pictures. The glass is good, but you’re not going to get a scanning stage when you’re dealing with 30-year-old gear made for a classroom full of sticky-handed eighth graders.

The Internet of Things Microscope includes a scanning stage that moves across the specimen on the X and Y axes, stitching digital images together to create a very large image. That’s a killer feature for a cheap digital microscope, and the folks at Arch Reactor are doing this with a few cheap stepper motors and stepper motor drivers.

The rest of the electronics are built around a Raspberry Pi, Raspberry Pi camera (which recently got a nice resolution upgrade), and a some microscope eyepieces and objectives. Everything else is 3D printed, making this a very cheap and very accessible microscope that has some killer features.

ArduCAM Introduces A Third Party Raspberry Pi

There are hundreds of ARM-based Linux development boards out there, with new ones appearing every week. The bulk of these ARM boards are mostly unsupported, and in the worst case they don’t work at all. There’s a reason the Raspberry Pi is the best-selling tiny ARM computer, and it isn’t because it’s the fastest or most capable. The Raspberry Pi got to where it is today because of a huge amount of work from devs around the globe.

Try as they might, the newcomer fabricators of these other ARM boards can’t easily glom onto the popularity of the Pi. Doing so would require a Broadcom chipset. Now that the Broadcom BCM2835-based ODROID-W has gone out of production because Broadcom refused to sell the chips, the Raspberry Pi ecosystem has been completely closed.

Things may be changing. ArduCAM has introduced a tiny Raspberry Pi compatible module based on Broadcom’s BCM2835 chipset, the same chip found in the original Raspberry Pis A, B, B+ and Zero. This module is tiny – just under an inch square – and compatible with all of the supported software that makes the Raspberry Pi so irresistible.

nano-rpi-cmio-backAlthough this Raspberry Pi-compatible board is not finalized, the specs are what you would expect from what is essentially a Raspberry Pi Zero cut down to a square inch board. The CPU is listed as, “Broadcom BCM2835 ARM11 Processor @ 700 MHz (or 1GHz?)” – yes, even the spec sheet doesn’t know how fast the CPU is running – and RAM is either 256 or 512MB of LPDDR2.

There isn’t space on the board for a 2×20 pin header, but a sufficient number of GPIOs are broken out to make this board useful. You will fin a micro-SD card slot, twin micro-USB ports, connectors for power and composite video, as well as the Pi Camera connector. This board is basically the same size as the Pi Camera board, making the idea of a very tiny Linux-backed imaging systems tantalizingly close to being a reality.

It must be noted that this board is not for sale yet, and if Broadcom takes offense to the project, it may never be. That’s exactly what happened with the ODROID-W, and if ArduCAM can’t secure a supply of chips from Broadcom, this project will never see the light of day.

Kansas City Maker Faire: Lawn Da Vinci Is The Droid You’re Looking For

Summer is now in full swing, which means that mowing the lawn once a week is starting to get old. So why not build a robot do it for you? That’s what [Blake Hodgson] did, and he’s never been happier. It only took him a couple of weeks of quality time at one of the local makerspaces.

[Blake] was showing off Lawn da Vinci at this year’s Kansas City Maker Faire. He had his own booth around the corner from Hammerspace, the shop where it all came together. [Blake] started with a standard push mower from a garage sale and designed a frame around it using OnShape. The frame is made from angle iron, so it’s strong enough that he can ride on the thing. To each his own, we say. The wheels and motors came from a mobility scooter and match the beefiness of the frame. These are powered by two 12v car batteries wired in series. He drives it around his yard with an R/C airplane controller.

lawnmower gutsLawn da Vinci’s brainpower comes from two Arduino Pro Minis and a Raspberry Pi. One Arduino controls the motors and the R/C signal from the remoteThe other runs some extra kill switches that keep the Lawn da Vinci out of trouble.

So what’s the Raspi for? Right now, it’s for streaming video from the webcam attached to a mast on the frame back to his phone. [Blake] says he has had some latency issues with the webcam, so there could be a pair of drone racing goggles in his future. He also plans to add a GPS logger and to automate part of the mowing.

Now, about those kill switches: there are several of them. You probably can’t have too many of these on a remote control spinning suburban death machine. Lawn da Vinci will stop grazing if it goes out of range of the remote or if the remote is turned off. [Blake] also wired up a dedicated kill switch to a button on the remote and a fourth one on a separate key fob.

The Lawn da Vinci is one of many example projects that [Blake] uses to showcase the possibilities of KC Proto, a company he started to help local businesses realize their ideas by offering design solutions and assistance with prototyping. Between mowings, [Blake] puts the batteries on a trickle charger. If you make your own robot lawn mower, you might consider building a gas and solar hybrid.

The Raspberry Pi 3 Compute Module Is On Its Way

The Raspberry Pi Foundation founder Eben Upton has revealed in an interview with PCWorld that there will be a new version of the organisation’s Compute Module featuring the faster processor from the latest Raspberry Pi 3 boards, and it will be available “In a few months”.

The Compute Module was always something of an odd one out among the Raspberry Pi range, being a stripped-out Raspberry Pi chipset on a SODIMM form factor card without peripherals for use as an embedded computer rather than the standalone card with all the interfaces we are used to in the other Pi boards. It has found a home as the unseen brains behind a selection of commercial products, and though there are a few interface boards for developers and experimenters available for it we haven’t seen a lot of it in the world of hackers and makers. Some have questioned its relevance when the outwardly similar Pi Zero can be had for a lower price, but this misses the point that the two boards have been created for completely different markets.

The Pi 3’s 1.2 GHz 64-bit quad-core ARM Cortex-A53 BCM2837 SoC will certainly up the ante in the Compute module’s market, but it will be interesting to see what changes if any they make to its form factor. The Foundation’s close ties with Broadcom mean that they have done an impressive job in maintaining backward compatibility at a hardware level between the different generations of their product, but it is unclear whether this extends to the possibility of the new module maintaining a pin-for-pin compatibility with the old. We’d expect this to be an unlikely prospect.

It is certain that we will see a new generation of exciting commercial products emerging based around the new module, but will we see it making waves within our domain? This will depend on its marketing, and in particular the price point and quantity purchase they set for it. The previous board when added to a Compute Module Development board was an expensive prospect compared to a Raspberry Pi Model B that became more unattractive still as newer Pi boards gained more capabilities. If they price this one competitively and perhaps if any cheaper open hardware breakout boards emerge for it, we could have a valuable new platform on our hands.

Here’s our coverage of the original Compute Module launch, back in 2014.

[via Liliputing and reddit].

BCM2837 image: By Jose.gil (Own work) [CC BY-SA 4.0], via Wikimedia Commons.

Code Craft – Embedding C++: Multitasking

We’re quite used to multitasking computer systems today. Our desktops run email, a couple of browsers in different workspaces, a word processor, and a few other applications, apparently all at once. Looking behind the scenes using a system monitor or task manager program reveals a multitude of other programs running in support of our activities. Of course, any given CPU is running a maximum of one program at a time. Multitasking is simply the practice of switching between active processes fast enough to give the illusion of simultaneity.

The roots of multiasking go way back. In the early days, when computers cost tons of money, the thought of an idle system was anathema. Teletype IO was slow compared to the processor, and leaving the processor waiting idle for a card reader to slurp in the next card was outrageous. The gurus of the time worked to fill that idle time with productive work. That eventually led to systems that would run multiple programs at one time, and eventually to more finely grained multitasking within a program.

Modern multitasking depends on support from the underlying API of an operating system. Each OS uses its own techniques, making it difficult to write portable code. The C++ 2011 standard increased the portability of the language by adding concurrency routines to the Standard Template Library (STL). These routines use the API of the OS. For instance, the Linux version uses the POSIX threading library, pthread. The result is a minimal, but useful, capability for building upon in later standards. The C++ 2017 standard development activities include work on parallelism and concurrency.

In this article, I’ll work through some of the facilities for and pitfalls in writing threaded code in C++.

Continue reading “Code Craft – Embedding C++: Multitasking”