Posts: 2
Joined: Fri Dec 07, 2012 2:38 pm

Baking PI: stuck at Screen 02

Fri Dec 07, 2012 2:56 pm


I worked trough the BakingPI tutorial.
It is nice, but unfortunately it's a little bit confusing and frustrating (my opinion).
Sometimes the example code is different from the solution.
But I managed to solve the problems that appeared so far.

But now I stuck at Lesson 7 Screen 02.

I tried all the folowing things:
a different screen
a different PI
solution code
my own code
different resolutions
framebuffer .align 4,5,12
without the kernel_old=1 option
unplug the screen and replug it

None of these seems to be the solution to my problem :(

I think the screen is getting a signal or something because it gets a little bit brighter, when I power on the PI.
Screen01 works, other OS ( Raspian, Rasbmc) also start up perfectly.

I hope you can help me.
Thanks in advance

Posts: 10
Joined: Mon Dec 03, 2012 12:48 am

Re: Baking PI: stuck at Screen 02

Sat Dec 08, 2012 10:57 pm

I had a similar issue with mine (on a new 512mb rev 2 B model). Some examples would start up about half the time, some none of the time. After reading through other threads here, it was suggested that sending frame-buffer info at a non-cache coherent address (below 0x4000000) would result in the VideoCore looking for the info and not finding it because the cache hasn't written back to main memory (apparently the VideoCore uses a different set of caches). By adding 0x40000000 to the frame buffer info address (before you send it through the mailbox), the pointer is then put into a range where it is aliased to the same memory, but now any reads to it ensure that there are no not-yet written cache-lines from the CPU (and possibly from the VC).

To do this in the tutorials you are working on, in framebuffer.s change:

Code: Select all

	mov r0,fbInfoAddr
	mov r1,#1
	bl MailboxWrite
around lines 76-79 to

Code: Select all

	mov r0,fbInfoAddr
	add r0,r0,#0x40000000
	mov r1,#1
	bl MailboxWrite
This now works for me 100% of the time.

Posts: 2
Joined: Fri Dec 07, 2012 2:38 pm

Re: Baking PI: stuck at Screen 02

Thu Dec 13, 2012 12:54 pm

Thanks dude.

That worked perfect for Lesson 7.

For lesson 8 I had to try somethings, but finally I get it running.

But now I have another question.
My Screen has a resolution of 1680x1050.
And all the examples are written for a resolution of 1024x768, so it looks not very nice.
On the first screen lesson I changed it to 1680x1040, ( 1050 didn't compile) and it looked very nice.

But now on lesson 8 it's blurry ( 1024*768) and with 1680*1040 the text is very small, blurry and distorted...

How did you guys do this?
1024x 768 or did you changed it?
If yes, how?

Thanks in advance

Posts: 119
Joined: Thu Jun 14, 2012 1:50 pm

Re: Baking PI: stuck at Screen 02

Sun Dec 16, 2012 7:39 pm

Thanks for this fix

I had a similar blank screen which this addition to framebuffer.s fixed.

All the best

Return to “Bare metal, Assembly language”