Warning L15: Multiple Call to Function. Using Two Interrupts

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

 Hello All,

   

In my code I am using two interupts. These interupts are calling functions to initialize themselves. Because both are using the same functions I am getting function re-entry warnings:

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    _CYINTSETPRIORITY/CYLIB

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    _CYINTSETVECTOR/CYLIB

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    CYSPCSTART/CYSPC

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    CYSPCLOCK/CYSPC

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    CYSPCUNLOCK/CYSPC

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    _CYSPCLOADROW/CYSPC

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

*** WARNING L15: MULTIPLE CALL TO FUNCTION

   

    NAME:    _CYSPCWRITEROW/CYSPC

   

    CALLER1: VBUS_IRQ_INTERRUPT/VBUS_IRQ

   

    CALLER2: TAKESAMPLE_IRQ_INTERRUPT/TAKESAMPLE_IRQ

   

 

   

Looking for solutions, it is suggested that I would make these function re-enterant. Is this a correct understanding or is there another way to initilize these interrupts? 

   

 

   

Thanks

0 Likes
1 Reply
Bob_Marlowe
Level 10
Level 10
First like given 50 questions asked 10 questions asked

You will have to make tese routines reentrant. There is a different approach for the generated module's functions and your own routines (if you have got some) that are called from different places, within a handler and from main() directly or indirectly.

   

for the latter case you may use the keyword "reentrant" while the other references have to be kept in a file.

   

Left click on your project in the Workspace Explorer window, select Add New Item and choose "Keil Reentrancy File".

   

Here you name all the functions you want to be reentrant, one item per line, case sensitive, no parenthesis, no parameters.

   

Look here www.cypress.com/ and here www.cypress.com/

   

 

   

Happy coding

   

Bob

0 Likes