Thank so much for the I was trying to upgrade and had not been able succeeded
On Wed, Sep 2, 2020, 7:42 AM Dave McLaughlin <davemclaughli...@gmail.com> wrote: > I have Android 7.1 and I implemented all of the changes you indicated, > although you do indicate P or higher I thought I would try it. During the > boot, the boot logo was still in portrait mode due to the fact that the > default orientation of the LCD display is portrait mode (the timings are > for 800x1280 and not 1280x800) > > When I flash the new OS to the board and then boot it and Android finally > starts, the display is initially in landscape mode but quickly changes to > portrait. Subsequent reboots are straight into portrait. I've not been able > to track down which part of the source is selecting portrait. > > By the way, the exact same build running on the same processor board but > with an 800x480 LCD that is default landscape timing, comes up as > landscape. > > On Wednesday, 8 July 2020 at 01:28:37 UTC+7 khab1...@gmail.com wrote: > >> Hi Dave, >> >> Please refer below steps to force orientation to landscape: >> >> 1. Make sure only landscape permission is available on your build >> environment >> >> Only add android.hardware.screen.landscape.xml to your makefile by below >> command: >> >> PRODUCT_COPY_FILES += >> frameworks/native/data/etc/android.hardware.screen.landscape.xml:system/etc/permissions/android.hardware.screen.landscape.xml >> \ >> >> Remove android.hardware.screen.portrait.xml if it exists >> >> 2. Add an overlay to force landscape mode >> Assume you have device/company/device_x >> >> Create a config.xml file and put it in >> >> device/company/device_x/overlay/framework/base/res/res/values >> >> Contents of config.xml: >> >> <resources> >> <bool name="config_forceDefaultOrientation">true</bool> >> </resources> >> >> 3. Make sure your overlay in config.xml is used >> >> PRODUCT_PACKAGE_OVERLAYS += device/company/device_x/overlay >> >> Done! Your system is always landscape! >> >> Note: This solution only works on Android P or older Android version. >> From Android Q, Google changes to use new solution. >> >> Limitation: The app which sets portrait as orientation in >> AndroidManifest.xml can’t display properly! Ex: Antutu Benmark. >> >> By the way, I had found solution for above limitation by creating a >> broadcast service which tried to convert rotation of the application. But i >> just forgot the reference. I will try to find it and share you later! >> >> Best Regards, >> KHA Tran >> >> >> >> >> -- > -- > unsubscribe: android-porting+unsubscr...@googlegroups.com > website: http://groups.google.com/group/android-porting > > --- > You received this message because you are subscribed to the Google Groups > "android-porting" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to android-porting+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/android-porting/150fb306-42d2-45c2-9c67-f75d1961186en%40googlegroups.com > <https://groups.google.com/d/msgid/android-porting/150fb306-42d2-45c2-9c67-f75d1961186en%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- -- unsubscribe: android-porting+unsubscr...@googlegroups.com website: http://groups.google.com/group/android-porting --- You received this message because you are subscribed to the Google Groups "android-porting" group. To unsubscribe from this group and stop receiving emails from it, send an email to android-porting+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/android-porting/CAL1SjPiSradqbZC66vndk6k8VuYr%2BFfvujAWsC0t-L26Av%3DSHQ%40mail.gmail.com.