Detect Signal


Closed Thread
Results 1 to 15 of 15

Thread: Detect Signal

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default

    Unfortunately I do not have a frequency meter. best I have is a cheapo Radio Snack multimeter with AC/DC, Diode test and Amperage. So I am rather stuck trying to ascertain what the signal looks like by what I have on hand. Now if I had the gear I had back in college, it would be a diff story.

    Basically I think I will count the pulses that show up, unless someone has a better idea (This is a 93 honda civic btw)

  2. #2
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by angrysmileyface View Post
    Unfortunately I do not have a frequency meter.
    You are building one. Be sure to look at the COUNT command in the manual. I use something similar to monitor fan and blower speeds.

    A hall effect sensor is often used. If the wiring is good the signal will be "OK". The first few blade speed monitors I built used sensors from autos.
    Dave
    Always wear safety glasses while programming.

  3. #3
    Join Date
    Apr 2006
    Location
    New Hampshire USA
    Posts
    298


    Did you find this post helpful? Yes | No

    Smile Pulses Per Mile 4000 PPM ???

    1992-1995 Honda Civic Cruise Information

    Constant 12V+ White Ignition Switch Harness or Use Hot Side of Brake
    Switched 12V+ Black/Yellow Ignition Switch Harness
    Ground Use Chassis Near Cruise Control Module
    Hot Side of Brake n/a Brake Switch
    Cold Side of Brake Green/White Brake Switch
    Tach Blue Distributor
    VSS Lead Yellow/Blue Driver's Side Dash, above Fuse Panel, Gray Connector
    Pulses Per Mile 4000 PPM

    http://www.hondafactor.com/v2/showpo...55&postcount=5

    “Your mileage may vary”
    -Adam-
    Ohm it's not just a good idea... it's the LAW !

  4. #4
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Pic_User View Post
    VSS Lead Yellow/Blue Driver's Side Dash, above Fuse Panel, Gray Connector
    Pulses Per Mile 4000 PPM

    http://www.hondafactor.com/v2/showpo...55&postcount=5
    There ya go. Use the VSS signal to trigger an interrupt, keep track of the pulses in a word variable...Bam...done...except for the building, and the programming, putting it in a box, testing it on the car, etc.etc.

  5. #5
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    Both Vss and Tach can be find easy under the dash for this car as well. Usually on the top of the fuse box. There's a lot of connector, just use the same wire color.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  6. #6


    Did you find this post helpful? Yes | No

    Default

    Ok got a little code here. Not quite sure if its what I want for this purpose, so excuse me if there are some errors. Basically I want it to count the pulses coming off the VSS and Im trying to use the VSS as a the interupt to start the process when it starts registering milage. I do not know if I configured the interupt process correctly as well as its not shown here, but I would like to be able to save the milage to some portion of the eeprom memory when the car is shut off. I intend to use a 16F877A for this project. Insight or help is greatly appreciated. Thanks.

    Define LOADER_USED 1 'required if bootloader used to
    'program PIC
    DEFINE LCD_DREG PORTC 'Define PIC port used for LCD Data
    'lines
    DEFINE LCD_DBIT 4 'Define first pin of portb
    'connected to LCD DB4
    DEFINE LCD_RSREG PORTC 'Define PIC port used for RS line of
    'LCD
    DEFINE LCD_RSBIT 3 'Define PortC pin used for RS
    ' connection
    DEFINE LCD_EREG PORTC 'Define PIC port used for E line of LCD
    DEFINE LCD_EBIT 0 'Define PortC pin used for E
    'connection
    DEFINE LCD_BITS 4 'Define the 4 bit communication
    'mode to LCD
    DEFINE LCD_LINES 2 'Define using a 2 line LCD
    DEFINE LCD_COMMANDUS 2000 'Define delay between sending LCD
    ' commands
    DEFINE LCD_DATAUS 50 'Define delay time between data sent.
    OPTION_REG = %00111111 'Not sure if this is needed.
    plscntr var WORD
    milage var word


    plscntr = 0 'Reset pulse counter
    ON INTERRUPT goto miles_start
    INTCON = $90
    Start:

    lcdout $fe, 1 ' Clear LCD
    lcdout $fe, 2 ' Position cursor at home
    LCDOUT #milage ' Initially display Milage
    Pause 1000 ' Pause for 1 second to see it
    If PortA.1 = 1 Then milage = 0 'Reset the milage indicator if reset button pressed
    Goto Start ' Loop back and do it all again


    miles_start:
    if PortA.5 = 1 then plscntr= plscntr +1 'add the pulses

    if plscntr = 4000 then
    plscntr = 0
    milage = milage+1
    lcdout $fe, 1 ' Clear LCD
    lcdout $fe, 2 ' Position cursor at home
    LCDOUT #milage ' Display Milage
    EndIF
    goto miles_start
    end

  7. #7
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Which pin do you plan on using to trip the interrupt?

    Assuming the pulse goes high (maybe PortB.0?), let the ON INTERRUPT kick you into the interrupt subroutine and stay there until the pin goes low so you don't kick the counter more than once.
    Check and reset the pulse counter (if counter > 4000 then = 0 etc.etc.) and increment the mileage counter, and do the displaying and button checking in your main loop. No sense doing that in your interrupt subroutine.
    First off though, don't worry about counting mileage...put the whole thing together and whip up a 555 timer or something (maybe even a pushbutton, the switch bounce will give you more than one pulse if the button is old enough!) to simulate the VSS pulse and get the display and everything working without having to go out to the car every 2 minutes to test it out. Just get the thing counting up as you need it (heck you can get both an odometer and speedometer and average speedometer and gas mileage and oil change intervals and all sorts of crap into this), then worry about all the neat stuff for later since you've already got basics down.

Similar Threads

  1. Replies: 24
    Last Post: - 1st December 2009, 09:01
  2. Detect fast movement using photodiode
    By Pic2008 in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 22nd November 2008, 15:07
  3. Decoding an incoming infrared signal: need advice
    By xnihilo in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 9th May 2008, 17:28
  4. PIC16F684 + LCD to use the 256bytes of EEPROM - HELP
    By xnihilo in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 7th March 2008, 15:19
  5. Help with sound command in 2 programs
    By hyperboarder in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 5th July 2007, 21:36

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts