hi all,
i am using the RF430-rf2500 kit. and i am trying to trigger on an input.
it must do something untill the input is set.
source i got:
in mcuint:
P4DIR = 0x00;
void init(void){
int x;
int iDummy = 1;
while(iDummy != 0)
{
if (0x10 & P4IN) // zolang p5 niet 1 is.
{
BSP_TOGGLE_LED2();
BSP_TOGGLE_LED1();
iDummy = 0;
}
else
{
for(x = 0; x < 400; x++)
{}
P2OUT ^= 0x01;
}
}
}
The input pin is 0.02 Volt and it already gets triggert al the time ...
tryed the folowing: hardwarewise
Ground - 1k resistor -
> Input Pin.
signal -
even then its getting 0x10 al the time :(.
anny1 know what i am doing wrong??
grtz
h2k
edit* it just seem its continuesly makeing that port 1 - 0 - 1 - 0 atleast the leds keep going on of on of on of.