Programming: If Condition Testing a Variable Against a Binary Number
Sometimes a condition will need to exist that tests a variable against a binary number. This is how to do this using the == operator.
Example: if (receiveData == 0b11110000) PORTB ^= (1 << PINB0);