Rochester
Recom
Allegro

Magnetic Position Sensors Efficiently Drive E-Bike with Pedal-Assist Systems

ebike isolated on white background. Generative ai design.

By Dr. Shashank Wekhande, Sr. Manager, Systems Engineering, and Abhijit Phadke, Sr. Applications Engineer,Allegro MicroSystems

Abstract

Throttle and pedal-assistance features make thee-bike a preferred choice for short-distance transportation. In an e-bike, the required motor assistance is determined by pedal-rate measurement.This technical article describes two designs for the pedal-rate measurement: a design using a pair of one-dimensional (1D) magnetic position sensors,which is common;and a two-dimensional (2D) magnetic speed and direction sensor design. Typical application circuits, magnet arrangements, and sensors are discussed for each scheme. The 2D sensor design is shown to simplify pedal-assist system (PAS) module assembly and to reduce the bill of materials (BOM).

Introduction

E-bikes are environmentally friendly, fashionable, and recreationally fun, which has given rise to their tremendous popularity. An e-bike is a conventional bicycle with the addition of a rechargeable battery that powers a brushless DC (BLDC) motor.A controller using a pedal-assist algorithm estimates the power to be applied to the motor.An electronic control unit (ECU) controls the motor power based on inputs such as throttle, brakes,pedaling rate, and running speed of the e-bike.

Pedal-Assist System

The typical e-bike pedal-assist system (see Figure 1) makes it easier for the rider to pedal, ride faster, and climb uphill terrain. In turn, it reduces rider fatigue and enhances travel range. It consists of a motor attached to the wheel. An ECU controls the motor to power the e-bike when the rider starts to pedal.Pedal-assist is provided only when the rider starts pedaling and the e-bike attains a minimum speed.Two types of sensors are used in these applications: torque sensors measure the pedaling effort, force applied on the pedal; and pedal-assist sensors measure the pedaling rate.The PAS sensors are also known as cadence sensors. Torque sensors either use: strain gauge, to determine the force a rider exerts on the pedal; or the degree of twist generated in the drive shaft. The harder the rider pedals, the more power assistance the motor provides.

E-Bike_Pedal-Assist_System

Figure 1: E-Bike Pedal-Assist System

The pedal-assist sensor detects the speed and direction of the e-bike drive shaft. The sensor is required to provide speed data when pedaling is performed in the forward direction only.This is necessary to ensure the safety of the rider. The sensor is most commonly used in low-cost applications where the pedaling rate is a necessary input for motor startup and motor power control in an open loop.

The rider can generally choose the level of pedal assistance from three or more PAS selection settings (see Figure 2). A graph of the motor power versus pedaling rate with three PAS settings is shown in Figure 3: PAS0(not shown) is the no pedal-assist requirement, where the e-bike is used like a typical bicycle; PAS1 is the low pedal-assist requirement; PAS2 is mid-level; and PAS3 is high. As pedal assistance increases, the rider has to exert less power and can enjoy a comfortable ride.

Control unit of an accumulator for an electric bicycle with dark background

Control unit of an accumulator for an electric bicycle with dark background

Figure 2:PAS Selection Switch

PAS-Options

Figure 3: Pedal-Assist Selection (PAS) Options

Pedal-Assist Sensor

In a pedal-assist sensor, discrete magnets are placed symmetrically in housing that rotates with the main drive shaft. The sensor detects the rotation speed and direction of these magnets and provides the according square-wave output pulses. The faster the pedal rate, the higher the frequency of the output signal, which commands greater power assistance.

A pedal-assist sensor and a similar sensor assembly on an e-bike are shown in Figure 4. Pedal-assist sensors have a three-wire interface that requires a 5V protected supply, ground, and output wire. The output uses an open-drain configuration, soa pull-up resistor is required.

Mounting-and-Assembly

Figure 4: Pedal-Assist Sensor Mounting and Assembly

Legacy Design Using a Pair of 1D Position Sensor Latches

Pedal-assist sensor applications commonly use a microcontroller and two 1D magnetic position-sensor latches, such as the Allegro APS12202. An advanced, precision Hall-effect 1D planar latch with symmetrical magnetic switch points anda supply-voltage range of 3 to 24 V is offered in the APS12202. In this design, 12 magnets are used, so the output provides 12 square-wave pulses per revolution. All magnets are arranged with the north poles facing radially outward, toward the sensor IC.Two latch devices placed in quadrature provide phase-shifted pulses. The controller takes the outputs from the individual latches and provides outputs when pedaling is performed in the forward direction only.

The design is detailed in Figure 5, showing the magnet arrangement, magnetic field observed by the IC, and typical application circuit.The magnetic-field values plotted are normalized such that the maximum field received in the case of a 12-alternating-magnet arrangement is 1, as shown in Figure 6. The plotted graph is for three air gaps. Measured from IC surface to target surface, these air gaps are 1 mm, 2 mm, and 3 mm for AG1, AG2, and AG3, respectively.

1D-Position-Sensor-Latch-Design

Figure 5: Pedal-Assist Sensor Using­ 1D Position Sensor

Example-Mag-Arrangements

Figure 6: Magnet Arrangements with 2D Sensor APS 12205 and Magnetic Field Observed By IC

Simplified Design Using a Single 2D Magnetic Speed and Direction Sensor IC

 and production can be simplified, the BOM can be minimized, and duty cycle can be improved using a single 2D magnetic speed and direction sensor IC. The AllegroAPS12625, for example, is a single-chip, speed-and-direction output, Hall-effect latch in a tiny SOT-23-5 package. The speed and direction outputs of the APS12625 can be combined to provide a unique interface for an e-bike pedal-assist sensor. The APS12625 senses the quadrature (such as ZX) magnetic fields presented by magnets placed in a rotating target, which offers a near-50% duty-cycle measurement advantage compared to the 1D position-sensor latch design. The small-sized, simplified design of the APS12625 replaces the pair of latches and controller circuit used in 1D position-sensor latch design, thus reducing the BOM. The design is detailed in Figure 7, showing PCB assembly and typical application circuit providing the desired output without an additional circuit.

PAS-Design2

Figure 7: Pedal-Assist Sensor Using 2D Speed-and-Direction Sensor

In this design, using the example APS12625, outputs are wire-ANDed (see the application circuit in Figure 7, right). During forward-pedaling, direction output B is high when its internal MOSFET is open, so speed output A provides pulses; during reverse-pedaling, direction output B is low when its internal MOSFET is ON, so the output is pulled low. The output waveform of a pedal-assist sensor is shown in Figure 8.

Untitled

Figure 8: Output Waveform of Pedal-Assist Sensor

Magnet Arrangements for Simplified Design Using a Single 2-D Magnetic Speed and Direction Sensor

Two magnet arrangements and the according field wave forms observed by the IC are shown in Figure 6. The polarity of each magnet arrangement is marked(north, N; south, S), and simulations of X-direction and Z-direction flux-density are plotted for reference at three air-gap(AG) conditions. Flux density values are normalized such that the maximum field received in the case of the 12-alternating-magnet arrangement is 1. This normalization is performed to facilitate comparison of various magnet arrangements. The flux density values between 0 and 1 indicate south polarity; flux density values between 0 and –1 indicate north polarity.

AG1 is a 1 mm air gap between the sensor IC and the target surface. Likewise, AG2 and AG3 correspond to 2 mm and 3 mm air gaps, respectively. The benefits and challenges of these arrangements are summarized in Table 1.

Table 1: Magnet Arrangements—Benefits and Challenges

Magnet Arrangement
Benefits
Challenges
Sensor Recommendation
A
12 magnets, vertically placed with alternating polarity
  • Higher flux-density values
  • 12 pulses/revolution
  • Nearly 50% duty cycle
  • Flux-density slope is flat.
  • 12 magnets for 12 pulses/revolution 
2D latch with medium sensitivity.
B
6 magnets, horizontally placed with cascading south and north poles
  • 6 magnets for 12 pulses/rev
  • Flux density slope is relatively sharper
  • Less suited for high AG requirement
  • Wider duty-cycle variation
2D latch with higher sensitivity 

 

Conclusion

E-Bikes are major contributors to modern personal mobility. E-bikes provide riding comfort delivered by the power-assist function.The effectiveness of the PAS depends on pedal-assist sensors that provide pedal-speed input to the controller. Pedal-assist sensors can be designed using a pair of 1D magnetic latches or a single 2D speed-and-direction sensor. The Allegro solutions presented here can simplify design and reduce BOM count.

Click to comment

Leave a Reply

Your email address will not be published. Required fields are marked *

To Top