Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

device_info缺失问题 #961

Closed
codeskyblue opened this issue Apr 28, 2024 · 2 comments
Closed

device_info缺失问题 #961

codeskyblue opened this issue Apr 28, 2024 · 2 comments
Assignees

Comments

@codeskyblue
Copy link
Member

{'udid': '08a3d291-26:17:84:b6:cb:a0-DT1901A',
 'version': '10',
 'serial': '08a3d291',
 'brand': 'SMARTISAN',
 'model': 'DT1901A',
 'hwaddr': '26:17:84:b6:cb:a0',
 'sdk': 29,
 'agentVersion': '0.10.0',
 'display': {'width': 1080, 'height': 2340},
 'battery': {'acPowered': False,
  'usbPowered': True,
  'wirelessPowered': False,
  'status': 5,
  'health': 2,
  'present': True,
  'level': 100,
  'scale': 100,
  'voltage': 4356,
  'temperature': 292,
  'technology': 'Li-poly'},
 'memory': {'total': 7665272, 'around': '7 GB'},
 'cpu': {'cores': 8, 'hardware': 'Qualcomm Technologies, Inc SM8150'},
 'arch': '',
 'owner': None,
 'presenceChangedAt': '0001-01-01T00:00:00Z',
 'usingBeganAt': '0001-01-01T00:00:00Z',
 'product': None,
 'provider': None}

原有的uiautomator2在2.x版本的时候存在输出,但是新版没有了。

@codeskyblue
Copy link
Member Author

计划保留这部分

{
 'version': '10',
 'serial': '08a3d291',
 'brand': 'SMARTISAN',
 'model': 'DT1901A',
 'sdk': 29,
 'display': {'width': 1080, 'height': 2340},
 'memory': {'total': 7665272, 'around': '7 GB'},
 'cpu': {'cores': 8, 'hardware': 'Qualcomm Technologies, Inc SM8150'}
}

@codeskyblue
Copy link
Member Author

battery 部分,可以通过下面的代码获取

d.adb_device.battery()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant