Hi, I need to generate software interrupts and I'm using the K60 twr board.
I have previously done like this:
#include "MK60N512MD100.h"
#include "core_cm4.h"
NVIC_EnableIRQ((IRQn_Type) 94); //Enable Software interrupts
NVIC->STIR = 94; //Genarate the interrupt.
How do I do this when using MQX?, the problem is that the include files conflicts with the MQX libraries.
Solved! Go to Solution.
Hi zeal,
#include <mqx.h>
#include <bsp.h>
those 2 headers you have to include for MQX (check examples) then board header (MK60DZ10.h) is included too.
Use bsp_int_init instead of your function NVIC_Enable_IRQ.
Regards,
MartinK
Hi zeal,
#include <mqx.h>
#include <bsp.h>
those 2 headers you have to include for MQX (check examples) then board header (MK60DZ10.h) is included too.
Use bsp_int_init instead of your function NVIC_Enable_IRQ.
Regards,
MartinK
Thank you Kojto, I got it to work.
#include "mqx.h"
#include "bsp.h"
_int_install_isr(110, latency_isr, ptr);
_bsp_int_init(110, 64, 0, TRUE);
Then NVICSTIR = 94; generates the interrupt.
Thanks again.