Device state monitoring

Dozens of answers already in the Topic below and others: