Velo AI

All success stories

Smart bike light with road monitoring relies on Raspberry Pi’s capable low-power compute

Low-cost, low-power, compact and performant, Raspberry Pi Compute Module 4 is at the heart of Velo AI’s debut road safety product, which alerts cyclists to vehicle movements behind them.

SolutionRaspberry Pi Compute Module 4
Size of businessSME
IndustryTransport / leisure

With a core mission to improve safety for all forms of mobility through the use of smart technology, Pittsburgh-based Velo AI was co-founded by robotics expert Clarke Haynes and AI specialist Micol Marchetti-Bowick. Both have a background in autonomous vehicle technology for the likes of Uber, and sought to apply similar AI algorithms to assist cyclists. Completing the core team is Alison Treaster, who is leading commercial partnership and community-building efforts for the startup firm.

Velo AI’s debut product is Copilot, an AI-powered bike light and camera. Based around Raspberry Pi Compute Module 4, it can detect and distinguish nearby vehicles, understand when one is about to overtake, and identify an aggressive or distracted driver approaching dangerously – in which case, it issues audible and visual alerts for the cyclist and driver to help prevent dangerous situations and crashes.

The challenge

Aware of the limitations of existing bike cameras and vehicle detection devices, the Velo AI team sought to create a more sophisticated AI-based alternative to improve road safety for cyclists.

As an example, says Haynes, a radar-based device such as the Garmin Varia “can’t figure out if it’s a car behind you or a bus. And to a bicyclist, there’s a big difference in being passed by a Toyota Corolla versus being passed by a large municipal bus.” In addition, he points out, radar only measures radially: “Radars can tell you if something is approaching you, but they can’t tell you if something is going to pass you with ten feet of space or one foot of space.”

A person sits at a table concentrating on assembling Copilot units from components laid out covering the surface in front of them: battery packs, various PCBs, cameras, flex cables, enclosures

In moving from radar to a camera-based solution, the aim was to create a device that could tell the cyclist “a lot more about what’s going on in the world and do a lot of things that the radar can’t do.” The device would need to help cyclists by providing situational awareness and alerts about nearby vehicles. This includes the ability to distinguish, using computer vision algorithms, between different vehicle types, as well as to estimate their relative speed and to identify and predict driver behaviour.

The first step of developing Copilot’s AI algorithms was to collect a large amount of data from riding around a variety of road types, with a focus on interactions with vehicles. This process was aided by a beta-testing cohort of Pittsburgh cyclists – ranging from commuters to recreational riders – who were given a free prototype unit to test.

While the Velo AI team has extensive experience in the field of autonomous vehicles, there was a steep learning curve involved in creating and selling a brand new physical product. “Jumping in and figuring out what it takes to put together a hardware product has been a huge challenge for us,” admits Haynes. “So, OK, what’s the weatherproofness of this? How do we design a lens to focus light for a bike light?”

A major challenge lay in cramming the camera, LED lights, electronics, and battery pack into a compact and lightweight package. The device also needed to be powerful enough to run AI neural networks, yet with a relatively low power drain to enable it to be used for longer bike rides.

The solution

Raspberry Pi Compute Module 4 is in effect the brain of the Copilot, aided by a custom Hailo AI co-processor to run the neural networks required for the device’s computer vision. A fixed-lens Arducam camera is used to record video footage.

The Copilot is supplied with a mount to fix it to a bike’s seat post or saddle rail, with the camera facing rearward. The AI analyses the live video footage and, depending on the type of driver behaviour detected, custom alerts may be triggered – audible for the cyclist, and flashing LED light patterns to alert the driver behind.

Three main categories of vehicle behaviour are detected and used to trigger different alerts. ‘Following’ behaviour is “when a vehicle is following behind you, but not accelerating toward you,” explains Marchetti-Bowick. ‘Approaching’ is when a vehicle is accelerating relative to you: “It’s getting closer to you … and that can either be directly behind you, or it can be in an adjacent lane to you.” The third category is ‘overtaking’: “That’s when we think the vehicle is imminently going to pass you. And that’s probably the one you want to be most aware of, because that’s the closest proximity interaction that they’ll have with you as a cyclist.”

In addition, the device connects to a companion app on a smartphone which can be mounted on the bike’s handlebars to show the rider a simplified road view with the positions of nearby vehicles. The app also enables the user to download video footage of their rides.

Power to the unit is supplied by a rechargeable two-cell lithium-ion battery. With the Copilot consuming a mere 4–5 watts of power, that equates to around five hours of battery life.

Why Raspberry Pi?

The team experimented early on with Nvidia Jetson boards for the prototype Copilot, but found that they were too expensive and their GPUs too power-hungry, according to Haynes. “If you’re going to run GPUs full tilt, you’re talking about something that even in a Jetson … you’re going 10 to 20 watts. And then to have a battery to power something that’s going at 10 watts for many hours, because we want people to go for four- or five-hour bike rides with this, it was just too much heat, too much weight [due to a larger battery pack being required]. And that’s what really led us to the Raspberry Pi.”

The very first circuit board, before Velo AI partnered with contract manufacturer and Raspberry Pi Design Partner Hellbender, was very simple: “We plugged in the CM4 one side, we slotted in the M.2 Hailo on the other side, and then connected the camera. And we had everything we needed to just prove that the compute stack worked. Since then, it’s advanced more and more. But the mere fact that the CM4 is a separate discrete component that just works; we can use everything that’s on it, including the Wi-Fi and Bluetooth. That’s great for us to just get started.”

The search for running the AI with super-low power consumption led them to add a Hailo AI co-processor: “The combination of Raspberry Pi plus Hailo made things super-easy to prototype and develop,” says Haynes.

Shot from above of the rear of a bike leaning against an outdoor bench, with a Copilot fixed to the seat post with its red lights lit. The cyclist's forearm arm is in shot, extended and holding a phone showing the Copilot Companion App.

The results

The Copilot appeals to different types of cyclists, says Treaster. “There’s not a particular customer persona, but they want to support making streets safer because they’re using streets as a cyclist often.” Potential customers also include parents and spouses who care about the cyclist in their life and want something that’s going to keep them safer on the road. “We’ve had a lot of folks say, ‘I would buy this for my son or daughter, I would buy this for my husband’.”

With the added awareness it provides, the device has already become an essential aid for some cyclists, says Haynes. “We’ve got great feedback from early customers that they don’t like having to ride their bike without it on there.”

The team hopes that Copilot may have broader social benefits. “The number one reason people don’t bike more is they don’t feel safe,” notes Haynes. “And so our goal was, let’s get more people to bike, and let’s get them to bike more because they feel safe.”

A major bonus is that data gathered from Copilot devices can prove useful to aid local authorities and road safety organisations seeking to make cities and towns safer for cycling. “We are in the middle of starting a partnership with the city of Pittsburgh,” says Haynes, “where we’re going to deploy dozens of these Copilots with people that bike to work and use that to actually inform where do we need to improve the bike infrastructure?”

Another pilot scheme is planned for Roanoke, Virginia, reveals Treaster. “They are working on the Vision Zero campaign [with the eventual aim of zero deaths for pedestrians and cyclists]. And they said it would be great to be able to get any kind of data that’s specific to cycling before the legislation is passed to say we need to give cyclists three feet of space when passing.” Post-legislation data can then be analysed to see how it has affected driver behaviour.

“We’re absolutely interested in as much as we can do to get these devices out there and use this data to make cycling safer,” adds Haynes.