Mountain bike electronic suspension control

Dear community, I present to your attention a report on the work done by crossing my two hobbies: mountain biking and microelectronics.

So, in this article we will focus on the domestic development of an electronic mountain bike suspension control system. I will not torment you with a long introduction, right to the photo and video:

Now for the details.


With active pedaling on a two-suspension bike, a large share of the rider’s energy is spent on swinging the bike suspension, this is true for both the rear and front suspension. The rear suspension is subject to buildup almost always, the front suspension is mainly susceptible to pedal "standing". To make it clearer, imagine that you are standing next to a mountain bike that has a shock absorber and with your hands cyclically push / push the fork to the ground. To do this, you spend your energy, in the same way your energy is spent completely useless when you intensively pedal (for example, uphill). That is, if it were not for the “buildup” of shock absorbers, then all the energy would be spent on a useful thing - pedaling.

To solve this problem, numerous mechanical systems have been developed and introduced by various manufacturers of suspensions to dampen swing oscillations. Such as Motion Control from RockShox and Terralogic with ProPedal from FOX and others.
One cannot disagree that such mechanical systems certainly improve pedaling efficiency, but still do not completely eliminate energy dissipation, since all these solutions are “passive”.

In other words, mechanical systems do not take into account various external conditions, such as:

  • Movement speed
  • Cadence (Cadence)
  • Road surface character

Therefore, recently, large-scale bicycle manufacturers have developed “active” suspension control systems that take into account the external conditions listed above, thanks to various sensors:

  • Reed switches of speed and cadence
  • Acceleration sensors


As usual, this was accepted in our homeland, the task was set as follows: "To surpass foreign analogues in terms of performance characteristics several times!". Namely, these foreign divisions needed to be technologically overtaken and overtaken by the following indicators:

  1. Efficiency
  2. Dimensions
  3. Weight
  4. Ability to pair the system with bluetooth devices
  5. Intelligence
  6. Cheapness
  7. Availability
  8. Easy installation on existing equipment (plug and amort) with minimal modification
  9. Maintainability
  10. fault tolerance
  11. Possibility of hardware modifications (upgrade)
  12. The ability to modify the software part (upgrade)
  13. Single Charge Time

What was achieved:

1. Efficiency

Firstly, unlike foreign analogues, the control takes place simultaneously with the front and rear suspension.
Secondly, the hardware (microcontroller) allows you to implement any suspension control algorithms using publicly available tools, namely the C ++ programming language.

2. Dimensions

Specially selected components are so small that they can be placed in the plug stem. That is, the "brain" and the battery are located directly in the free space of the plug stem.
Thus, the size of the control element does not exceed 200 mm in length, and 22 mm in width. Actual sizes are approximately the following: 150x19.
The result is an elegant solution that is not even visible, and most importantly, it does not stick out and does not take the right place as it is done here (a bulky battery pack attached instead of a vital flask with water):

3. Weight

For those who are new to cycling, I will explain that weight is one of the main critical indicators for the equipment of a bicycle used in competitions. For this reason, particular attention has been given to this criterion. As a result, the weight was about 120 grams. This includes:
Servo drive (2 to 19 grams)38
Microcontroller boardten
Acceleration Sensor (Sprung)five
Acceleration sensor (unsprung, together with a sealed housing)15
Reed switches and magnets (2 to ~ 10)20
Control module (buttons)five
Total:128 grams
For reference: similar systems from foreign manufacturers weigh more than 300g.

4. Intelligence

Sensors and the possibility of programming a microcontroller allow you to implement any algorithm in a high-level c ++ language. As a result, the following features are currently implemented:

Manual mode

In this mode, the user can control the locks of the front and rear shock absorbers (jointly or separately) through the buttons located under the neoprene flu (rubber handle on the steering wheel). The operation of this mode can be seen in the video above. Despite its simplicity, this mode is a very convenient and useful feature, since it is very difficult to twist the shock absorber lock levers by hand when driving on a bike, especially at high speeds.

Semi-automatic mode

Mainly, this mode was developed for new shock absorbers from the company FOX , which have CTD levers. The main idea for this mode was to use the maximum mechanical characteristics of shock absorbers. That is, the system, depending on the sensors, must choose one of the three CTD (Climb-Trail-Descent) modes, giving all the logic to optimize the shock absorbers to the shock absorbers themselves. The mode is selected by turning the servo by a certain angle corresponding to a specific mode of operation of the shock absorber.

Currently, CTD modes are selected based on the angle of the bike. In other words, it works like this:
  • The bike goes uphill - Climb mode is activated.
  • The bike goes in a straight line - Trail mode.
  • The bike rides from the mountain - Descent mode.

The limits of the transition from mode to mode are adjustable (value of the slope catch in degrees). Also, the timeout for switching from mode to mode is also configurable.

This mode was designed specifically for one very respected rider (I will not name him because I agreed so), but at the last moment he changed his sponsor, and installing the system on his new bike became impossible.

Here's how it works:

Auto mode

This is the most interesting and difficult mode, since it is designed to maximize the efficiency of pedaling, by intelligently turning on / off shock absorber locks exactly at those times when it is necessary.

To implement this mode, several possible states of the system and the rules for the transition between them were identified, in short it looks like this:

The system using sensors:
  • acceleration sensor sprung (in the plug stem)
  • acceleration sensor unsprung (on fork trousers)
  • speed sensor
  • cadence sensor

Calculates the following indicators:
  • bump severity
  • buildup of the fork in a vertical plane and in a plane perpendicular to the movement
  • bike angle
  • speed
  • cadence

And based on these indicators, he selects the necessary state, moving from one to another:
System Status (Drive Mode)Shock Absorber Lock Status
rest modefull lock
fork swing pedalfull lock
pedaling fork shock unlocked, rear shock locked
free rolling modeall unlocked
mode of absorption of the bumpsall unlocked
Unfortunately, I have not yet shot a video on how this mode works in action. If I find a video recorder then I’ll try to shoot.
In the meantime, here is a video of the operation of this mode in statics:

5. Pairing the system with bluetooth devices

Thanks to the built-in bluetooth module, bluetooth devices can be connected to the system to display the telemetry of the system and to edit the settings.
At the moment, an android application has been written that acts as a bicycle computer and system settings editor. Here are some screenshots:

Manual mode:

CTD mode:

The red curve is the unfiltered data of the angle of inclination. The
blue curve is the angle of inclination obtained by applying the mathematical filter.
Climb / Descend gradient threshold - the limiting angles of operation of the Climb / Trail / Descend modes (adjusted by the slider or from the buttons on the steering wheel). Also shown on the chart in dashed lines.

Auto mode:

Red curve - readings of the accelerometer sensor suspended on the fork trousers (unsprung sensor)
Blue curve - readings of the accelerometer sensor inside the plug stem (sprung sensor)
Sprung / Unsprung severity threshold - limit values ​​of the sensors for locking the fork and amortization (sensitivity), when crossing unsprung values ​​- Amorth is blocked, at the intersection of the sprung value - the fork is blocked, provided that the sprung value is not exceeded, that is, there are no bumps (can be adjusted with the slider or from the buttons on the steering wheel). Also shown on the chart in dashed lines.

Editing settings:

The first two screenshots are servo / mode calibration. When dragging the sliders, the servo rotates in real time. This is just a small part of the available settings, only about 50 different parameters.

And here are some videos:

Manual mode:

CTD mode:

Servo Calibration:

Of course, in the future it will be possible to port the android application for iPhone and other devices with bluetooth.
Soon, I’ll get such a device with an android , and port the application to it. I think it will be very convenient:

5. Cheapness

All selected components can be purchased on ebay or at scanty prices. But to create this system I had to buy the same components at high prices, because I did not want to wait for delivery. The result is something like this:
ebay or dxlocal shops
Microcontroller300 rub1500 rub
Acceleration Sensor (x2)~ 300r2000 rub
Battery (good 18650)200 rub500 rub
Button Module~ 30r50 rub
Reed switchesis unknownunknown, used from old bike computers
Wires~ 100r400 rub
Servo drive (good, with metal gear, fastest, x2)600 rub1300r
Hinges (aircraft modeling)50 rub250 rub
Bluetooth module200 rub~ 500r
Solid State Relays, Li-Ion Battery Microcontroller, Small Things~ 300r~ 700r
Total:~ 2180r~ 7200r
I do not know how much the same system will cost from manufacturers, I can imagine that when it comes on sale it will cost an order of magnitude or even two more (with, presumably, lesser possibilities).

6. Availability

All components can be found in local stores, but at high prices. If you have time, you can buy on ebay and In addition, I doubt that similar foreign systems will be available with us even after a year.

7. Ease of installation on existing equipment (plug and amort) with minimal modification

Only one hole was drilled in the plastic wiki lock control cover and on the rear shock absorber lock lever. Bearing joints are screwed into these holes (standard joints for aircraft modeling).
Servos are mounted on plastic ties through the plastic and rubber brackets that I found at home (mostly from old bike computers).
As a result, most likely, this system can be put on any bike.

8. Maintainability

As you can see, the system consists of many components / modules, each of which is easily accessible and replaceable. One can imagine what will happen if the factory shock absorber breaks, most likely it will be impossible to repair, only replacing the fully shock absorber will save. And if the carriage flies (where did the manufacturers of a similar system place the cadence sensor)? It seems that the carriage will be ejected.

9. Fault tolerance

Even if the battery has run out or a wire has been broken or there is a fire on your bike, it still remains possible to switch the lock by hand. When, as an external system, in such cases (as far as I know) they will simply be jammed.
Servo drives are treated with a special rubber compound to ensure water resistance.

10. The possibility of modifications to the hardware (upgrade)

The system was built using a modular approach. At the moment, it remains possible to connect (free connectors) additional sensors (such as a heart rate monitor) and other devices (such as an LCD screen as a display of the functions of the bike computer).

11. Ability to modify the software part (upgrade)

The microcontroller can be flashed at any time with a new firmware written in c ++ via a USB cord. You can imagine how great it is when you can realize any whims.

The plans to implement the following:
  • All possible functions of the bike computer (whatever you like, including those that are available in the top models of bike computers).
  • A deeper analysis of the nature of the road surface (asphalt, grader, roots) to more accurately calibrate / calculate blocking characteristics.
  • Many other things (even an alarm) ...

12. Operating time on a single charge

Sleep mode

During downtime, the system consumes 1mA, thanks to the implanted three solid-state relays that disable servos, bluetooth and the i2c port (for the LCD screen, it is not used now) in sleep mode. Therefore, we can say that in an inactive state the system can stand idle for months (it all depends on the internal resistance of the battery, i.e. how much the battery can be in a charged state without load).
In sleep mode goes automatically by timeout. You can change the timeout time, or completely disable the use of sleep mode. From sleep mode, the system exits by cadence sensor event or by a button on the steering wheel.

Active mode

Again, thanks to the solid-state relays, all servos are switched off immediately after they have been activated. Thus, ~ 80% of the time of the servo drive is not connected to the circuit at all (the holding mode is not used, which greatly saves the charge).
In addition, the bluetooth module is disabled by an independent relay, so the operating time is increased without using bluetooth. Bluetooth is disconnected from the buttons on the steering wheel or by timeout. The timeout time is configurable.
Current consumptionService life from a separate charge (estimated)
Sleep mode1mA4 months (excluding internal battery resistance)
Active mode20mA6 days continuously
Active mode + bluetooth40mA2.5 days continuously
Active mode + servo150mA20 hours continuously, that is, if the servos worked continuously back and forth

13. Battery charge from a regular USB port

Thanks to the built-in microchip for charging Li-Ion batteries, the system can be charged from a regular USB cord. Time to full charge ~ 10 hours. Charging is automatically turned off if the battery is fully charged, thus eliminating the "recharge" of the battery, thereby increasing the battery life.

Instead of a conclusion:

The system was developed and tested for several months. At the moment, the work is not yet finished, it is a pity that the bicycle season has ended and now most likely the testing will have to be postponed until the next season. But now it is clearly felt that the system really allows you to optimize the shock absorbers, thereby helping the cyclist to show better results.

PS. Please note that this article is for guidance only, because the size of the article no longer allows you to describe in detail all the features of the system. If this article is of interest to the public, I promise to write a more detailed review of each part of the system, for example, interesting in my opinion:
  • work with accelerometers
  • signal filtering algorithms
  • system state model
  • the most effective way to interact with a bluetooth device
  • electrical circuits
  • and much more

I had to remove all the videos. For my comrades from LaPierre threaten me with lawsuits. The life situation now I have such that butt with the monster there are no opportunities. I'm sorry.

Recently, they sent an email with an official letter (with digital signature) saying that I violate their patents (by the way, the patents were received the day after I posted the video on YouTube, i.e. at that time my system was already working and I used it with might and main). Also in this letter they demand that I immediately stop selling the system (although I did not sell it to anyone), delete all the videos from YouTube (the most popular video has 35+ thousand views), and ( ATTENTION ) stop using it! Otherwise, they intend to “proceed with further legal action”.

It seems that the popularity of my system somewhat prevents them from selling their products. By the way, an article on bikerumor was published about the system .
This article for a month became the most popular, and gained 17 thousand views (not that a hubr but still :-)). And if you google “bike automatic suspension system” then the article about the system appears in the first place. So I seem to have spoiled a little their grandiose plans :)

Also popular now: