Re: PIC processor interrupt for delayed output
- From: "google@xxxxxxxxxxxxx" <google@xxxxxxxxxxxxx>
- Date: Wed, 23 Apr 2008 02:19:41 -0700 (PDT)
On Apr 22, 3:15 am, Bill Bowden <wrongaddr...@xxxxxxx> wrote:
What is the best approach to generate a delayed output from a triggerYou don't say what else you want the PIC to be doing while it's
input to a PIC microcontroller? The idea is to have a constant known
time from trigger input to output, so I don't want to poll the logic
level on some pin due to the jitter that would occur. Thought about
using the comparator module to generate an interrupt, but it seems
complicated setting and clearing all the various bits and reference
levels.
Is there an easier way?
monitoring the pin.
If you can run it in a tight loop I think you can test 8 input pins
(on one port) for a change in four cycles (16 clocks). If you unravel
the loop you can get that down to an average approaching 3 cycles at
the expense of code size.
You also don't say if you're then going to wait in another loop or
whether you'll set up a timer to trigger an interrupt when the output
needs to change state. Finally you don't say how long the delay needs
to be. Unless you can afford your interrupt routine to trash the W and
status register or you can guarantee that the interrupt will never
trigger when anything other than a known bank is selected then there
is quite a lot of overhead you'll need in the interrupt routine that
will limit your minimum delay.
Tim.
.
- Follow-Ups:
- Re: PIC processor interrupt for delayed output
- From: Bill Bowden
- Re: PIC processor interrupt for delayed output
- From: google@xxxxxxxxxxxxx
- Re: PIC processor interrupt for delayed output
- References:
- PIC processor interrupt for delayed output
- From: Bill Bowden
- PIC processor interrupt for delayed output
- Prev by Date: Wholesale Patek Philippe Grand Complications Replica Watches PP036 Discount, Fake Watch
- Next by Date: Re: PIC processor interrupt for delayed output
- Previous by thread: Re: PIC processor interrupt for delayed output
- Next by thread: Re: PIC processor interrupt for delayed output
- Index(es):
Relevant Pages
|
Loading