advanced
hardware
pedal
PAS

Pedal Sensors

Pedal Assist System (PAS) configuration for cadence and torque sensors with ASI BAC motor controllers

Levy Fleets Team12 janvier 202518 min read

Pedal Sensors

Pedal sensors form part of the Pedal Assist System (PAS) for e-bikes. They read pedal cadence speed and/or torque to determine when and how much motor assistance to provide.

Supported Pedal Sensor Types

Type ValueSensor TypeDirectionNotes
0Single HallDuty cycle directionalGreater than 50% duty cycle is forward
1Single HallNon-directionalNo direction detection
3Quadrature Speed & TorquePFS leads CruiseDuty cycle 50:50
4Quadrature Speed onlyPFS leads CruiseDuty cycle 50:50
5Axle TorqueNon-directionalSimple torque only (legacy)
6Single Hall InvertedDuty cycle directionalLess than 50% duty cycle is forward
7Single Hall and TorqueLogical input directionalCruise input active is forward
8Single Hall and TorqueNon-directionalCombined cadence + torque
9Dyname TorqueNon-directionalRefined torque only

Wiring

Single-Output Pedal Cadence Sensor

Single output sensors typically have 3 wires:

WireConnection
Power5V or 12V supply
GNDGround
SignalPFS/Digital input 2

Single-Output with Direction

Sensors with direction detection have 4 wires:

WireConnection
Power5V or 12V supply
GNDGround
SignalPFS/Digital input 2
DirectionCruise/Digital input 1

Two-Output Quadrature Sensor

Quadrature speed sensors have 4 wires:

WireConnection
Power5V or 12V supply
GNDGround
Sine SignalPFS/Digital input 2
Cosine SignalCruise/Digital input 1

Axle Torque Legacy

The Axle torque (Type 5) is a legacy configuration that only supports the Throttle analog input as a source. All other pedal torque sensor inputs can use any available analog input (Throttle, Brake1, Brake2, ABMS, or remote throttle voltage).

Configuration

Safety Warning

Ensure the vehicle is secured in case the motor engages unexpectedly while manually configuring your pedal sensor.

Configuration Tips

  • Make backup copies of your parameter file often
  • Set Control command source to 0 / Serial stream to prevent motor from spinning while configuring

Cadence-Only Sensors (Types 0, 1, 4, 6)

1

Set Sensor Type

Set Pedal sensor type to the appropriate value (0, 1, 4, or 6).

2

Set Pulses Per Revolution

Enter your Pedal speed sensor pulses per revolution.

Note for Quadrature types:

  • Firmware 6.026 and earlier: Sum of both PFS/sine and Cruise/cosine pulses
  • Firmware 6.027+: Sum of PFS/Sine pulses only
3

Set Control Source

Set Control command source to:

  • 2 / Pedal Sensor for pedal-only control
  • 4 / Throttle OR Pedal Sensor for combined control
4

Test Operation

Verify:

  • No faults present
  • Pedaling forward spins the motor
  • Stopping pedals or pedaling backwards causes motor to coast
5

Verify with Average Pedal Speed Test

See the Average Pedal Speed Test section below.

Cadence with Torque Sensors (Types 3, 7, 8)

1

Set Sensor Type

Set Pedal sensor type to the appropriate value (3, 7, or 8).

2

Set Pulses Per Revolution

Enter your Pedal speed sensor pulses per revolution.

3

Set Control Source

Set Control command source to 2 / Pedal Sensor or 4 / Throttle OR Pedal Sensor.

4

Configure Torque Sensor

  • Set Torque sensor voltage source to your analog input
  • Set Torque sensor offset to the resting input voltage
  • Set Torque sensor gain using the actual sensitivity in Nm/V
5

Test Operation

Verify pedaling forward engages motor and stopping causes coast.

6

Verify with Average Pedal Speed Test

See the Average Pedal Speed Test section below.

Axle Torque Sensor (Type 5)

With the axle torque sensor connected to Throttle/Analog input 1:

1

Prevent Accidental Engagement

Set Control command source to 0 / Serial stream.

2

Enable E-Bike Flag

Enable eBike flag bit 10 under communications configuration vector.

3

Verify Wiring

Poll throttle voltage and apply load to verify voltage responds to torque input.

4

Set Sensor Type

Set Pedal sensor type to 5 / Axle torque.

5

Configure Gains

Set Axle torque sensor 1, Axle torque sensor 2, and Axle torque sensor 3 gains.

6

Set Power Gain

Set Pedalec power gain to 1 for 1:1 power gain initially.

7

Enable Control

Set Control command source to Pedal sensor or throttle OR pedal sensor.

8

Test Torque Response

Add resistance to the wheel (using trainer or brakes) and pedal at constant cadence. Verify average pedal torque increases/decreases with resistance.

Dyname Torque Sensor (Type 9)

1

Set Sensor Type

Set Pedal sensor type to 9 - Dyname torque sensor.

2

Set Voltage Source

Set Torque sensor voltage source to your input source.

3

Set Offset

Set Torque sensor offset to the resting sensor voltage.

4

Set Filter

Set Torque Sensor Voltage Filter bits (0-15):

  • Higher value = More filtering, slower response
  • Lower value = Less filtering, faster response
  • Averaged time = 2^value in milliseconds
  • Example: Value 7 = 2^7 = 128ms averaging
5

Set Gain

Set Torque sensor gain to calculate the torque.

6

Set Deadband

Set Pedalec deadband torque below which filtered torque is ignored.

Example: At 28 Nm/V gain, a 10Nm threshold = 10 Nm / 28Nm/V = 0.35V deadband.

Optional Dyname Settings

Rolling Start Enable:

  1. Enable Features bit 9 rolling start enable
  2. Torque will be disabled below Rolling start speed
  3. Configure Dyname rolling start ignore torque as a threshold to bypass rolling start

Static/Stuck Torque Signal Fault Protection:

  • Set Throttle deadband threshold to prevent static voltage faults
  • Set Torque sensor static voltage fault threshold for reset voltage change
  • Set negative value to disable static faults entirely
  • Set Torque sensor static voltage fault time for fault trigger duration

Tuning Parameters

Cadence Sensor Tuning

ParameterEffectRecommendation
Pedalec positive motoring torque rampControls assist buildup speedIncrease for softer feel
Pedalec negative motoring torque rampControls assist decay speedApplication-dependent
Pedal speed map endRPM for 100% assistIncrease for softer feel
Pedal speed map offsetAssist at 0 RPM0 for no assist at standstill
Pedal sense delayPulses before assist startsIncrease to reduce sensitivity
Assist cut out distanceDistance-based timeout calculationFor speed-dependent cutout
Pedalec minimum timeoutMinimum time before negative rampPrevents too-quick cutout
Pedalec maximum timeoutMaximum time before negative rampLimits coast time

Softening bike feel: Increase Pedal speed map end and Pedalec positive motoring torque ramp from defaults (64 RPM and 200 ms).

More responsive feel: Decrease these values.

Pedal Speed Map Offset

  • Value > 0: Provides assist at 0 RPM when pedals are active
  • Value < 0: Requires positive RPM before assist begins
  • Value > 1: Assist request becomes 0% above Pedal speed map end

Torque Sensor Tuning

ParameterEffectRecommendation
Pedalec power gainMaster feel adjustmentHigher = brisker assist arrival
Pedalec torque symmetryTorque averaging method0 for smoothest (single-sided sensors)
Pedalec deadband torqueMinimum torque before assistReduce sensitivity to noise
Pedalec initial torqueInitial power on pedal startStart at 0, increase if needed

Pedalec Power Gain Calculation

Torque assist request [%] = 100% × Average pedal torque [Nm] × Pedalec power gain / 64 Nm
Pedalec Power GainFull Assist (100%) at
0.5128 Nm
1.064 Nm
2.032 Nm

Pedalec Torque Symmetry Options

ValueModeBest For
0One cycleSmoothest, single-sided sensors
1Half cycleModerate responsiveness
2Quarter cycleFaster response
3InstantaneousThrottle-like feel

Average Pedal Speed Test

To verify pedal sensor configuration:

  1. Operate pedals in the forward direction
  2. Examine average pedal speed parameter value
ResultMeaningAction
Positive when forward, negative when backwardCorrect wiringConfiguration complete
Values reversedWires swappedSwap PFS/Digital input 2 and Cruise/Digital input 1 wires
Erratic at constant cadenceWiring issueCheck all connections

Troubleshooting

No Motor Assist When Pedaling

Check Wiring:

  • Single output: Power + GND + PFS/Digital input 2
  • Dual output: Add Cruise/Digital input 1 for cosine signal

Check Input Signals:

  • Single output: Verify digital inputs bit 3 (Pedal First input) toggles 0↔1
  • Dual output: Verify both bit 3 and bit 4 (Cruise) toggle independently

Check Signal Voltage:

  • Scope the sensor signals
  • Compare against input specifications in Connector Interface
  • Example issue: 1.3V/3.7V output when BAC 855 requires 4V digital low threshold

Check Motor Power Settings:

  • Rated motor power (Race mode PAS power) must be filled in
  • Rated motor power (Street mode PAS power) if using alternate power mode

Check Brake/Cutout:

  • eBike flags bit 1 (Cutout enabled) prevents motor engagement
  • Usually coupled with eBike flags bit 0 (Brake enabled)

Solutions:

  • Disconnect brakes if pulling voltage out of range
  • Set Cutoff brake sensor source out of range
  • Verify chosen source voltage is above Analogue brake full voltage

Motor Engages When Pedaling Backwards Only

The controller may be interpreting forward cadence as reverse direction.

Solution: Switch pedal sensor type:

  • From Single Hall (0) to Single Hall Reverse (6)
  • Or vice versa

E-Bike Flag Not Set

Enable communications configuration vector bit 10 (Enable Ebike) to enable pedal sensors.

Key Parameters Reference

AddressParameterFunction
175Pedal sensor typeSensor type selection (0-9)
176Pedal speed sensor pulses per revolutionPulses per pedal rotation
177Pedal sense delayPulses before assist starts
178Pedal speed map endRPM for 100% assist
179Pedal speed map offsetAssist at 0 RPM
180Pedalec positive motoring torque rampAssist ramp-up time (ms)
181Pedalec negative motoring torque rampAssist ramp-down time (ms)
182Torque sensor voltage sourceAnalog input selection
183Torque sensor offsetResting voltage (V)
184Torque sensor gainSensitivity (Nm/V)
185Pedalec power gainMaster torque multiplier
186Pedalec torque symmetryAveraging mode (0-3)
187Pedalec deadband torqueMinimum torque threshold (Nm)
188Pedalec initial torqueInitial assist boost
189Assist cut out distanceDistance-based timeout
190Pedalec minimum timeoutMinimum cutout delay (ms)
191Pedalec maximum timeoutMaximum cutout delay (ms)

Next Steps