Changes for device detect