So I was reading through "Gooligum's" website and he uses these commands:
sGPIO |= 1<<1; // turn on LED on GP1
sGPIO &= ~(1<<1); //turn off LED on GP1
sGPIO ^= 1<<2; //toggle LED on GP2 using shadow reg
Now I understand everything but the "|=" and the "&=". Could anyone shed some light on this?
Thanks in advance!
sGPIO |= 1<<1; // turn on LED on GP1
sGPIO &= ~(1<<1); //turn off LED on GP1
sGPIO ^= 1<<2; //toggle LED on GP2 using shadow reg
Now I understand everything but the "|=" and the "&=". Could anyone shed some light on this?
Thanks in advance!