diff --git a/devlib/target.py b/devlib/target.py index 60af5c7..fdef1bd 100644 --- a/devlib/target.py +++ b/devlib/target.py @@ -68,7 +68,7 @@ import devlib.utils.asyn as asyn FSTAB_ENTRY_REGEX = re.compile(r'(\S+) on (.+) type (\S+) \((\S+)\)') -ANDROID_SCREEN_STATE_REGEX = re.compile('(?:mPowerState|mScreenOn|mWakefulness|Display Power: state)=([0-9]+|true|false|ON|OFF|DOZE|Asleep|Awake)', +ANDROID_SCREEN_STATE_REGEX = re.compile('(?:mPowerState|mScreenOn|mWakefulness|Display Power: state)=([0-9]+|true|false|ON|OFF|DOZE|Dozing|Asleep|Awake)', re.IGNORECASE) ANDROID_SCREEN_RESOLUTION_REGEX = re.compile(r'cur=(?P\d+)x(?P\d+)') ANDROID_SCREEN_ROTATION_REGEX = re.compile(r'orientation=(?P[0-3])') @@ -2220,6 +2220,8 @@ class AndroidTarget(Target): if match: if 'DOZE' in match.group(1).upper(): return True + if match.group(1) == 'Dozing': + return False if match.group(1) == 'Asleep': return False if match.group(1) == 'Awake':