add sensor detection