RPi in portrait mode


22 posts
by RaTTuS » Tue Jun 26, 2012 4:19 pm
using the console
I've re-compiled the kernel with
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y
and added
fbcon=rotate:3
to the end of the /boot/cmdline.txt
and now I have 80x100 console display running.

\o/
happy bunny
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by gruso » Sat Jun 30, 2012 5:33 am
Cool. I need this mode for a project I'm working on.

Any chance you could share your modified kernel?
User avatar
Posts: 40
Joined: Tue Mar 06, 2012 4:39 am
by clickykbd » Sat Jun 30, 2012 6:51 am
Nice. I've been eyeing some of the 90deg twisting monitors lately. Good to know it will work.
User avatar
Posts: 117
Joined: Wed Jun 06, 2012 2:21 am
Location: Austin, Texas
by RaTTuS » Sat Jun 30, 2012 7:48 am
I'll put a up link monday for the kernel
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by gruso » Sat Jun 30, 2012 8:02 am
Great, thanks :)
User avatar
Posts: 40
Joined: Tue Mar 06, 2012 4:39 am
by RaTTuS » Mon Jul 02, 2012 8:28 am
http://www.sendspace.com/file/h4dcns

this is debian squeeze kernel.img ... make a backup for your existing one ... hope it works ... lets see
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by gruso » Mon Jul 02, 2012 11:33 pm
Thanks for the upload :) I'll give it a try when I get a chance.
User avatar
Posts: 40
Joined: Tue Mar 06, 2012 4:39 am
by spottypaws » Mon Jul 23, 2012 6:15 pm
Rattus - Any chance you've looked at doing this for the newer Raspbian release please?
Posts: 3
Joined: Wed Jul 18, 2012 9:50 am
by chrowe » Mon Jul 23, 2012 9:31 pm
This worked fine for us to get the console rotated, but not the GUI.

Running 2012-07-15-wheezy-raspbian

All we did was to swap out the kernel.img file and added fbcon=rotate:3 to the end of the /boot/cmdline.txt


Now, we just need to get randr working
Posts: 7
Joined: Sun Jul 22, 2012 2:53 pm
by dom » Tue Jul 24, 2012 6:04 pm
I've had a think about this and it's something that the GPU can do almost for free.

Try this build:
https://dl.dropbox.com/u/3669512/temp/start_rot.elf

and add
display_rotate=1
to config.txt.

(1=90, 2=180, 3=270 degrees of rotation)

There's definitely some issues with this build, like fbset, and how hdmi resolutions are reported (should they be 1920x1080 or 1080x1920?).

But give it a go.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4059
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by Clifor » Thu Jul 26, 2012 11:19 am
Just tried Dom proposal and it worked fine so far :) Could you explain it a bit further?

I am doing several test with the RPi connected to a 46'' Samsung screen and looks awesome for the price :)
Posts: 12
Joined: Thu Jul 26, 2012 10:58 am
by direk » Wed Aug 01, 2012 10:15 am
I am also testing dom's proposal and it works just great :-)
Simple and elegant way to rotate screen!
Posts: 6
Joined: Thu Jul 26, 2012 11:23 am
by RaTTuS » Thu Aug 02, 2012 10:54 am
awesome - this works great
;-p
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by dajavous » Sat Aug 04, 2012 6:27 am
I've been looking for a way of using the Raspberry Pi in portrait mode for a while, and this works in both command line and Xwindows with no issues - simply replaced start.elf with the build supplied and added the line as Dom describes. I will be using it for a rolling display at home, as a vertically placed screen fits the hole left by a previous fish tank!

:D

Could Dom provide some explanation on why the new build works, and whether it will be included in future releases?
Posts: 1
Joined: Sat Aug 04, 2012 6:18 am
by dom » Sat Aug 04, 2012 10:39 am
dajavous wrote:Could Dom provide some explanation on why the new build works, and whether it will be included in future releases?

It's in the main source tree, so support is in current latest firmware and will be in any future builds.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4059
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by DonOregano » Mon Sep 17, 2012 7:04 am
For those having trouble with this, try changing the memory split to give more memory to the graphics. I could not get portrait mode working until I did that.
Posts: 13
Joined: Wed Jul 11, 2012 3:30 pm
by RaTTuS » Mon Sep 17, 2012 8:10 am
yes in latest [ < 15th September] I have to use the 192 split to use the rotated display , 224 / 240 both both work for me
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by dom » Mon Sep 17, 2012 11:43 am
RaTTuS wrote:yes in latest [ < 15th September] I have to use the 192 split to use the rotated display , 224 / 240 both both work for me

What does "fbset -s" report? The rotated display does require more GPU memory, but I'm surprised 224M is not sufficient.
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 4059
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge
by RaTTuS » Mon Sep 17, 2012 11:52 am
mode "1200x1600"
geometry 1200 1600 1200 1600 16
timings 0 0 0 0 0 0 0
rgba 5/11,6/5,5/0,0/16
endmode
I'll try 224 again shortly
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by RaTTuS » Mon Sep 17, 2012 12:27 pm
just updated everything
and can confirm that
224 does not work - rotated
192 rotated and the multicolour screen is centered on the screen
224 and it is top left aligned and does not get any further
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK
by zentsang » Thu Dec 06, 2012 5:31 pm
Update: SOLVED
After scouring more Google hits. I came across a forum that lead me to believe replacing the "start.elf" file is no longer needed. You simply add the "display_rotate=x" line in the config.txt file.

The catch is... portrait mode requires a higher GPU/CPU split of the RAM. So I fired up "raspi-config" and gave 128MB to the GPU (per the other forum post). I added the "display_rotate=1" line back in the config.txt and rebooted. BAM! Screen is rotated. If I backed the split back down to 16MB for GPU... no boot. So I got it working.

Figured I'd post my update in case anyone else finds their way to this thread via Google. =)

Original Post:
Hey all,

Dom's "start_rot.elf" and the config line didn't work for me using the latest "2012-10-28-wheezy-raspbian.zip" build. I'm putting together a MAME cabinet so this is why I'm trying to boot everything in portrait mode.

Hardware:
256mb Raspi - 900Mhz overclocked
RAM Split: 16MB to video - remainder to system
Vizio 21" 1080p HDTV 60Hz.
HDMI 1.4 and 1.3 cables tested.
Class 10 16GB microSD
Powered USB 2.0 hub

Steps:
sudo mv /boot/start.elf to /boot/start.elf.bkp
sudo mv /boot/start_rot.elf /boot/start.elf
sudo nano /boot/config.txt
added: display_rotate=1 to end of file and saved.
sudo reboot

Result:
You see the initial rainbow palette screen in an unrotated view. Then nothing. You don't see any of the boot up code running. Also as a check... Caps Lock and NumLock won't light up on the keyboard so it appears something is hanging the boot process.

Simply removing the line in the config.txt and swapping the original start.elf back in and everything boots fine.

Any ideas? I see others say they got it working. Is there anything in my steps above that is wrong or missing?

Thanks.

-ZenTsang
Posts: 1
Joined: Fri Sep 28, 2012 9:14 pm
by RaTTuS » Fri Dec 07, 2012 12:42 pm
display_rotate=3
gpu_mem=32
this is what I use in my config.txt file and it works fine
any less and it does not boot. [IIRC]
http://www.catb.org/esr/faqs/smart-questions.html <- ask smart Questions
"That's not right, the badgers have moved the goalposts."
1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX - Prosliver FTW
User avatar
Posts: 5566
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK