Welcome to XDA

Search to go directly to your device's forum

Register an account

Unlock full posting privileges

Ask a question

No registration required
Post Reply

[How-to] auto-switch to 1080p on slimport, using tasker

OP cpanos

17th June 2014, 10:41 PM   |  #1  
cpanos's Avatar
OP Senior Member
Flag Athens
Thanks Meter: 310
 
377 posts
Join Date:Joined: Nov 2012
More
Both the nexus 4 and the nexus 7 (2013) support slimport, which is very useful for mirroring the device to a big screen. However, neither device uses the standard 16:9 (1080p) aspect ratio. As a result, you end up with some cropping on a 1080p TV. For the nexus 4 it is even worse, since it outputs 768p upscaled to the TV's resolution.

However, the flexibility of android allows us to manually change the native resolution. In a console, we can type the command:

wm size 1080x1920

and the resolution will change. In the device screen the new resolution will look odd, however you now have true 1080p on the TV. To get back to the default resolution you type:

wm size reset

This solution works, but it is not very convenient. So I made two profiles for tasker, that automatically change the device resolution upon the connection of an HDMI cable and reset it when the cable is disconnected, thus automating the whole process.

I 'm attaching a screenshot of the two profiles, as well as a zip file so you can extract and import them in tasker.

In summary,
- you need root

- the HDMI plugged profile
reduces the device brightness to minimize battery consumption
increases volume
sets resolution to 1080p
enables WiFi
sets display timeout to 10 hours
activates display rotation

- the HDMI un-plugged profile
sets auto brightness back on
resets screen resolution
sets display timeout to 1min

These are optional settings that I found useful to automate, but they are all optional, and you can tweak them once you imported the profile to tasker.

I hope you find this useful!!!
Attached Thumbnails
Click image for larger version

Name:	HDMI_plugged.png
Views:	123
Size:	42.5 KB
ID:	2804101   Click image for larger version

Name:	HDMI_unplugged.png
Views:	113
Size:	28.4 KB
ID:	2804102  
Attached Files
File Type: zip auto_slimport_tasker.zip - [Click for QR Code] (1.1 KB, 10 views)
The Following 2 Users Say Thank You to cpanos For This Useful Post: [ View ]
Post Reply Subscribe to Thread
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes