This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Problem in calling the function in ISR

Hi,

I'm using LPC2148 controller and interfacing accelerometer sensor, I need to enable this

sensor all the time and with the counter set in the ISR it should come out of the loop, below is

the code.

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "adc.h"
#include "lcd.h"
#include "lcd1.h"
#include "systemInit.h"
#include "delay.h"
#include <stdio.h>
#include "string.h"
//#include "uart.h"
#include "config.h"
#include "stdlib.h"
#define BUZZER (1 << 25)
#define BUZZER_DIR IO1DIR
#define BUZZER_SET IO1SET
#define BUZZER_CLR IO1CLR
#define TIMER_TICK_1_MS (59999) /* VPB at 60 MHz clock */
static unsigned int ms_count;
void delay2(int count);
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Presently only a=0 is printing on LCD, sensor function part is not working, if sensor function is called in the main() it works fine and displays detected values on LCD. Any suggestions will be of great help.

 

Regards,

Aakansha

0