Trying to measure time between two pulses on different pins.


Results 1 to 27 of 27

Threaded View

  1. #2
    Join Date
    Jan 2012
    Location
    Grid EN19MV
    Posts
    159


    Did you find this post helpful? Yes | No

    Default Re: Trying to measure time between two pulses on different pins.

    What if you were to use DT's Instant Interrupts? Have an interrupt that times out at some frequency - every time that interrupt happens, increment a counter. When the leading edge of the first pulse happens (could also be an interrupt), zero the counter. When the leading edge of the second pulse hits, read the counter and multiply by the frequency of the interrupt to determine the time.

    That was my first thought. Never actually done it - but I think it would work.
    Last edited by andywpg; - 21st August 2014 at 16:17. Reason: Spelling
    "I have noticed that even those who assert that everything is predestined and that
    we can change nothing about it still look both ways before they cross the street"


    -Stephen Hawking

Similar Threads

  1. Measure time in mS between two pulses
    By Fredrick in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 7th March 2011, 07:20
  2. time measurement between 2 pulses
    By xvladx in forum mel PIC BASIC Pro
    Replies: 10
    Last Post: - 27th April 2010, 17:33
  3. calculate time between pulses
    By hell_pk in forum mel PIC BASIC Pro
    Replies: 19
    Last Post: - 20th October 2007, 16:49
  4. Count pulses between VARIABLE TIME
    By RodSTAR in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 15th October 2007, 12:44
  5. Timed pulses on 2 pins
    By Danie Joubert in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 15th March 2004, 07:38

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