16F876A CCP1 Capture/Interrupt Question


Closed Thread
Results 1 to 7 of 7

Hybrid View

  1. #1
    Join Date
    Jul 2003
    Posts
    2,405


    Did you find this post helpful? Yes | No

    Default

    Capture will generate the interrupt, but only if you have it enabled. PIE1 = $04 should do
    the trick. With PIE1 = 0 you have the interrupt disabled.

    Do a search here for examples using capture & code execution timing with timers for several
    good examples.

    Edit: Here's an example http://www.picbasic.co.uk/forum/showthread.php?p=23401
    Last edited by Bruce; - 16th January 2008 at 15:02. Reason: Link to thread
    Regards,

    -Bruce
    tech at rentron.com
    http://www.rentron.com

  2. #2
    Join Date
    Jan 2008
    Location
    Carrollton, TX
    Posts
    6


    Did you find this post helpful? Yes | No

    Default

    Joe and Brian,
    Thanks for the comments.. I had already downloaded Darrel's instant interrupts but I haven't tried those yet... later in my learning process I will do that. The phototransistor turn off time I'm measuring with a 10K load is on the order of 100 to 200uS, and I seem to be getting very accurate measurements using the CCP1 pin (they agree with my oscilloscope), but not that accurate with the RB0/INT pin because of the things you mentioned.

    Bruce,
    You nailed it. Thanks for taking the time to read through my code and figure it out for me...I should have been able to figure that out myself, but I kept missing it. I knew it couldn't have been a bad PIC - I bought it from you!
    TDon

Similar Threads

  1. 16 bit PWM using CCP1
    By Normnet in forum mel PIC BASIC Pro
    Replies: 60
    Last Post: - 27th August 2014, 08:13
  2. Question Regarding Port A on 16F876A
    By jevert in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 26th February 2009, 14:00
  3. PIC16F819 HPWM CCP1 clariffication
    By earltyso in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 20th March 2008, 18:43
  4. Please answer my first question
    By John_001 in forum Off Topic
    Replies: 1
    Last Post: - 15th September 2006, 06:49
  5. Timer / CCP Question
    By jamie_s in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 2nd November 2005, 08:22

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