1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-09-02 03:12:34 +01:00

revent: Added record and replay commands

Added two commands to WA to record and replay input events using revent.

As part of this also added the ability to get a device model from
android and linux device. This may need to be improved in the future.
This commit is contained in:
Sebastian Goscik
2016-01-21 17:11:53 +00:00
parent 6a388ffc71
commit 1e6eaff702
8 changed files with 331 additions and 114 deletions

View File

@@ -536,6 +536,14 @@ class BaseLinuxDevice(Device): # pylint: disable=abstract-method
command = 'cd {} && {}'.format(in_directory, command)
return self.execute(command, background=background, as_root=as_root, timeout=timeout)
def get_device_model(self):
if self.file_exists("/proc/device-tree/model"):
raw_model = self.execute("cat /proc/device-tree/model")
return '_'.join(raw_model.split()[:2])
# Right now we don't know any other way to get device model
# info in linux on arm platforms
return None
# internal methods
def _check_ready(self):