cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

Anonymous
Not applicable

The interrupt on capture box is disabled for the fixed function timer.

   

 

   

I assume this function is not available on fixed function timers but the documentation says differently. Timer_v2_70.pdf page 2 shows:

   

 

   

Am I doing something wrong or is this just wishful thinking in the documentation?

0 Likes
Reply
13 Replies
Esteemed Contributor

Sure looks like this is an error in docs as Capture functionality

   

in either FF or UDB implemented, with limited Capture input

   

functionality and only a single register for FF. And interrupt register

   

bit there for either.

   

 

   

I recommend you file a CASE on this and if you would please

   

post back the result.

   

 

   

    

   

          

   

To create a technical or issue case at Cypress -

   

 

   

www.cypress.com

   

“Support”

   

“Technical Support”

   

“Create a Case”

   

 

   

You have to be registered on Cypress web site first.

   

 

   

Regards, Dana.

0 Likes
Reply
Honored Contributor II

According to the documentation, this parameter only set the _initial_ interrupt mask. Did you try to enable the capture interrupt via the software API - there it should work.

0 Likes
Reply
Anonymous
Not applicable

With the FF version, the compiler will not even generate the ISR code.

0 Likes
Reply
Esteemed Contributor

That is correct, the compiler is not "aware" of what you want to

   

do in the ISR. It does, however, make a placeholder file for you

   

to put your code in, or alternatively you can do a C ISR -

   

 

   

    

   

          

   

CY_ISR_PROTO(MyIntFunc);      // Prototype declaration

   

then

   

CY_ISR(MyIntFunc)                         // Interrupt function definition

   

{

   

// Place code here

   

}

   

 

   

In  initialization part of the program

   

 

   

isr_StartEX(MyIntFunc);               // Start Interrupt with my handler

   

 

   

CY_ISR-macro have a look into the "System Reference Guide" under Help -> Documentation..

   

 

   

Regards, Dana.

0 Likes
Reply
Contributor II

 To enable Capture interrupt, you must select "UDB" as the configuration.

   

 At that point a capture mode is enabled, and an "On Capture" interrupt is enabled.

0 Likes
Reply
Anonymous
Not applicable

I understand the interrupt on capture capability is available in the UDB block.  Documentation says it should be available in the fixed-function block as well.

   

 

   

Dana, Hli,

   

Are you saying that it will work if I create the interrupt and enable it in s/w?

0 Likes
Reply
Esteemed Contributor

If in SW you enable interrupt then placeholder file is created, or you can

   

do the C ISR.

   

 

   

If you connect an external ISR component to pin then you can do a

   

interrupt that way alternatively. You would use its API to enable it

   

and that creates a placeholder, or again you can do it in C.

   

 

   

Regards, Dana.

0 Likes
Reply
Contributor II

 It appears in the data sheet, page 26 for the timer, that if you se the "Capture" bit in the Timer_Mode (Fixed-Function Implementation), you will get a timer interrupt.

0 Likes
Reply
Honored Contributor II

The interrupt is always external. You need to connect an ISR component to the interrupt output, then you will also get your IRS function generated. Since the timer doesn't need an internal interrupt, it won't have an internal ISR.

0 Likes
Reply
Esteemed Contributor

My mistake, my prior post is in error. I might be getting confused with

   

PSOC 1. Airhead comes to mind.

   

 

   

Your comment "IRS function generated", here in States very scary IRS

   

(Internal Revenue Service), I hope nothing I do on this forum raises their

   

flags. The NSA spying on US is enough.

   

 

   

Regards, Dana.

0 Likes
Reply
Anonymous
Not applicable

Wait, there's no IRS function???  I was going to do my taxes with that.  Oh well...

0 Likes
Reply
Anonymous
Not applicable

Per WSM's suggestion, I checked and there is a capture interrupt mask generated so I assume the interrupt is active as well.  I will test and post my results.

0 Likes
Reply
Anonymous
Not applicable

The interrupt on capture appears to be functional even though it can't be enabled in the configuration dialog.  So I guess the documentation is actually correct.  Interrupt on capture is available in the fixed function timer.

0 Likes
Reply