Posts with «transportation hacks» label

Automatic Arduino Bicycle Shifter

One of the keys to efficient cycling performance is a consistent pedalling cadence. To achieve this the cyclist must always be in the correct gear, which can be tricky when your legs are burning and you’re sucking air. To aid in this task, [Jan Oelbrandt] created Shift4Me, an open-source Arduino powered electronic shifter.

The system consists of a hall effect sensor at the pedals to measure cadence, an Arduino controller, and a servo mechanism to replace the manual shifter. Everything is mounted in a small enclosure on the frame. The only way to get one is to build your own, so a forum is available for Shift4Me builders, where the BOM, instructions, code and other documentation is available for download. Most bikes should be easy to convert, and [Jan] invites builders to post their modifications and improvements.

Since the only input is the cadence sensor, we wonder if the system will interfere more than help when the rider has to break cadence. It does however include allowance to hold on the current gear, or reset to a starting gear by pushing a button. One major downside is that you will be stuck in a single gear if the battery dies since the manual shifter is completely removed.

As one of the oldest continuously used forms of mechanical transport, there is no shortage of bicycle-related hacks. Some of the more recent ones we’ve seen on Hackaday include e-bike with a washing machine motor, and a beautifully engineered steam-powered bicycle.

A Tidy Little OBD Display For Your Car

It’s likely that many readers will have an OBD dongle through which they can peer into the inner workings of their car, but the chances are that most of us will have restricted our curiosity to the Bluetooth or USB interface it was supplied with. Not [Frederico Souza Sant’ana] though, because he’s modified his OBD dongle to expose the serial lines between its ELM327 OBD chip and its Bluetooth chip. These go to an Arduino, which powers a small information display to supplement the car’s dashboard. This can display a range of readings as can be seen in the video below the break, he has it monitoring the battery, the various temperatures in the engine bay, and the ignition parameters.

All the software and hardware details can be found in a GitHub repository. In hardware terms it’s a surprisingly simple unit, but it serves to remind us that OBD sniffer dongles are more versatile than we might at first imagine, and good for a bit more than hooking up our smartphones via Bluetooth. If OBD is something you’d like to visit in more depth, in the past we’ve featured an open-source OBD interface, and a retrospective look at the protocol.

Hack a Day 13 Apr 19:30

Wiping Your Windscreen To The Beat

Nothing spoils your mood quite like your windscreen wipers not feeling it when the beat drops. Every major car manufacturer is focused on trying to build the electric self driving vehicle for the masses, yet ignoring this very real problem. Well [Ian Charnas] is taking charge, and has successfully slaved his car’s wipers to beat of its stereo.

Starting with the basics, [Ian] first needed to control the speed of the wiper motor. This was done using a custom power supply adapted from another project. The brain of the system is a Raspberry Pi 3B+ which runs a phase locked loop algorithm to sync the music and the motor. Detecting the beat turned out to be the most difficult part of the project, and from the research [Ian] did, there is no standard solution. He ended up settling on “madmom“, a Python audio and music signal processing library, which runs a neural net to detect the beat in real time. The Raspi sends the required PWM and Enable signals to an Arduino over serial, which in turn controls the power supply. The entire system was neatly integrated in the car, with a switch in the dash that connects the motor to the new power supply on demand, to allow the wipers to still be used normally (and safely).

[Ian] filed a provisional patent application for the idea, and will be putting it on auction on eBay soon, with the hope that some major car manufacturer would be interested. For older cars, you can shove an Arduino into the stereo, or do a super cheap bluetooth upgrade. Check out the video after the break.

Enforce Speed Limits with a Rusty Bike

They say you can’t manage what you can’t measure, and that certainly held true in the case of this bicycle that was used to measure the speed of cars in one Belgian neighborhood. If we understand the translation from Dutch correctly, the police were not enforcing the speed limit despite complaints. As a solution, the local citizenry built a bicycle with a radar gun that collected data which was then used to convince the police to enforce the speed limit on this road.

The bike isn’t the functional part of this build, as it doesn’t seem to have been intended to move. Rather, it was chosen because it is inconspicuous (read: rusty and not valuable) and simply housed the radar unit and electronics in a rear luggage case. The radar was specially calibrated to have less than 1% error, and ran on a deep cycle lead acid battery for around eight days. Fitting it with an Arduino-compatible shield and running some software (provided on the github page) is enough to get it up and running.

This is an impressive feat of citizen activism to provide the local police with accurate data to change a problem in a neighborhood. Not only was the technology put to good use, but the social engineering involved with hiding expensive electronics in plain sight with a rusty bicycle is a step beyond what we might have thought of as well.

Thanks to [Jo_elektro] for the tip!

This Cup Holder Crystal Ball Tells Your MPG Future

Hybrid vehicles, which combine an eco-friendly electric motor with a gasoline engine for extended range, are becoming more and more common. They’re a transitional technology that delivers most of the advantages of pure electric vehicles, but without the “scary” elements of electric vehicle ownership which are still foreign to consumers such as installing a charger in their home. But one element which hybrids are still lacking is a good method for informing the driver whether they’re running on petroleum or lithium; a way to check at a glance how “green” their driving really is.

[Ben Kolin] and his daughter [Alyssa] have come up with a clever hack that allows retrofitting existing hybrid vehicles with an extremely easy to understand indicator of real-time vehicle efficiency. No confusing graphics or arcade-style bleeps and bloops, just a color-changing orb which lives in the cup holder. An evolved version which takes the form of a smaller “dome light” that sits on the top of the dashboard could be a compelling aftermarket accessory for the hybrid market.

The device, which they are calling the ecOrb, relies on an interesting quirk of hybrid vehicles. The OBD II interface, which is used for diagnostics on modern vehicles, apparently only shows the RPM for the gasoline engine in a hybrid. So if the car is in motion but the OBD port is reporting 0 RPM, the vehicle must be running under electric power.

With a Bluetooth OBD adapter plugged into the car, all [Ben] and [Alyssa] needed was an Arduino Nano clone with a HC-05 module to read the current propulsion mode in real-time. With some fairly simple conditional logic they’re able to control the color of an RGB LED based on what the vehicle is doing: green for driving on electric power, purple for gas power, and red for when the gas engine is at idle (the worst case scenario for a hybrid).

Check out our previous coverage of OBD hacking on the Cadillac ELR hybrid if you’re looking to learn more about what’s possible with this rapidly developing class of vehicle

Building an Electric Scooter That’s Street Legal, Even in Germany

Sometimes a successful project isn’t only about making sure all the electrons are in the right place at the right time, or building something that won’t collapse under its own weight. A lot of projects involve a fair amount of social engineering to be counted as a success, especially those that might result in arrest and incarceration if built as originally planned. Such projects are often referred to as “the fun ones.”

For the past few months, we’ve been following [Bitluni]’s DIY electric scooter build, which had been following the usual trajectory for these things – take a stock unpowered scooter, replace the rear wheel with a 250 W hub motor, add an ESC, battery, and throttle, and away you go. Things took a very interesting turn, however, when his street testing ran afoul of German law, which limits small electric vehicles to a yawn-inducing 6 kph. Unwilling to bore himself to death thus, [Bitluni] found a workaround: vehicles that are only assisted by an electric motor have a much more reasonable speed limit of 25 kph. So he added an Arduino with a gyro and accelerometer module and wrote a program to only power the wheel after the rider has kicked the scooter along a few times – no throttle needed. The motor stops after a bit, needing another push or two to kick it back on. A brake lever kills the motor, as does laying the scooter on its side. It’s quite a clever design, and while it might not keep the Polizei at bay, you can’t say he didn’t try.

[Bitluni] has quite a range of builds, from software-defined television to bad 3D-scanners to precision wine glass whacking. You should check out his stuff.

Thanks for the tip, [Baldpower].

Cheating the Perfect Wheelie With Sensors And Servos

Everyone remembers popping their first wheelie on a bike. It’s an exhilarating moment when you figure out just the right mechanics to get balanced over the rear axle for a few glorious seconds of being the coolest kid on the block. Then gravity takes over, and you either learn how to dismount the bike over the rear wheel, or more likely end up looking at the sky wondering how you got on the ground.

Had only this wheelie cheating device been available way back when, many of us could have avoided that ignominious fate. [Tom Stanton]’s quest for the perfect wheelie led him to the design, which is actually pretty simple. The basic idea is to apply the brakes automatically when the bike reaches the critical angle beyond which one dares not go. The brakes slow the bike, the front wheel comes down, and the brakes release to allow you to continue pumping along with the wheelie. The angle is read by an accelerometer hooked to an Arduino, and the rear brake lever is pulled by a hobby servo. We honestly thought the servo would have nowhere near the torque needed, but in fact it did a fine job. As with most of [Tom]’s build his design process had a lot of fits and starts, but that’s all part of the learning. Was it worth it? We’ll let [Tom] discuss that in the video, but suffice it to say that he never hit the pavement in his field testing, although he appeared to be wheelie-proficient going into the project.

Still, it was an interesting build, and begs the question of how the system could be improved. Might there be some clues in this self-balancing motorized unicycle?

Adding Upgrades To A Stock Motorcycle

In today’s world of over-the-air firmware upgrades in everything from cars to phones to refrigerators, it’s common for manufacturers of various things to lock out features in software and force you to pay for the upgrades. Even if the hardware is the same across all the models, you can still be on the hook if you want to unlock anything extra. And, it seems as though Suzuki might be following this trend as well, as [Sebastian] found out when he opened up his 2011 Vstrom motorcycle.

The main feature that was lacking on this bike was a gear indicator. Even though all the hardware was available in the gearbox, and the ECU was able to know the current gear in use, there was no indicator on the gauge cluster. By using an Arduino paired with an OBD reading tool (even motorcycles make use of OBD these days), [Sebastian] was able to wire an LED ring into the gauge cluster to show the current gear while he’s riding.

The build is very professionally done and is so well blended into the gauge cluster that even we had a hard time spotting it at first. While this feature might require some additional lighting on the gauge cluster for Suzuki to be able to offer this feature, we have seen other “missing” features in devices that could be unlocked with a laughably small amount of effort.

Pavement Projection Provides Better Bicycle Visibility at Night

Few would question the health benefits of ditching the car in favor of a bicycle ride to work — it’s good for the body, and it can be a refreshing relief from rat race commuting. But it’s not without its perils, especially when one works late and returns after dark. Most car versus bicycle accidents occur in the early evening, and most are attributed to drivers just not seeing cyclists in the waning light of day.

To decrease his odds of becoming a statistics and increase his time on two wheels, [Dave Schneider] decided to build a better bike light. Concerned mainly with getting clipped from the rear, and having discounted the commercially available rear-mounted blinkenlights and wheel-mounted persistence of vision displays as insufficiently visible, [Dave] looked for ways to give drivers as many cues as possible. Noticing that his POV light cast a nice ground effect, he came up with a pavement projecting display using four flashlights. The red LED lights are arranged to flash onto the roadway in sequence, using the bike’s motion to sweep out a sort of POV “bumper” to guide motorists around the bike. The flashlight batteries were replaced with wooden plugs wired to the Li-ion battery pack and DC-DC converter in the saddle bag, with an Arduino tasked with the flashing duty.

The picture above shows a long exposure of the lights in action, and it looks very effective. We can’t help but think of ways to improve this: perhaps one flashlight with a servo-controlled mirror? Or variable flashing frequency based on speed? Maybe moving the pavement projection up front for a head-down display would be a nice addition too.

Arduino + Geometry + Bicycle = Speedometer

It is pretty easy to go to a big box store and get a digital speedometer for your bike. Not only is that no fun, but the little digital display isn’t going to win you any hacker cred. [AlexGyver] has the answer. Using an Arduino and a servo he built a classic needle speedometer for his bike. It also has a digital display and uses a hall effect sensor to pick up the wheel speed. You can see a video of the project below.

[Alex] talks about the geometry involved, in case your high school math is well into your rear view mirror. The circumference of the wheel is the distance you’ll travel in one revolution. If you know the distance and you know the time, you know the speed and the rest is just conversions to get a numerical speed into an angle on the servo motor. The code is out on GitHub.

Granted, reading a magnet, keeping time, and driving a servo isn’t exactly cutting edge. On the other hand, it made us think about what other kinds of outputs you could drive. We haven’t seen a nixie tube speedometer (well, not on a bicycle, anyway), for example. Or maybe one built with mechanical flip numbers like an old clock.

We have seen some with Arduinos and lots of LEDs (although, again, not really for a bicycle). This speedometer might still be our favorite, though.

 


Filed under: Arduino Hacks, transportation hacks