Nothing says friendship like a reverse engineering challenge on unknown terrain as a birthday present. When [Rikaard] turned 25 earlier this year, his friend [Veydh] put together a Capture the Flag challenge on an ESP8266 for him. As a software guy with no electronics background, [Rikaard] had no idea what he was presented with, but was eager to find out and to document his journey.
Left without guidance or instructions, [Rikaard] went on to learn more about the ESP8266, with the goal to dump its flash content, hoping to find some clues in it. Discovering the board is running NodeMCU and contains some compiled Lua files, he stepped foot in yet another unknown territory that led him down the Lua bytecode rabbit hole. After a detour describing his adjustments for the ESP’s eLua implementation to the decompiler he uses, his quest to capture the flag began for real.
While this wasn’t [Rikaard]’s first reverse engineering challenge, it was his first in an completely unknown environment outside his comfort zone — the endurance he demonstrated is admirable. There is of course still a long way down the road before one opens up chips or counts transistors in a slightly more complex system.
An urban planner once told me that every car requires at least four times as much space as they actually occupy. Each needs a spot on the roads, and three available parking spaces: one at home, one at work, and one to shop. Motorcycles are much smaller, but they still spend most of their time parked.
Motorcycles are the primary means of transport in Southeast Asia, and learning to safely drive one is an essential part of adapting to life here. Assuming it’s not pouring rain and you’re not flooded past your ankles, it’s actually quite a pleasant experience… until you have to park.
Unlike the parking lots you may be familiar with, there’s no expectation that your bike won’t be moved. In fact, it might very well end up on another floor, in another parking lot, or behind hundreds of impassable parked bikes on the roof. In the latter case, the attendant will shrug and suggest you come back in a few hours. Eventually, this won’t even register as a frustration – you will simply reason that there are plenty of other things that are more convenient here, like the weather (recent typhoon aside) or unlimited symmetrical fiber to the home for USD 5 a month.
That being said, with a little technology the problem could be lessened a bit while waiting for automated parking lots to become commonplace. On rare occasions I see people with little radio emitters that make their headlights flash, but they’re not terribly common here and require carrying yet another thing on my already full key chain (homes here typically use several different locks). It seemed pretty easy to pull off something similar using my smart phone with an ESP8266 running NodeMCU. I had been meaning to try out the sleep modes to save battery power anyway, so off I went.
Continue reading “Finding Your Motorbike Using Wi-Fi”
Smart Christmas trees may soon come to mean something more than a fashionably decorated tree. Forging ahead with this new definition, [Ayan Pahwa], with help from [Akshay Kumar], [Anshul Katta], and [Abhishek Maurya] turned their office’s Christmas Tree into an IoT device you can watch live!
As an IoT device, the tree relies on the ever-popular ESP8266 NodeMCU — activated and controlled by Alexa, as well as from a web page. The LEDs for the tree — and the offline-only tree-topper controlled by an Arduino Pro Mini — are the similarly popular Neopixels.
Continue reading “An IoT Christmas Tree For Your Hacker-Mas Celebrations”
Many automatic air fresheners are wasteful in that they either ceaselessly spritz the room, and manual ones need to be — well — manually operated. This will not do in an era of smart products, so Instructables user [IgorF2] has put together an air freshener that does more than check if you’re around before freshening things up.
The air freshener uses a NodeMCU LoLin and an MG 995 servomotor, with a NeoPixel ring acting as a status light. Be aware — when the servo is triggered there is a significant spike in current, so be sure you aren’t powering the air freshener from a PC USB port or another device. After modeling the air freshener’s case in Fusion 360 — files available here — [IgorF2] wired the components together and mounted them inside the 3D printed case.
Hardware work completed, [IgorF2] has detailed how to set up the Arduino IDE and ESP8266 support for a first-time-user, as well as adding a few libraries to his sketch. A combination of an Adafruit.IO feed and ITTT — once again, showing the setup steps — handles how the air freshener operates: location detection, time specific spritzing, and after tapping a software button on your phone for those particularly lazy moments.
Continue reading “The Smartest Air Freshener In The Room”
One of the tasks I dread is configuring a web server to send email correctly via Gmail. The simplest way of sending emails is SMTP, and there are a number of scripts out there that provide a simple method to send mail that way with a minimum of configuration. There’s even PHP
mail(), although it’s less than reliable.
Out of the box, Gmail requires OAUTH2 for authentication and to share user data, which has the major advantage of not requiring that you store your username and password in the application that requires access to your account. While they have an ‘allow less secure apps’ option that allows SMTP access for legacy products like Microsoft Outlook, it just doesn’t seem like the right way forward. Google documents how to interact with their API with OAUTH2, so why not just use that instead of putting my username and password in plaintext in a bunch of prototypes and test scripts?
Those are the thoughts that run through my head every time this comes up for a project, and each time I’ve somehow forgotten the steps to do it, also forgotten to write it down, and end up wasting quite a bit of time due to my own foolishness. As penance, I’ve decided to document the process and share it with all of you, and then also make it work on an ESP8266 board running the Arduino development environment.
Continue reading “Using Gmail with OAUTH2 in Linux and on an ESP8266”
Previously, we discussed how to apply the most basic hypothesis test: the z-test. It requires a relatively large sample size, and might be appreciated less by hackers searching for truth on a tight budget of time and money.
As an alternative, we briefly mentioned the t-test. The basic procedure still applies: form hypotheses, sample data, check your assumptions, and perform the test. This time though, we’ll run the test with real data from IoT sensors, and programmatically rather than by hand.
The most important difference between the z-test and the t-test is that the t-test uses a different probability distribution. It is called the ‘t-distribution’, and is similar in principle to the normal distribution used by the z-test, but was developed by studying the properties of small sample sizes. The precise shape of the distribution depends on your sample size. Continue reading “Statistics and Hacking: A Stout Little Distribution”
Feeding the cat should be a moment of magic, in which you bond with your adorable pet as she rubs seductively against your ankles. As you place the saucer of tender and moist meaty chunks on the floor, she bounds the length of your kitchen, excited expression on her little kitty face, and tail in the air.
If Hackaday made television adverts for cat food, we’d have it nailed. But our everyday reality involves the cute-as-heck Hackaday moggy turning into a persistent little pest when she decides it’s feeding time. [ThinkSilicon]’s friends had exactly this problem, with their furry friend’s preferred timing coming early in the morning. His solution? An automated cat feeder (translated) that dispenses kibbles from a hopper into the lucky mouser’s feeding dish.
The mechanical part of this endeavour is pretty straightforward, a servo moves a sliding piece of plywood with a hole cut in it across the bottom of a hopper full of cat food. Move the slide, dispense food down a chute to the waiting happy cat. Behind the scenes is an ESP8266 and a NodeMCU web service, through which feeding time can be either scheduled, or dispensed at will.
A happy cat means a happy owner, especially in the very early morning. Until that is the newly-sated creature decides to spread the love, jumping onto the owner’s bed in thanks and breathing cat-food-breath into their face. You really do have to love ’em!
We’ve shown you many cat food related projects in the past, including this Arduino take on the same idea. But why take the effort to trigger it yourself, when the cat can do it for you.