Let The Cards Fall Where They May, With A Robotic Rain Man

Finally,  a useful application for machine vision! Forget all that self-driving nonsense and facial recognition stuff – we’ve finally got an AI that can count cards at the blackjack table.

The system that [Edje Electronics] has built, dubbed “Rain Man 2.0” in homage to the classic title character created by [Dustin Hoffman] for the 1988 film, aims to tilt the odds at the blackjack table away from the house by counting cards. He explains one such strategy, a hi-low count, in the video below, which Rain Man 2.0 implements with the help of a webcam and YOLO for real-time object detection. Cards are detected in any orientation based on their suit and rank thanks to an extensive training set of card images, which [Edje] generated synthetically via some trickery with OpenCV. A script automated the process and yielded a rich training set of 50,000 images for YOLO. A Python program implements the trained model into a real-time card counting application.

Rain Man 2.0 is an improvement over [Edje]’s earlier Tensor Flow card counter, but it still has limitations. It can’t count into a six-deck shoe as the fictional [Rain Man] could, at least not yet. And even though cheater’s justice probably isn’t all cattle prods and hammers these days, the hardware needed for this hack is not likely to slip past casino security. So [Edje] has wisely limited its use to practicing his card counting skills. Eventually, he wants to turn Rain Man into a complete AI blackjack player, and explore its potential for other games and to help the visually impaired.

Continue reading “Let The Cards Fall Where They May, With A Robotic Rain Man”

Yet Another Robotic Rubik’s Solver

The Rubik’s Cube was a smash hit when it came out in 1974, and continues to maintain a following to this day. It can be difficult to solve, but many take up the challenge. The Arduino Rubik’s Solver is a robot that uses electronics and maths to get the job done.

The system consists of computer-based software and a hardware system working in concert to solve the cube. Webcam images are processed on a computer which determines the current state of the cube, and the necessary moves required to solve it. The solving rig is constructed from steel rods, lasercut acrylic, and 3D printed parts, along with an Arduino and six stepper motors. The Arduino receives instructions from the solving computer over USB serial link. These are then used to command the stepper motors to manipulate the cube in the correct fashion.

It’s no speed demon, but the contraption is capable of solving a cube without any problems. Manipulation of the cube is reliable and smooth, and the build is neat and tidy thanks to its carefully designed components. Of course, there are now even Rubik’s Cubes that can solve themselves. Video after the break.

Continue reading “Yet Another Robotic Rubik’s Solver”

Raspberry Pi Camera With Smarts — Cloud Or Local?

[Mark West] gave an interesting presentation at last year’s GOTO Copenhagen conference. He shows how he took a simple Raspberry Pi Zero webcam and expanded it with AI. He actually added the intelligent features in two different ways: on in the Amazon cloud and another using the Intel Modvidius NCS USB stick directly connected to the USB. You can see the video below.

Local motion detection uses some open source software. You simply configure it using a text file and it even handles the video streaming. However, at that point, you just have a web camera — not amazing, nor very cost effective. However, you get a lot of false alarms with the motion detection software. A random cat walking past, clouds, trees, or even rain would push [Mark] an email and after 250 alert e-mails a day, [Mark] decided to make something better.

Continue reading “Raspberry Pi Camera With Smarts — Cloud Or Local?”

High-Style Ball Balancing Platform

If IKEA made ball-balancing PID robots, they’d probably look like this one.

This [Johan Link] build isn’t just about style. A look under the hood reveals not the standard, off-the-shelf microcontroller development board you might expect. Instead, [Johan] designed and built his own board with an ATmega32 to run the three servos that control the platform. The entire apparatus is made from a dozen or so 3D-printed parts that interlock to form the base, the platform, and the housing for the USB webcam that’s perched on an aluminum tube. From that vantage point, the camera’s images are analyzed with OpenCV and the center of the ball is located. A PID loop controls the three servos to center the ball on the platform, or razzle-dazzle it a little by moving the ball in a controlled circle. It’s quite a build, and the video below shows it in action.

We’ve seen a few balancing platforms before, but few with such style. This Stewart platform comes close, and this juggling platform gets extra points for closing the control loop with audio feedback. And for juggling, of course.

Continue reading “High-Style Ball Balancing Platform”

Cheap ESP32 Webcam

Looking for a cheap way to keep an eye on something? [Kevin Hester] pointed us to a way to make a WiFi webcam for under $10. This uses one of the many cheap ESP32 dev boards available, along with the Internet of Things platform PlatformIO and a bit of code that creates an RTSP server. This can be accessed by any software that supports this streaming protocol, and a bit of smart routing could put it on the interwebs. [Kevin] claims that the ESP32 camera dev boards he uses can be found for less than $10, but we found that most of them cost about $15. Either way, that’s cheaper than most commercial streaming cameras.

Continue reading “Cheap ESP32 Webcam”

Open Data Cam Combines Camera, GPU, And Neural Network In An Artisanal DIY Cereal Box

The engineers and product designers at [moovel lab] have created the Open Data Cam – an AI camera platform that can identify and count objects as they move through its field of view – along with an open source guide for making your own.

Step one: get out your ruler and utility knife. In this world of ubiquitous 3D-printers they’ve taken a decidedly low-tech approach to the project’s enclosure: a cut, folded, and zip-tied plastic box, with a cardboard frame inside to hold the electronic bits. It’s “splash proof” and certainly cheap to make, but we’re a little worried about cooling and physical protection for the electronics inside, as they’re not exactly cheap and rugged components.

So what’s inside? An Nvidia Jetson TX2 board, a LiPo battery with some charging circuitry, and a standard webcam. The special sauce, however, is the software, which is available on GitHub. [Moovel lab]’s engineers have put together a nice-looking wifi-accessible mobile UI for marking the areas where you’d like the software to identify and tally objects. The actual object detection and identification tasks are performed by the speedy YOLO neural network, a task the Nvidia board’s GPU is of course well suited for.

As the Open Data Cam’s unblinking glass eye gazes upon our urban environments, it will log its observations in an ancient and mysterious language: CSV. It’s up to you, human, to interpret this information and use it for good.

A summary video and build time lapse are embedded after the break.

Continue reading “Open Data Cam Combines Camera, GPU, And Neural Network In An Artisanal DIY Cereal Box”

Seeing A Webcam’s PCBs In A Whole Different Light

When it comes to inspection of printed circuits, most of us rely on the Mark I eyeball to see how we did with the soldering iron or reflow oven. And even when we need the help of some kind of microscope, our inspections are still firmly in the visible part of the electromagnetic spectrum. Pushing the frequency up a few orders of magnitude and inspecting PCBs with X-rays is a thing, though, and can reveal so much more than what the eye can see.

Unlike most of us, [Tom Anderson] has access to X-ray inspection equipment in the course of his business, so it seemed natural to do an X-ray enhanced teardown and PCB inspection. The victim for this exercise was nothing special – just a cheap WiFi camera of the kind that seems intent on reporting back to China on a regular basis. The guts are pretty much what you’d expect: a processor board, a board for the camera, and an accessory board for a microphone and IR LEDs. In the optical part of the spectrum they look pretty decent, with just some extra flux and a few solder blobs left behind. But under X-ray, the same board showed more serious problems, like vias and through-holes with insufficient solder. Such defects would be difficult to pick up in optical inspection, and it’s fascinating to see the internal structure of both the board and the components, especially the BGA chips.

If you’re stuck doing your inspections the old-fashioned way, fear not – we have tips aplenty for optical inspection. But don’t let that stop you from trying X-ray inspection; start with this tiny DIY X-ray tube and work your way up from there.

Thanks for the tip, [Jarrett].