LabVIEW Embedded

cancel
Showing results for 
Search instead for 
Did you mean: 

Interrupts in LabVIEW Embedded for ARM

Gmg - very userful comments, thanks!

 

I have had a close look at the interrupt files and am curious as to how you know what to include in your intialization function - is this obvious somewhere ?? Can you help me there ?

 

The reason I ask, is that I need an interrupt on Port0[23] - the AD(0), CAP3(0) pin - or more specifically the ADC0 interrupt line. I need to know if there has been a variation on the input level (falling edge) but am unsure of how to set up the intialisation function (required inputs etc) - the pin setup I am sure I can work out. What are the other nitty gritties, do you know ?

 

I appreciate any help.

 

I am using the LPC2368/2387 (just extra RAM in the latter), using LabVIEW 8.6.1 and ARM embedded module 1.1.

0 Kudos
Message 11 of 12
(3,366 Views)

There are basically three things you must handle in the initialization function:

 

1.  pin configuration - associate a pin to the respective peripheral  (in this case, settting the PINSEL registers)

 

2.  configure the interrupt - part varies per interrupt, but involves things such as setting clock rates, etc.

 

3.  enable peripheral interrupt - (should be done last) is normally done by writing to the peripheral's interrupt enable register and may also include configuring when the interrupt fires (i.e. falling/rising edge).  As long as you specify the correct interrupt vector (in the XML file) then LabVIEW will automatically enable/register the interrupt with the interrupt controller and CPU.

 

(4.)  enable power to peripheral -  may be needed depending on if peripheral is powered on startup or not.  It should not be needed by any peripherals that are currently used by LabVIEW.

 

As to where to find the details of the above, the best I can do is refer you to the ADC section of the user manual for your chip:   http://www.nxp.com/acrobat_download/usermanuals/UM10211_1.pdf

0 Kudos
Message 12 of 12
(3,359 Views)