<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Microwindows, M5329x Framebuffer, and LTIB in ColdFire/68K Microcontrollers and Processors</title>
    <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171367#M6382</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Oops, here's the code itself...&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 30 Apr 2009 08:22:01 GMT</pubDate>
    <dc:creator>Mr_Bob</dc:creator>
    <dc:date>2009-04-30T08:22:01Z</dc:date>
    <item>
      <title>Microwindows, M5329x Framebuffer, and LTIB</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171365#M6380</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;SPAN&gt;I'm working with a board derived from the Freescale/LogicPD mcf5329&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;evaluation board, and using the microwindows-0.90 package which is&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;included in ltib-cf_nommu-20081215 from Freescale's web site.&amp;nbsp; The&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;framebuffer (kernel is linux-2.6.26) is set up for a 320 wide by 240&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;high LCD.&amp;nbsp; The penguin shows fine on power-up.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But, when I try to run some of the demo apps, I get mixed results at&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;best.&amp;nbsp; As a good example of exactly where I'm at, if I&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;run /usr/nanox/launcher.sh, I get what appears to be a 3 x 3 matrix of&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;icons, presumably for launching other demo apps; the icons included are&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;(top row) Tetrix, Slider, Terminal; (middle row) Clock, Magnifier,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Scribble, (bottom row) Roach, Tux, and NXEyes.&amp;nbsp; This matrix has its&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;lower left corner aligned with the lower left corner of the screen, and&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;does not occupy the entire screen; the remainder (about the top 25% and&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;the rightmost 10%) seems to be some patterned background.&amp;nbsp; All this&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;appears good - I say "appears" as I'm not really sure what to expect.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;However, there is a big problem - the bottom ~20% of the screen has a&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;flicker that exhibits itself as random row-wide artifacts.&amp;nbsp; What I mean&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;is that it seems some rows really are not being drawn - for example, row&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;200 might be drawn, row 201 gets skipped, and row 202 gets drawn where&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;201 should be.&amp;nbsp; I say this because it appears that the labels of the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;bottom three icons (i.e. Roach, Tux, and NXEyes jump up and down a row&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;or two.&amp;nbsp; The rest of the display is rock-solid.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;After playing with this a while, I've discovered something.&amp;nbsp; After about&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;15 seconds, the launcher.sh demo goes into a random screensaver mode.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Some screensavers look really good, such as a "searchlight" that&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;illuminates a small circle that is moved over the display, the rest of&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;which is black - simulating a flashlight searching in a darkened room.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For this screensaver, every thing is sharp, and there is no flicker&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;whatsoever.&amp;nbsp; Other screensavers, such as one that looks like lighting&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;flashes, exhibits the flicker over large portions of the display - not&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;just the bottom portion.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Other screensavers show either extreme, or behavior in between them.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;What seems to be going on is that the more dynamic the graphics, the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;more the flicker is exhibited. Put another way, the more static the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;display, the less flicker is noticed.&amp;nbsp; I would expect that a totally&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;static display might well show no flicker whatsoever.&amp;nbsp; (Note: I don't&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;know if the launcher.sh main screen is indeed fully static - it would&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;appear to be, but perhaps something at the very bottom isn't).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This would seem to be timing related or something, but I haven't been&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;able to find anything amiss in the stock code.&amp;nbsp; I did come across&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;something regarding priority of the LCD controller on the internal&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;crossbar switch, but it appears that it has already been elevated to the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;highest priority by the kernel.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm completely stumped by this - anyone have any ideas on what might be&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;amiss, or what to investigate?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-Bob&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Apr 2009 08:28:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171365#M6380</guid>
      <dc:creator>Mr_Bob</dc:creator>
      <dc:date>2009-04-13T08:28:49Z</dc:date>
    </item>
    <item>
      <title>Re: Microwindows, M5329x Framebuffer, and LTIB</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171366#M6381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wow, thanks for all the help!&amp;nbsp; &lt;IMG alt=":smileywink:" class="emoticon emoticon-smileywink" id="smileywink" src="http://freescale.i.lithium.com/i/smilies/16x16_smiley-wink.gif" title="Smiley Wink" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Seriously, it seems Microwindows is NOT the problem.&amp;nbsp; I wrote a very simple program that writes directly to the framebuffer, and I still see flickering/tearing/shearing of the display.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attached is a silly test program, which in pseudo-code goes like this:&lt;BR /&gt;&lt;BR /&gt;test:&lt;BR /&gt;&amp;nbsp; open framebuffer&lt;BR /&gt;&amp;nbsp; write all zeros to it (i.e. erase the screen)&lt;BR /&gt;&amp;nbsp; sleep(10) to allow inspection&lt;BR /&gt;&amp;nbsp; lseek to beginning&lt;BR /&gt;&amp;nbsp; write all ones to it (i.e. set all pixels white)&lt;BR /&gt;&amp;nbsp; sleep(10)&lt;BR /&gt;&amp;nbsp; lseek to beginning&lt;BR /&gt;&amp;nbsp; write a pattern of 8x8 multi-colored boxes to screen&lt;BR /&gt;&amp;nbsp; sleep(10)&lt;BR /&gt;&amp;nbsp; close framebuffer&lt;BR /&gt;&lt;BR /&gt;Running this shows a nice blank screen for 10 seconds, then a white&lt;BR /&gt;screen for 10 seconds, then finally some pretty boxes.&amp;nbsp; Or at least,&lt;BR /&gt;that is what is supposed to happen.&lt;BR /&gt;&lt;BR /&gt;What actually happens, sometimes, is that, sometimes it works, other&lt;BR /&gt;times the white screen shows the flicker/tearing/shearing throughout the&lt;BR /&gt;entire lower two-thirds of the screen.&amp;nbsp; Of course, the black looks fine,&lt;BR /&gt;but surprisingly, the colored blocks also looks fine.&amp;nbsp; Well, almost -&lt;BR /&gt;when the white shows the shearing, there is usually a small black&lt;BR /&gt;rectangle, maybe 3-4 pixels wide by 6-8 high, at the far left of the&lt;BR /&gt;screen, centered vertically about the first sheared line; this block is&lt;BR /&gt;also present on the white screen, along with an 6-8-pixel long vertical&lt;BR /&gt;black line at the same elevation, midway across the screen.&amp;nbsp; I don't&lt;BR /&gt;know if that little line shows up with the colored boxes.&lt;BR /&gt;&lt;BR /&gt;I don't thing there is anything wrong with my code - it's so simple -&lt;BR /&gt;but perhaps I'm missing something?&amp;nbsp; Any ideas?&lt;BR /&gt;&lt;BR /&gt;Presuming my code is okay, where is the framebuffer running into trouble?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm really at a loss here, and while my client is very patient, he's likely to pull the plug soon...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;-Bob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2009 08:20:55 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171366#M6381</guid>
      <dc:creator>Mr_Bob</dc:creator>
      <dc:date>2009-04-30T08:20:55Z</dc:date>
    </item>
    <item>
      <title>Re: Microwindows, M5329x Framebuffer, and LTIB</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171367#M6382</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Oops, here's the code itself...&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Apr 2009 08:22:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171367#M6382</guid>
      <dc:creator>Mr_Bob</dc:creator>
      <dc:date>2009-04-30T08:22:01Z</dc:date>
    </item>
    <item>
      <title>Re: Microwindows, M5329x Framebuffer, and LTIB</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171368#M6383</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;Hi Mr. Bob, I just noticed this posting. What did you come up with? I am involved in project that is based on the MCF5328 and using an Optrex 640 x 480 display.&amp;nbsp; For our purpose I found that the framebuffer&amp;nbsp;at 18 bpp took too much bus bandwidth. I wrote an alternate display driver instead of using the framebuffer/microwindows and we run mostly in 8 bpp which allows not having LCDC at the highest priority.&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Jun 2009 20:38:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Microwindows-M5329x-Framebuffer-and-LTIB/m-p/171368#M6383</guid>
      <dc:creator>obidon</dc:creator>
      <dc:date>2009-06-25T20:38:42Z</dc:date>
    </item>
  </channel>
</rss>

