I am having problem with masking the bit for reading and writing operation.
Here's what I am doing
LPC_GPIO0->DIR |= (1<<3)|(1<<5);
LPC_GPIO0->MASKED_ACCESS[(1<<3)|(1<<5)] = (1<<3)|(1<<5);
In above code, it is suppose to mask only 3rd and 5th bits of GPIO 0. Bit it masks all bits.
Another strange thing I notice that in above code, replacing
LPC_GPIO0->MASKED_ACCESS[(1<<3)|(1<<5)] = (1<<3)|(1<<5);
with
LPC_GPIO0->MASKED_ACCESS[0] = (1<<3)|(1<<5);
makes no difference. Here in place of 0, writing any number makes no difference.
Can any one help??
