Functions? Creating a Radio Hub

Start with the low hanging fruit...

...
  if (doorState = HIGH) {
...
  else if (doorState = LOW) {
...