Bottom bracket torque sensor

Skippic

100 W
Joined
Jun 22, 2010
Messages
224
Location
Bratislava, Slovakia
I'm about finished with the design phase of my e-bike project, but I'm missing an important part a bottom bracket torque sensor.

From these links it's clear they exist, but I'm having a difficult time searching where to buy one.

http://www.jdssportcoaching.com/index.cfm/services/equipment-consultation/ergomo-troubleshooting-and-service/
http://www.pressebox.com/pressemeldungen/schaeffler-technologies-gmbh-co-kg/boxid/370302

My requirements:
relatively cheap (< $100)
the signal can be in almost any form
I only need the torque (no need for cadence - I can calculate it based on bike speed "single speed bike")
 
GCinDC said:
Tell people what you're going to do with the torque data, once you get it... ie, why you want it...

I'm making an e-bike that will be controlled exclusively by pedals, just like Bionx, but with 3Kw of power. For control and logic I'm using Arduino.

I'll publish all once I'm done ;)
 
do you have a separate chain just for pedaling ? Then you can add a little chain tension wheel in
the 'stressed' part of the chain and measure the compression of its spring ?
 
Lebowski:
That's the back-up plan. I have a 20Kg weight sensor I would use in combination with a spring and a wheel to measure the upper chain tension. But I'm having problems designing it to withstand the possible tensions, suspension movement and it's reliability couldn't possibly compare with an industrial component. Plus the complexity would convert the whole project from a commuter bike to a toy I would be adjusting and repairing most of the time. But thanks for the suggestion.

GCinDC:
I know how the Bionx works, what I meant was the final sensation for the rider. I have seen the strain gauge on the front chain wheel, but I would like to use a 53T, so although not impossible, it would complicate things. Also they seem to be bad quality products.

There is still time until I need to order one. I also saw the following from Shimano:
http://www.bikeradar.com/news/article/shimano-unveil-new-steps-electric-bike-components-26649/

I can't find where to buy replacement parts for it.
 
Here's a link: http://www.thun.de/en/products/

Thun manufacture bicycle components. The sensor was developed for them by NCTEngineering:
http://www.ncte.de/english/index.htm
 
Thanks Miles!

I was looking at that one before as well. The problem is I have no idea where to buy one. Otherwise they are perfect. I even wrote an email to someone asking for more info, but never got a reply.
 
I had the same idea of using Arduino to use the X-Cell RT.

Below the code that I've created so far (GPL2). It works sort of. YMMV. Be careful not to create a run-away bike.

Any improvements are welcome! Have fun!


Code:
/*
 * THUN
 * Reads the X-Cell RT and drives a controller based on sensed torque.
 *
  
 * Created 28 January 2013
 * By Alexander Brandt
 *
 */
 
// INPUT PULSE
int pulsePin = 21;       // PulseOne from crank connected to pin 31
volatile int pulse = 0;  // Hall sensor state
volatile int tempPulse = 2;

// INPUT TORQUE
int torquePin = 7;       // Analog IN pin that reads torque
volatile int torque = 0;          // Gemeten torque 0-1023
volatile int torqueMax = 0;       // Maximum torque measured last 16 pulse changes, which equals one complete circle
//volatile int torqueMaxAge = 0;    // Number if pulses that have passed since maxTorque
int torqueLowerLimit = 512;       // Inclusive 512: 2,5 volt
int torqueUpperLimit = 600;       // 919 to use full scale; 4,5 volt. Lower to increase sensitivity. Too low value will result in power falling away at peak.
volatile int torqueArray[16];
volatile int torqueArrayIndex = 0;


// OUTPUT LED
int ledPin =  13;    // LED connected to digital pin 52
int led = 1;        // LED STATE

// OUTPUT DRIVE
int drivePin = 8;    // PWM pin that drives the controller
volatile int drive = 0;       // Waarde die aan de controller wordt doorgegeven 0-255
int driveLowerLimit = 50;
int driveUpperLimit = 216;

// TIME & COUNTER VARIABLES
volatile int triggerCount = 0;
volatile int changeCounter = 0;
volatile long timeExpired = 0;
int loopDelay = 200;
volatile long lastUpdateTime = 0;   // in miliseconds from starting the program. note: will need to deal with overflow.
int timeOut = 410;
volatile int pulseCounter = 0;
volatile int timeOutCounter = 0;
volatile int updateReason = 0;

void setup() {                
  // PULSE
  pinMode(pulsePin, INPUT);
//  digitalWrite( pulsePin, HIGH);
  attachInterrupt(2, callUpdate, CHANGE);
  
  pinMode(torquePin, INPUT);     // TORQUE
  pinMode(ledPin, OUTPUT);       // LED
  pinMode(drivePin, OUTPUT);     // DRIVE
  
  // Open serial communications and wait for port to open:
  Serial.begin(57600);
  Serial.println("Hello Dave..");
  
}
 
// the loop() method runs over and over again,
// as long as the Arduino has power

void loop()
{  
  //Serial.println("LOOP");
  timeExpired = millis() - lastUpdateTime;
  if(timeExpired > timeOut)
  {
    
    updateReason = 0;
    timeOutCounter++;
    update();
    //printDebug();
  }
//  printDebug();
  delay(loopDelay);
}                 

void callUpdate()
{
  updateReason = 1;
  pulseCounter++;
  update();
  //printDebug();
}

void update() {  
  pulse = digitalRead(pulsePin);
  digitalWrite(ledPin, pulse);
  updateTorqueMax();
  setDrive();
  lastUpdateTime = millis();
  printDebug();
}

void updateTorqueMax(){
  if(timeExpired > timeOut)
  {
    for (int i=0; i<16;i++)
    {
      torqueArray[i]=0;  
    }
    torqueMax=(1023-analogRead(torquePin));
  }
  else 
  {
    torqueArray[torqueArrayIndex]=(1023-analogRead(torquePin));
    torqueMax=getTorqueMaxFromTorqueArray();
    if(torqueArrayIndex==15)
    {
      torqueArrayIndex=0;
    }
    else
    {
    torqueArrayIndex++;
    }
  }
}
    
int getTorqueMaxFromTorqueArray(){
  int max=0;
  for (int i=0; i<16;i++){
    if(max<torqueArray[i]){
      max = torqueArray[i];
    }
  }
  return max;
}

void setDrive(){
  if(torqueMax<torqueLowerLimit)
  {
    drive = driveLowerLimit-1;
//    Serial.println("WARNING: Recorded torque is lower than expected!!");
//    Serial
  }
  else if(torqueMax>torqueUpperLimit)
  {
    drive = driveLowerLimit-1;
//    Serial.println("WARNING: Recorded torque is higher than expected!!");
  }
  else
  {
     drive = map(torqueMax, torqueLowerLimit, torqueUpperLimit, driveLowerLimit, driveUpperLimit);
  }
  analogWrite(drivePin, drive);
}

void printDebug(){
/*
  Serial.print("\r                                              \r");
  Serial.print("PULSE:");
  Serial.print(pulse);
  Serial.print(" R:");
  Serial.print(updateReason);
*/
 // Serial.print(timeExpired);

  Serial.print(" T:");
  Serial.print(timeOutCounter);
  Serial.print(" P:");
  Serial.print(pulseCounter);
  
/*
//  Serial.print(" TRIGG:");
//  Serial.print(triggerCount);
//  Serial.print(" DELTA:");
//  Serial.print(changeCounter);
//  Serial.print(" TRT:");
//  Serial.print(1023-analogRead(torquePin));
  Serial.print(" I:");
  Serial.print(torqueArrayIndex);
  Serial.print(" TIND:");
  Serial.print(torqueArray[torqueArrayIndex]);
  Serial.print(" TMAX:");
  Serial.print(torqueMax);
  //Serial.print(" TIME:");
  //Serial.print(timeExpired);
*/
  Serial.print(" DRV:");
  Serial.println(drive);
//  Serial.println(".");
}
 
I just stumbled across this one, but I don't know anything about it. Dapush stuff is normally pretty good:
http://www.dapush.cn/English/Product_2.htm
 
Hi Alexander,
Your post inspired me to try to create a Thun + Arduino controller controller... The good old Dawes Horizon now has a hub motor and a rear carrier with battery, motor controller and Arduino board all tucked away inside. Just 2 wires - one to the motor and one to the Thun.

I have written the project up. You can find it here: http://endless-sphere.com/forums/viewtopic.php?f=6&t=57185
 
Ebike.ca has 2 different types of torque sensors. The Thun (expensive) and a new one (cheaper)
otherDoc
 
Back
Top