bbc / hive-mind

Device management service for the Hive
MIT License
9 stars 3 forks source link

Add device Classification for tablets #198

Closed Ashraf-Ali-aa closed 7 years ago

Ashraf-Ali-aa commented 7 years ago

When you connect a Tablet device like an iPad hive mind displays it under mobile classification

jitgo commented 7 years ago

Agreed this would be useful for iPads but it's not so simple on android as it's up to the app developer to decide what is a tablet and phone based on the screen size.

As always we're open to pull request.

Ashraf-Ali-aa commented 7 years ago

@jitgo ok cool, on Android something like this might work to determine the device type i.e Phone or tablet adb -s DEVICE_SERIAL shell command: device_type = %x[adb shell getprop ro.build.characteristics]

I am currently creating scripts to ease the process of setting up and deploying the Hive CI, it would have helped if the Docs was updated but I'll add it to my list of to-do's

jitgo commented 7 years ago

It might be worth speaking with your android dev team and see how they determine what is a phone or tablet within their code. You could then use a similar process within your scripts.

They maybe using device dependent pixels (DDP) to determine if a device is a tablet which you can query using

adb -s DEVICE_SERIAL shell dumpsys window | grep mCurConfiguration=