LCDInfo.com

http://www.lcdinfo.com
It is currently Fri Nov 22, 2024 9:55

All times are UTC + 2 hours




Post new topic Reply to topic  [ 63 posts ]  Go to page 1, 2, 3, 4, 5  Next
Author Message
 Post subject: LCD demos
PostPosted: Mon Aug 15, 2005 12:51 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
Have you tried to program your display on your own and have something interresting to show? :wink:


http://oms.wmhost.com/lcd/pcd8544.avi


Last edited by Zee on Fri May 19, 2006 13:48, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 15, 2005 14:16 
Offline
User avatar

Joined: Sat Apr 17, 2004 17:42
Posts: 467
Location: The Netherlands
VERY nice dude! Is it in color BTW?

_________________
My Plexeon-Insane LCD!-Or this one!-LCDinfo-LCDStudio


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 15, 2005 16:39 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
Only black'n'white currently. Still waiting to get a new working color display to play with.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 17, 2005 23:48 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
Punishing Optrex DMF5001NY-LY :)

Image

Image


Not so great in the Nokia style...

Image

Image


Last edited by Zee on Fri May 19, 2006 13:48, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 18, 2005 21:19 
Offline

Joined: Fri Jul 23, 2004 3:33
Posts: 16
Location: Norway
That's pretty damn awesome! Niiiice work :D

_________________
- Rexxie


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 22, 2005 11:32 
Offline

Joined: Wed Jul 27, 2005 8:47
Posts: 9
Location: Moscow, Russia
Very impressive ;-). Do u use some LCD Drivers or u connect LCD directly to PC? Very nice work!!!!!!!!My congratulations!!!.

_________________
AC/DC \m/ =)


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 22, 2005 13:40 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
It's hardly practical to control displays without dedicated controller. :)

Optrex uses T6963C and the Nokia display PCD8544. Both panels are controlled through the LPT port.

I can currently refresh the full area of the Nokia display at about 75fps and the Optrex should be able to work at around 120fps (haven't measured with it yet) as it's 8-bit compared to the PCD which is 1-bit. The LPT port seems to be able to output data at ~300kb/s. Don't know how CPU dependant it is but board manufacturers really should recreate the electronics for this still so handy utility-port. :)

Both displays are currently written without any delays without problems but the PCD seems to be picky about the cable length and needs some delay in the initialization.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 23, 2005 21:02 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
These are made to work with my 160x128 Optrex panel so changes are needed to make them work on others.

Also, I'm not one of the cleanest programmers. :)


Simple 4x4 & 16x16 ordered dithering for 8-bit grayscale image.
Code:
unsigned char dithmap[] = {0x00, 0x88, 0x22, 0xaa, 0xcc, 0x44, 0xee, 0x66, 0x33, 0xbb, 0x11, 0x99, 0xff, 0x77, 0xdd, 0x55};

            if ((sourcepixel+dithmap[(x&3)+((y&3)<<2)])>>8 == 1)
            {
               Plot(x,y);
            }


unsigned char dithmap16[] = {0x00, 0x80, 0x20, 0xA0, 0x08, 0x88, 0x28, 0xA8, 0x02, 0x82, 0x22, 0xA2, 0x0A, 0x8A, 0x2A, 0xAA,
0xC0, 0x40, 0xE0, 0x60, 0xC8, 0x48, 0xE8, 0x68, 0xC2, 0x42, 0xE2, 0x62, 0xCA, 0x4A, 0xEA, 0x6A,
0x30, 0xB0, 0x10, 0x90, 0x38, 0xB8, 0x18, 0x98, 0x32, 0xB2, 0x12, 0x92, 0x3A, 0xBA, 0x1A, 0x9A,
0xF0, 0x70, 0xD0, 0x50, 0xF8, 0x78, 0xD8, 0x58, 0xF2, 0x72, 0xD2, 0x52, 0xFA, 0x7A, 0xDA, 0x5A,
0x0C, 0x8C, 0x2C, 0xAC, 0x04, 0x84, 0x24, 0xA4, 0x0E, 0x8E, 0x2E, 0xAE, 0x06, 0x86, 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+((y&15)<<4)])>>8 == 1)
            {
               Plot(x,y);
            }




Floyd-Steinberg dithering for 8-bit grayscale image (160x128 in this case). workbuf/worktemp are both the size of the image in pixels to be processed. All variables are int:
Code:
      for (bcy=0; bcy<128; bcy++)
      {
         for (bcx=0; bcx<160; bcx++)
         {
            imagepixel=workbuf[bcx+(bcy<<7)+(bcy<<5)];
            temppixel=worktemp[bcx+(bcy<<7)+(bcy<<5)];
            newpixel=imagepixel+temppixel;
            if (newpixel<=127.5)
            {
               level=0;
            }
            else
            {
               level=255;
            }
            diff=(newpixel-level)>>4;
            diff3=diff+diff+diff;
            diff5=diff+diff+diff3;
            diff7=diff+diff+diff5;
            if (bcx<159) worktemp[(bcx+1)+(bcy<<7)+(bcy<<5)]=worktemp[(bcx+1)+(bcy<<7)+(bcy<<5)]+diff7;
            if ((bcx>0) && (bcy<127)) worktemp[(bcx-1)+((bcy+1)<<7)+((bcy+1)<<5)]=worktemp[(bcx-1)+((bcy+1)<<7)+((bcy+1)<<5)]+diff3;
            if (bcy<127) worktemp[bcx+((bcy+1)<<7)+((bcy+1)<<5)]=worktemp[bcx+((bcy+1)<<7)+((bcy+1)<<5)]+diff5;
            if ((bcx<159) && (bcy<127)) worktemp[(bcx+1)+((bcy+1)<<7)+((bcy+1)<<5)]=worktemp[(bcx+1)+((bcy+1)<<7)+((bcy+1)<<5)]+diff;
            if (imagepixel!=0 && level!=0)
            {
               buffer[(bcx>>3)+(bcy<<2)+(bcy<<4)]=buffer[(bcx>>3)+(bcy<<2)+(bcy<<4)] | (1<<(7-(bcx&7)));
            }
         }
      }


Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 24, 2005 7:12 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
http://oms.wmhost.com/lcd/patriotic_cellphone.avi


Last edited by Zee on Fri May 19, 2006 13:49, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Wed Aug 24, 2005 16:56 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
One oldie effect...

Code:
   int x, y, l, diam, temp, count=0;
   double sintab[360], costab[360], d=0;

   for (l=0;l<360;l++)
   {
      sintab[l]=sin(d);
      costab[l]=cos(d);
      d=d+(6.283185307/360);
   }

   do
   {
      temp=count;
      for (diam=8; diam<140; diam=diam+2)
      {
         x=sintab[count]*32+80;
         y=costab[count]*32+64;
         count=count-7;
         if (count<0) count+=360;
         for (l=0; l<360; l=l+4)
         {
            Plot(x+sintab[l]*(diam+(costab[count]*5)),y+costab[l]*(diam+(sintab[count]*5)));
         }
      }
      count=temp+4;
      if (count>359) count-=360;
   } while (!kbhit());


Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 25, 2005 23:17 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
Another classic...

Code:
   const unsigned int   swidth   = 160;
   const unsigned int   sheight   = 128;

   unsigned char buffer[swidth/8*sheight], texture[128*128], workbuf[swidth*sheight];
   char worktemp[swidth*sheight];
   double sintab[360], costab[360], z, zoom, zoominc;
   int i, d1, d2, x, y, x1, y1, x2, y2, x3, y3;

   z=0;
   d1=0;
   d2=180;
   zoom=1;
   zoominc=0.0025;

   for (i=0;i<360;i++)
   {
      sintab[i]=sin(z);
      costab[i]=cos(z);
      z=z+(6.283185307/360);
   }

   for(y=0; y<128; y++)
   {
      for(x=0; x<128; x++)
      {
         texture[x+y*128] = (x ^ y) * 2;
      }
   }

   do
   {
      for (i=0; i<sizeof(buffer); i++)
      {
         buffer[i]=0;
      }
      for (i=0; i<sizeof(workbuf); i++)
      {
         workbuf[i]=0;
         worktemp[i]=0;
      }
      y2=-(sheight>>1);
      for (y1=0; y1<sheight; y1++)
      {
         x3=sintab[d1]*y2/zoom;
         y3=costab[d1]*y2/zoom;
         x2=-(swidth>>1);
         for (x1=0; x1<swidth; x1++)
         {
            x=sintab[d2]*x2/zoom+x3;
            y=costab[d2]*x2/zoom+y3;
            workbuf[x1+y1*swidth] = texture[((64+x)&127)+(((64+y)&127)<<7)];
//            sourcepixel = texture[((64+x)&127)+(((64+y)&127)<<7)];
/*   Use ordered dithering here.   */
            x2++;
         }
         y2++;
      }
/*   Use FS dithering here.      */
/*   Send buffer to LCD here.   */
      d1+=4;
      if (d1>359) d1-=360;
      d2+=4;
      if (d2>359) d2-=360;
      zoom+=zoominc;
      if ((zoom<0.03) || (zoom>1)) zoominc=-zoominc;
   } while (!kbhit());


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 27, 2005 9:06 
Offline

Joined: Wed Jul 27, 2005 8:47
Posts: 9
Location: Moscow, Russia
Zee I found your theme on Development, do u have problems with init on SED1335 (S1D13305)?

_________________
AC/DC \m/ =)


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 27, 2005 16:20 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
Solved it a while ago with some help from Henri and using a source example for KS-controlled displays. The main problem was with using winio, but everythings running fine now.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 27, 2005 17:08 
Offline

Joined: Wed Jul 27, 2005 8:47
Posts: 9
Location: Moscow, Russia
I have such a question. What time is needed to load 320*240 image true the SED1335. It takes on my device 5 - 8 secs, is it too slow?

_________________
AC/DC \m/ =)


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 27, 2005 18:12 
Offline

Joined: Wed Aug 03, 2005 20:27
Posts: 130
Location: .fi
For me, transferring 320x240 image takes around 45 milliseconds.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 63 posts ]  Go to page 1, 2, 3, 4, 5  Next

All times are UTC + 2 hours


Who is online

Users browsing this forum: No registered users and 18 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group