Simultaneous AP & Client On The Pi Zero W

The Raspberry Pi Zero W is a great platform for IoT projects, with a smattering of GPIO and onboard WiFi. However, security is an important consideration when it comes to the Internet of Things and it can be beneficial to keep your IoT devices on a separate network for safety’s sake. [Albert] wanted to do this all on board the Pi Zero W, and figured out how to get it acting as an access point and a client all at the same time.

[Albert] starts off with a fresh install of Raspbian Stretch, and sets the Pi up in OTG mode. This allows access to the Pi over a USB serial terminal. This is great for productivity when working on headless networking projects, as it can be frustrating trying to work with an SSH session that keeps dropping out when you change settings.

After creating a second named device (ap0) to go along with the one created automatically by the kernal (wlan0), DNSmasq is installed to act as a DHCP server for the AP. Hostapd is then installed to control the AP settings. Following this, like anything in Linux, a flurry of configuration files are edited to get everything humming along and starting up automatically after a reboot. For some reason, things don’t start up smoothly, so [Albert] has a cron job that fires 30 seconds after bootup and toggles the interfaces off and on again, and that’s done the trick.

It’s a useful hack, as it allows the Pi Zero to act as a hub for IoT devices, while also creating a bridge between them and the internet. Traffic can be managed to stop random internet users flicking your lights on and off and overspeeding your dishwasher.

We’ve seen the Pi Zero used for just about everything under the sun so far. If you’re just starting your own IoT build, perhaps you’d like to use the Pi Zero as a streaming camera?

 

Earth Rovers Explore Our Own Planet

While Mars is currently under close scrutiny by NASA and other space agencies, there is still a lot of exploring to do here on Earth. But if you would like to explore a corner of our own planet in the same way NASA that explores Mars, it’s possible to send your own rover to a place and have it send back pictures and data for you, rather than go there yourself. This is what [Norbert Heinz]’s Earth Explorer robots do, and anyone can drive any of the robots to explore whatever locations they happen to be in.

A major goal of the Earth Explorer robot is to be easy to ship. This is a smaller version of the same problem the Mars rovers have: how to get the most into a robot while having as little mass as possible. The weight is kept to under 500g, and the length, width, and height to no more than 90cm combined. This is easy to do with some toy cars modified to carry a Raspberry Pi, a camera, and some radios and sensors. After that, the robots only need an interesting place to go and an Internet connection to communicate with Mission Control.

[Norbert] is currently looking for volunteers to host some of these robots, so if you’re interested head on over to the project page and get started. If you’d just like to drive the robots, though, you can also get your rover fix there as well. It’s an interesting project that will both get people interested in exploring Earth and in robotics all at the same time. And, if you’d like to take the rover concept beyond simple exploration, there are other machines that can take care of the same planet they explore.

Continue reading “Earth Rovers Explore Our Own Planet”

Hackaday Links Column Banner

Hackaday Links: September 24, 2017

This is it. After twelve years we finally have a new Star Trek. Star Trek: Discovery (we’re using ST:DSC as the abbreviation) is airing right about when this post goes up. Next week, you’ll have to pay CBS $6USD a month to get your Star Trek fix, and today might be the last time a new episode of Star Trek is aired on broadcast TV ever. Enjoy it now, and hope the theme song doesn’t have lyrics. Also, hope The Orville is a tenth as good as a Galaxy Quest series could be.

What’s the best way to describe Delta Sigma PLLs? The Cat In The Hat (PDF, page 31). [Dr. Tune] found a Seuss reference in a TI app note. Personally, I’m a fan of hand-drawn cartoons, but we’ll take what we can get.

This weekend the Prusa I3 MK3 was announced. A good printer just got better. Now here’s the video.

The Raspberry Pi is a great media storage device, but it’s absolutely insufficient for audiophile tomfoolery. Here’s a neat Pi DAC/amp/DSP thingy. The VoltaStream turns the Raspberry Pi into a WiFi-connected pair of speakers with low-latency audio in and a TOSLINK connector.

SpaceX! There is serious consideration being given to starting an ‘Elon Musk column’ here on Hackaday. There will be SpaceX updates coming this week from the International Astronautical Congress in Adelaide. What will we find out? I don’t know bruh, but I just got back from Burning Man and I realized it was a whole lot like Mars and I was wondering Elon, like, have you ever been to Burning Man because it’s really dusty and a whole lot like Mars and there’s not much water… Please, organizers of the IAC, I implore you: give more idiots microphones. That was hilarious.

How was the World Maker Faire in New York this weekend? In one word, empty. Abnormally so. Maker Faire was not as crowded as last year, and you could actually move around. My agoraphobia didn’t kick in until the afterparties, and lines for the $5 bottles of water were short. Bay Area Faire attendance was down 16% from 2016-2017, and I would bet attendance for the NY Faire would be down a similar amount. Even a 10% decline in attendance would be noteworthy; the weather last year was cold and rainy and this year was beautiful. There are rumors, speculation, and people wondering how long Maker Faire will continue, but except for Intel pulling out of the maker market, no actual information. Millennials are killing the Maker Faire industry?

8-Channel ADC For The Raspberry Pi

The Raspberry Pi is a powerful embedded computing platform. However, for all its Linux-based muscle, it lacks one thing that even the simplest 8-bit microcontrollers usually have – analog-to-digital conversion. There are a great many ways to rectify this shortcoming, and [Chris Burgess] has brought us another – with an 8-channel ADC for the Raspberry Pi.

For the ADC, [Chris] chose the MCP3008, for its low cost and availability. In this configuration it offers 10-bit resolution and a maximum sampling rate of 200 kilosamples per second. Adafruit has a great guide on working with the MCP3008, too. With such a useful resource to hand, [Chris] was able to spin up a PCB to interface the chip to the Raspberry Pi using SPI. [Chris] took care to try to make the board to the official HAT specifications. As far as the physical aspects go, the board is to spec, however [Chris] omitted the EEPROM required for auto-configuration purposes. That said, the pads are on the board if someone wants to take the initiative to install one.

It’s a tidy build that provides something sorely missing from the Raspberry Pi, for a reasonable cost. [Chris]’s goal was to build something that would enable the measurement of analog sensors for a robot project; we’d love to hear your ideas for potential uses in the comments!

Arduino And Pi Breathe New Life Into Jukebox

What do you do when someone gives you a Wurlitzer 3100 jukebox from 1969, but keeps all the records? If you are like [Tijuana Rick], you grab an Arduino and a Rasberry Pi and turn it into a really awesome digital music player.

We’ll grant you, making a music player out of a Raspberry Pi isn’t all that cutting edge, but restoration and integration work is really impressive. The machine had many broken switches that had been hastily repaired, so [Rick] had to learn to create silicone molds and cast resin to create replacements. You can see and hear the end result in the video below.

[Rick] was frustrated with jukebox software he could find, until he found some Python code from [Thomas Sprinkmeier]. [Rick] used that code as a base and customized it for his needs.

There’s not much “how to” detail about the castings for the switches, but there are lots of photos and the results were great. We wondered if he considered putting fake 45s in the machine so it at least looked like it was playing vinyl.

Of course, you don’t need an old piece of hardware to make a jukebox. Or, you can compromise and build out a replica.

Continue reading “Arduino And Pi Breathe New Life Into Jukebox”

Hackaday Prize Entry: The $50 Raspberry Pi Smartphone

The Hackaday Prize is a challenge to create hardware, and the ZeroPhone is quite possibly the most popular project entered in the Hackaday Prize. What is it? It’s a mobile phone built around the Raspberry Pi Zero that can be assembled for about $50 in parts. Already, it’s a finalist in the Hackaday Prize best product competition, a finalist for the grand prize of $50,000, and one of the most popular projects on Hackaday.io of all time.

We took a look at the ZeroPhone early this year, and while there have been significant advances in this project, the philosophy is still pretty much the same. This is a mobile phone with a numeric keypad and a 128 x 64 pixel OLED display — basically the same user interface as a Nokia brick. The brain of the phone is a Raspberry Pi Zero wrapped in a PCB sandwich, with options for WiFi, Bluetooth, HDMI and audio outputs, a USB port, battery charging, and a ton of GPIOs that include ISM band radios, infrared receivers and transmitters, more flash storage, and anything else you can imagine. Basically, we’re looking at one of those modular, reconfigurable smartphone ideas, using a Raspberry Pi as the brains. Tech journos should be creaming themselves over this. We’re looking forward to [Arsenijs]’ cover story in Wired.

As with any Open Source / DIY cell phone, the big question surrounding the ZeroPhone is the cellular radio. 2G radios are cheap and plentiful, but the infrastructure is either coming down shortly, or already is down. A 3G radio is a must for a minimum viable product, and [Arsenijs] says there are provisions for replacing the 2G radio with a 3G module. Of course, 3G modules aren’t as capital-‘O’-Open as their technological predecessors, but that’s a discussion for another time.

Already the ZeroPhone is a huge success. There’s an actual team working on this project, the ZeroPhone subreddit is bigger than the Hackaday subreddit, there are newsletters, a wiki, and there will be a crowdfunding campaign ‘shortly’. This is one to look out for, and a very worthy project in the running for the 2017 Hackaday Prize.

Table-Top Self Driving With The Pi Zero

Self-driving technologies are a hot button topic right now, as major companies scramble to be the first to market with more capable autonomous vehicles. There’s a high barrier to entry at the top of the game, but that doesn’t mean you can’t tinker at home. [Richard Crowder] has been building a self-driving car at home with the Raspberry Pi Zero.

The self-driving model is trained by first learning from the human driver.

[Richard]’s project is based on the EOgma Neo machine learning library. Using a type of machine learning known as Sparse Predictive Hierarchies, or SPH, the algorithm is first trained with user input. [Richard] trained the model by driving it around a small track. The algorithm takes into account the steering and throttle inputs from the human driver and also monitors the feed from the Raspberry Pi camera. After training the model for a few laps, the car is then ready to drive itself.

Fundamentally, this is working on a much simpler level than a full-sized self-driving car. As the video indicates, the steering angle is predicted based on the grayscale pixel data from the camera feed. The track is very simple and the contrast of the walls to the driving surface makes it easier for the machine learning algorithm to figure out where it should be going. Watching the video feed reminds us of simple line-following robots of years past; this project achieves a similar effect in a completely different way. As it stands, it’s a great learning project on how to work with machine learning systems.

[Richard]’s write-up includes instructions on how to replicate the build, which is great if you’re just starting out with machine learning projects. What’s impressive is that this build achieves what it does with only the horsepower of the minute Raspberry Pi Zero, and putting it all in a package of just 102 grams. We’ve seen similar builds before that rely on much more horsepower – in processing and propulsion.