Research Article

IoT-Based Smart Management of Healthcare Services in Hospital Buildings during COVID-19 and Future Pandemics

Algorithm 4

If sensor S1 and sensor T1 detect the movement in the same way and -1 direction, it will decrease the total value.
  / Thread-1 /
  void thread1(void unused){
  int value;
  value = (int ) unused;
  if(S1 == IN && T1 == IN){
  /if sensorS1 and sensorT1 detect the movement
  in the same way and +1 direction it
  will increase the total value. /
  room ++;
  }
  while(1); /loop forever/
  }