Friday, January 11, 2008

Rotate Android Screen to Landscape/Portrait

Here are some tips of android screen rotation.

On the emulator, after the Android system is started up, open another command window, type the following command line in the adb shell to change the screen to landscape:
# service call window 18 i32 1
type the following command line to change the screen to portrait:
# service call window 18 i32 0

23 comments:

Jared said...

Or you could just hit 7 or 9 on your keypad to switch:
http://code.google.com/android/reference/emulator.html#controlling

Sandy_Android said...

When I enter the 'service call' command, I get a response Result: 'Parcel(00000000 '....'), with no change to the emulator display.
Also, 7 or 9 on the keypad simply brings up the Contacts application - ??
What am I doing wrong?

rabbia said...

hi,
just off ur Num Lock key & press 7/9 at numeric keypad to see the rotation effect on emulator
bye

Sandy_Android said...

Thanks for your response. Any idea if you can resize the display after the emulator starts? For example, switch from 320x480 -> 800x480?

deenybird said...

thanks rabia for your advice

Nicholas John said...
This comment has been removed by the author.
Godlessons said...

I know this is old, but you can hit ctrl-f12 to rotate the screen in the emulator while it is running.

jaireina said...

7 or 9 works perfectly!.. :)

Vince said...

@GodLessons: That is the only solution that worked for me...thanks!

suresh said...

Hi Every body........
Ctrl+F12 is the perfect key to rotate the emulator.......
bye
Thanks & Regards
Suresh.g

Gary said...

Even though Generic Viagra is interesting matter, I think this stuff is even more interesting than anything I have seem before.

shripal said...

any idea about potrait to landscape in mac os, i want my whole application should be display in landscape mode.

Nikolai said...
This comment has been removed by the author.
cryptognome said...

On a Mac without a key pad, you may also need the 'fn' key: fn-ctrl-F11, fn-ctrl-F12

sasha said...

In a tough economy, investors tend to put their money into thriving industries. Innovation drives the marketplace, and this is demonstrated clearly in the case of Android apps.

best android apps

best iphone apps

Arghya Chakraborty said...

Excellent information related to Android. Got many unknown information about android system. Regards Fuel Injection Service Fort Worth

steve beckam said...

Having been just browsing for useful blog posts intended for the project research when I happened to stumble on yours. Thanks for this useful material!
buy levitra

Archie Pavia said...

that was nice. very nice informative article and site as well. Thanks for the share.... Keep posting. -- hotel nightclub louisville

FBMASOFT said...

Thanks Rabia for ur help :)

Riscsys Information Technologies said...

Hi I 'm so tired because I have an MK802 Deivce and I2m using an monitor which support HDMI IN but I still have an problem Screen don't rotate from landscape to portrait. Can anyone help me? Please...

Raul Jacinto-Montes said...

try

adb root
adb shell am display-size 640x480
adb shell am display-size 1920x1080
adb shell am display-size 1280x720
adb shell am display-size reset

Raul Jacinto-Montes said...

To resize the screen try

adb root
adb shell am display-size 640x480
adb shell am display-size 1920x1080
adb shell am display-size 1280x720
adb shell am display-size reset

Emelia Grase said...

It gives you a chance to view Microsoft Office records and few likewise mind 'make and alter' usefulness. It, May additionally, let you to download applications, for example, singular and business fund supervisors, or about whatever you need to. Alternately it may give you a chance to alter photographs, get driving bearings through GPS, and make a playlist of numerical tunes.
Develop Android Apps // Mobile Application Development // Android Application Development