Shop OBEX P1 Docs P2 Docs Learn Events
Best way to adjust a speed pulse — Parallax Forums

Best way to adjust a speed pulse

Jim FouchJim Fouch Posts: 395
edited 2008-08-17 14:29 in Propeller 1
I'm wondering what would be the best way to have a propeller adjust a speed pulse from a motorcycle. Bikes from the factory are always over reporting their speed. For example when traveling at 60 MPH indicated by the bike, your actual speed will be like·56-58 MPH·(Reported by a GPS). Not sure why they do this. But pretty much all bikes are this way.

Another problem is if you change your gearing, lets say drop one tooth in the front it will throw you off another amount. For example I went from a 16 tooth sprocket to a 15, which causes my RPM to increase by 6.25% for any given road speed and over estimate my road speed.

What I'm looging to do is have a Propeller intercept the speed pulses and adjust them and then report them to the bike's computer.

My initial thought would be to use one timer to read the pulses and at·specific intervals, set another timer to send out another pulse that would be adjusted for the new sprocket and the manufaturer's build in error. I know this would not be perfect, and I'm willing to drop a few pulses here and there, but it would be alot better then the ~11-12% that I'm off now.

I think mostly I need to find what interval will work best. At very slow speeds (<5 MPH) the pulses will be very long and the corrected output pulse may have more errors. Maybe it would be better to count the actual pulses and after so many send out the modified signal?

Any thoughts?

Thanks,

Jim

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jim Fouch

FOUCH SOFTWARE

Comments

  • ElectricAyeElectricAye Posts: 4,561
    edited 2008-08-17 04:13
    Jim,
    I don't know about the electronics, but remember that the circumference of a tire is 2 times pi times radius. A small change in tire radius, brought about by tread wear, will show up multiplied by more than 6 on your circumference and thus will affect your apparent speed as measured by the pulse counter. Similarly, tire pressure, tire temperature, or even if you're carrying around a lot of "old beer" can change the effective radius of your tire. These kinds of error sources can pile up sometimes, so you might keep that in mind as you try to correct for things.

    But whatever you do, wear a helmet. A bare head makes a bad brake pad.

    good luck,
    Mark
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2008-08-17 04:35
    Underinflated tires are what first occurred to me, too, when I read your post. Be that as it may, if you want to slow the reported speed by 58/60ths, say, just drop every 30th pulse. In other words, devise a circuit (Stamp, perhaps, or Prop) that passes 29 pulses from one pin to another, then skips the next one, passes 29, skips one, ... , etc. This assumes, of course, that your display incorporates some sort of long-term averaging to smooth past the missing pulses.

    -Phil

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    'Still some PropSTICK Kit bare PCBs left!

    Post Edited (Phil Pilgrim (PhiPi)) : 8/17/2008 4:40:38 AM GMT
  • SeariderSearider Posts: 290
    edited 2008-08-17 14:29
    Another approach would be to measure the period of the incoming pulse stream. Do the math to calculate the desired change, convert Period to Frequecy and then output the correct freqency.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔

    Searider
Sign In or Register to comment.