Hello,
I am using port1,port2 pins. what is default status of port pin if m not connected to vcc and ground also??.
var=(P1OUT & BIT3);
var1=(P1OUT & BIT4);
do
{
right_rotate=0;
if(var && (~var1)) //for right rotation
{
right_rotate=1;
timer_delay(); //0.75sec delay
count =count_r ++;
P1OUT ^= BIT0;
var=0;
var1=0;
Bingo_value=Bingo_value+(count*20);
}
}while(right_rotate==1);
do
{
left_rotate=0;
if((~var) && var1) //for left rotation
{
left_rotate=1;
timer_delay(); //0.75sec delay
count =count_l ++;
var=0;
var1=0;
Bingo_value=Bingo_value-(count*20);
}
}while(left_rotate==1);
in this if i keep p1.3 ,p1.4 open then first time it is entering inside if part [ if(var && (~var1)) //for right rotation] of first do while loop. so m not cleared about that why it is entering inside ??? can anyone clear this dought???