Two loops possible?

the above doesn't look compilable
below is proper format

void bt0PopCallback(void *ptr)     // Release event for dual state button bt0
{
  uint32_t alarmTswitch = 0;                                // alarmbutton - Create variable to store value we are going to get
  bt0.getValue(&alarmTswitch);
  ...
}

as others have suggested, millis() can be used to check if a time period has expired without blocking