Go Back   EcoModder Forum > EcoModding > Instrumentation > OpenGauge / MPGuino FE computer
Register
Now


Reply
 
Submit Tools LinkBack Thread Tools
Old 08-01-2008, 05:56 PM   #1 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
VSS Signal assistance?

Is anyone in a position to capture the vss signal on a reed switch car (metro, starion)? My scope is on the fritz.

Problem: The vss is too noisy on some cars, need to know what it looks like in order to filter it properly. Plain old debouncing won't work because it seems the vss pulse peak to peak duration is less than your typical debounce period (was seeing 8342 microseconds @53mph, typical debounce is like 20000 microseconds). I added a tiny bit of debounce (3ms) and was able to put a more normal vssPulsesPerMile figure in, but the instant reading is jumpy.

It isn't a problem for hall effect cars because that is not a noisy physical switch.

I wonder if there is noise from the electromechanical parts of the speedometer/odometer? I don't know if I can defeat this problem with software alone. But would appreciate any insights into how to fix this.

Anyone seen a metro ECU schematic? Maybe someone has an old one I can dissect?


(Support Ecomodder.com & get rid of these annoying ads!)      
 

Last edited by dcb; 08-01-2008 at 06:29 PM.
  Reply With Quote
Old 08-01-2008, 06:40 PM   #2 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Edit, ok I think I have a "debounce" strategy, for dealing with this. I have to change it so it looks for X number of milliseconds in a given state before deciding to increment the vss pulse counter. Only tricky bit is the timing of the pulses should be done on the leading edge, and not whenever the pulse settles down. I think it is doable with the event scheduler though, instead of just disabling the pin interrupt for a given amount of time I will schedule an "increment the counter" event that will get overridden with each junk pulse.
  Reply With Quote
Old 08-01-2008, 07:34 PM   #3 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Quote:
Originally Posted by dcb View Post
Is anyone in a position to capture the vss signal on a reed switch car (metro, starion)? My scope is on the fritz.
Disregard, I forgot there was an existing laptop .wav file recording of a metro vss, wanna see? It is kinda fugly


But it looks like the "wait for it to settle down" strategy should work. It looks like just waiting till there is 2 milliseconds of clean signal would do it. But it will start flaking out again above 75mph. 1 millisecond might be enough, but I can't remember the last time I went 75 Maybe I will leave changing it to 1 millisecond as an exercise for the user

Last edited by dcb; 08-01-2008 at 07:49 PM.
  Reply With Quote
Old 08-02-2008, 08:43 AM   #4 (permalink)
Addicted
 
bbjsw10's Avatar
 
Join Date: Jul 2008
Location: Findlay,OH
Posts: 537

bbjsw10 - '91 Metro Xfi
90 day: 51.06 mpg (US)
What about this option on some cars, a add on hall effect. Put 1-2 magnets on halfshaft close to tranny and mount a hall effect like this one. Only like $3 and would put out consistent readings. Hall Effect Switch | Low Sensitivity | Manufactured by Melexis

And all you would need to know at that point is tire size to know pulse rate.
155/80-12 927 rev/mile
1 magnet = 927/mile
8 magnets = 7416/mile
You could attach magnets to large hose style clamp and strap to inner cv joint case.
__________________

Last edited by bbjsw10; 08-02-2008 at 09:20 AM.
  Reply With Quote
Old 08-02-2008, 09:36 AM   #5 (permalink)
EcoModding Lurker
 
Join Date: May 2008
Location: Marietta, Georgia
Posts: 23

4OVER4 - '85 Starion ESi
90 day: 24.97 mpg (US)

Auto - '87 Starion LE
90 day: 23.65 mpg (US)
Quote:
Originally Posted by dcb View Post
Is anyone in a position to capture the vss signal on a reed switch car (metro, starion)? My scope is on the fritz...
I have a 'scope - but my extension cord isn't long enough to do meaningful on-the-road testing . I have an inverter - maybe I can make it all work that way and get some pictures for us. But before I do that, I'm going to put a small capacitor in parallel with the zener and see if I can filter the bounces...
  Reply With Quote
Old 08-02-2008, 04:40 PM   #6 (permalink)
Captain Slow
 
MetroMPG's Avatar
 
Join Date: Nov 2007
Location: Lunenburg, Nova Scotia, Canada
Posts: 6,031

Blackfly - '98 Metro
90 day: 78.69 mpg (US)

ForkenSwift - '92 Metro EV
90 day: 128.28 mpg (US)
Quote:
Originally Posted by bbjsw10 View Post
What about this option on some cars, a add on hall effect. Put 1-2 magnets on halfshaft close to tranny and mount a hall effect like this one.
I bet dcb's already thinking along those lines for his motorbike. (He's already got the magnet/pickup installed, in the form of a bicycle computer.)

EDIT: FYI the Audiovox cruise control I added to my car came with a magnet kit for just this purpose - for older cars that may not have a VSS signal.
__________________
Latest test: Minivan Kardboard Kammback boosts MPG +3.7% (6.6%, counting roof rack delete)

Latest mod project: designing/building front wheel skirts (Geo Metro)





www.MetroMPG.com - fuel efficiency info for Geo Metro owners
www.ForkenSwift.com - electric car conversion on a beer budget
  Reply With Quote
Old 08-04-2008, 07:52 PM   #7 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Ok, I might be overthinknig the vss reed switch bit (LOL). Probably some more code changes before I'm done

But took a dive today with a SG also and mpguino vesion 0.70 and heres where it landed:

odometer: 42.5 miles
mpguino: 42.33 miles
SG: 41.7 miles

So I am liking the distance tracking pretty well, rough indications have it at 0.4% off of the odometer even with the reed switch. Still want to research it some more and retest the saturn to make sure that is still accurate. But if the trip is accurate then I have to look elsewhere for the jumpy instant mph reading.
  Reply With Quote
Old 08-04-2008, 08:36 PM   #8 (permalink)
Addicted
 
bbjsw10's Avatar
 
Join Date: Jul 2008
Location: Findlay,OH
Posts: 537

bbjsw10 - '91 Metro Xfi
90 day: 51.06 mpg (US)
Quote:
Originally Posted by dcb View Post
Ok, I might be overthinknig the vss reed switch bit (LOL). Probably some more code changes before I'm done

But took a dive today with a SG also and mpguino vesion 0.70 and heres where it landed:

odometer: 42.5 miles
mpguino: 42.33 miles
SG: 41.7 miles

So I am liking the distance tracking pretty well, rough indications have it at 0.4% off of the odometer even with the reed switch. Still want to research it some more and retest the saturn to make sure that is still accurate. But if the trip is accurate then I have to look elsewhere for the jumpy instant mph reading.
Looks like the Mpguino is pretty accurate , what car was this on the Saturn?
__________________
  Reply With Quote
Old 08-04-2008, 09:33 PM   #9 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
This was on the metro, the one with the bouncy vss reed switch that has been giving a bit o'trouble (had to double the vsspulsespermile initially). I was very happy with the saturn readings, both distance and fuel consumption at last check, but I've messed with the distance code a bit since then.
  Reply With Quote
Old 08-12-2008, 11:01 AM   #10 (permalink)
EcoModding Lurker
 
Join Date: May 2008
Location: Marietta, Georgia
Posts: 23

4OVER4 - '85 Starion ESi
90 day: 24.97 mpg (US)

Auto - '87 Starion LE
90 day: 23.65 mpg (US)
Looks like the v.70 fixed the Starion VSS bounce! Pulses per mile = 8204! GREAT JOB and THANKS!
  Reply With Quote
Old 08-12-2008, 01:42 PM   #11 (permalink)
Master EcoModder
 
wagonman76's Avatar
 
Join Date: Jun 2008
Location: Northwest Lower Michigan
Posts: 372

Red Car - '89 Celebrity CL 4 door
90 day: 34.81 mpg (US)

Winter Wagon - '89 6000 LE Wagon
90 day: 26.47 mpg (US)
On vehicles that are having trouble with the VSS signal, does the VSS go through the ECM or VSS buffer? And if so, is the signal being tapped after that?

I know at least on mine, the signal from the VSS itself isnt very friendly. Depending on the vehicle, it goes either through the ECM or VSS buffer to clean up the signal, and then feeds the pulses per mile to the gauge cluster and cruise control module. I tapped into that and didnt have any problems once I got my wiring right.
__________________

  Reply With Quote
Old 08-12-2008, 03:27 PM   #12 (permalink)
EcoModding Lurker
 
Join Date: May 2008
Location: Marietta, Georgia
Posts: 23

4OVER4 - '85 Starion ESi
90 day: 24.97 mpg (US)

Auto - '87 Starion LE
90 day: 23.65 mpg (US)
Quote:
Originally Posted by wagonman76 View Post
On vehicles that are having trouble with the VSS signal, does the VSS go through the ECM or VSS buffer? I know at least on mine, the signal from the VSS itself isnt very friendly...
Starions: The signal to the ECM is not pre-filtered. It's a very bouncy/noisy 0-5v signal created by a magnet/reed switch combination at the speedometer.
  Reply With Quote
Old 09-07-2008, 01:00 PM   #13 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Just a heads up, I think I made some progress this morning after the NASA guys got me thinking

Basic strategy,

keep track of the number of vss pulses (already do that) and accumulate the vss pulse lengths.

every 1/2 second compute the instant mph from the accumulated pulse lengths/number of vss pulses and reset.

I did a quick road test an instant mph is looking a lot better in the metro. Will release a new version when satisfied with it and when I integrate it into instant mpg.
  Reply With Quote
Old 09-07-2008, 04:12 PM   #14 (permalink)
EcoModding Lurker
 
Join Date: Sep 2008
Location: Olympia, wa
Posts: 65

Red Beast - '82 V45 Sabre Vetter Fairing
90 day: 39.38 mpg (US)

Da Truck - '92 B2600I
90 day: 25.66 mpg (US)

The Wife's bike - '82 CM450E Red
90 day: 57.22 mpg (US)

Yellow Submarine - '04 Neon SXT
90 day: 31.88 mpg (US)

Here is the waveform supplied to me from DCB. Placing a filter circuit in there will clean up the extra high speed pulses (small peaks) that may trigger false signals.
__________________


Last edited by ac7ss; 09-07-2008 at 04:13 PM. Reason: Image
  Reply With Quote
Old 09-07-2008, 04:18 PM   #15 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
There are no known false peaks being picked up though. The chip has built in a differential between ON and OFF detection and there is debouncing to boot. As well as the pulse count seems accurate over large distances, so what are you trying to fix? The extra hardware won't buy you anything at this point.
  Reply With Quote
Old 09-07-2008, 04:28 PM   #16 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
I would add that as evidence that the fully processed signal is about as good as it is going to get is evidenced by the fact that when you average the readings over 1/2 second it now seems to be spot on and pretty smooth.

So it is accurate over distance, it is accurate on the 1/2 second scale, things will get progressively worse at less than 1/2 second for sure.
  Reply With Quote
Old 09-07-2008, 04:54 PM   #17 (permalink)
EcoModding Lurker
 
Join Date: Sep 2008
Location: Olympia, wa
Posts: 65

Red Beast - '82 V45 Sabre Vetter Fairing
90 day: 39.38 mpg (US)

Da Truck - '92 B2600I
90 day: 25.66 mpg (US)

The Wife's bike - '82 CM450E Red
90 day: 57.22 mpg (US)

Yellow Submarine - '04 Neon SXT
90 day: 31.88 mpg (US)
Likely, the downslope and upslope are causing the difficulty. They may be triggering a longer / shorter duration between pulses depending on the trigger level. If the average over a half second is good. there is not likely to be a problem in the long term. If one wanted to play with it on their own, there are a few ways to normalize the signal. But if, as you say, the 1/2 second average is good, that is the best solution.
__________________

  Reply With Quote
Old 09-07-2008, 05:27 PM   #18 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Quote:
Originally Posted by ac7ss View Post
Likely, the downslope and upslope are causing the difficulty.
Well, if you like, around position 1159760 in that file, the speed should be pretty steady, but I think you will find that the large verticals are not evenly spaced, likely due to mechanical "slop". The data is all there and you were the one who said it was "easy" You might have to look at more than one pulse though.

Quote:
Originally Posted by ac7ss View Post
of course, if we had a trace output of the anomalous pulses it would be easy to determine the easy way to screen them out.
  Reply With Quote
Old 09-11-2008, 11:16 PM   #19 (permalink)
testing the waters
 
Join Date: Jun 2008
Location: usa
Posts: 38
I just uploaded the v.72 code and the vss instant speed is awesome it is so fluid now, EXCEPT

when I get to 40 mph

then it waits until about 60 mph before it starts counting backward

1, 10, 30, 40, 40, 40, 40, 40, 39, 38, 37


CRAZY

where in the code can I tweak this to get it right?
  Reply With Quote
Old 09-11-2008, 11:27 PM   #20 (permalink)
dcb
Master EcoModder
 
dcb's Avatar
 
Join Date: Feb 2008
Location: 3rd rock
Posts: 1,309

pimp mobile - '81 gs 250 t
90 day: 96.29 mpg (US)
Hmm.... Maybe
Code:
change:
  addEvent(enableVSSID,2 ); //check back in a couple milli
to:
  addEvent(enableVSSID,1 ); //check back in a couple milli
  Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
VSS, tach, injector signal logic wikityler Instrumentation 2 07-21-2008 12:02 AM
Signal Generator dcb OpenGauge / MPGuino FE computer 26 06-27-2008 11:29 PM
Arduino-based turn signal jacket SVOboy Alternative Transportation 6 06-23-2008 11:22 AM
Opengauge/MPGuino development: Freeduino signal processing dcb OpenGauge / MPGuino FE computer 6 04-16-2008 10:40 AM
[CRXMPG Mailbag] SuperMID and VSS Issues with EF Civics SVOboy Instrumentation 0 02-03-2008 05:33 AM




Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.2.0 RC5
All content copyright EcoModder.com