LCDInfo.com

http://www.lcdinfo.com
It is currently Thu Nov 21, 2024 23:30

All times are UTC + 2 hours




Post new topic Reply to topic  [ 288 posts ]  Go to page Previous  1 ... 14, 15, 16, 17, 18, 19, 20  Next
Author Message
 Post subject: Can it be faster?
PostPosted: Tue Mar 18, 2008 13:29 
Offline

Joined: Thu Mar 06, 2008 15:40
Posts: 7
Hello everybody!

I got this Display to work with a PSoC at 24MHz. I would like to plot some real time lines, but it seems too slow! It´s taking about 128ms for each line plotting.

Do you know if this display can plot faster with this processor? Today I am using PASET, CASET and then the RAMWR commands to plot each pixel of my lines.

Thanks!

Rick


Top
 Profile  
 
 Post subject: LCD Colors?
PostPosted: Fri Jun 06, 2008 14:58 
Offline

Joined: Mon Jun 02, 2008 20:29
Posts: 1
Would someone mind explaining how the colors work? I have the epson lcd and I think I am in 16 tone 16 gray scale mode (although I'm not sure about that either)...when I use RAMWR I follow that command with the data for the colors...I can't get them figured out, how to get solid colors? How many lines of data do i need to send? If I follow it with 0x0F, 0xF1 and 0xF2 I get a sort of light green color, I don't know why though....

Help?
Please and thank you!
Sjr


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 24, 2008 14:47 
Offline

Joined: Mon Jun 30, 2008 17:01
Posts: 5
Location: Italy
Does anyone know what type of controller has nokia LCD with 65K, 262K colors? (like nokia 7360, 7390, ...)

thanks


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 25, 2008 0:49 
Offline

Joined: Mon Aug 02, 2004 12:18
Posts: 16
Location: lisboa
[quote="Béci"]Hi Everyone,

I have recently disassembled an original 3100 phone and I'm still a bit confused about the controller it has. On the first page of this topic, Schijf says the one with the brown PCB uses a Philips controller and the green one uses Epson. It should be true because I've read this on many other sites. But according to Mike's Electric Stuff
[url]http://www.electricstuff.co.uk/noklcd.html[/url]
it should be a Philips one with a GREEN PCB on the back.

So, this is what I have:
[img]http://www.electricstuff.co.uk/noklcd9.jpg[/img]
[img]http://www.electricstuff.co.uk/noklcd10.jpg[/img]

I've tried drivers for both controllers with an ATMega8, but none of them worked. (HW and LCD pinouts seem to be ok).

Please let me know if you have any idea. Any help shall be fine as I've recently started using LCD-s. Thank you very much![/quote]

any solution on this??
tks


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 25, 2008 12:06 
Offline

Joined: Mon Aug 02, 2004 12:18
Posts: 16
Location: lisboa
Problem Fix... change Voltage regulator from 3,3V to 2,5V (AMC1117-2.5)


Top
 Profile  
 
PostPosted: Fri Aug 01, 2008 15:36 
Offline

Joined: Fri Aug 01, 2008 13:33
Posts: 1
HI i have some problem with nokia 6100 lcd (philips) i want to display a picture and charcters to the lcd but dosen't work i use this code

If you try with another function for example draw() it will work











#include "PCF8833U8_lcd.h"
#include <avr/io.h>
#include <util/delay.h>

#include "bmp.h"
///////////////////////////////////
#define F_CPU 12000000UL //
#define SPIPORT PORTA
#define SPIDDR DDRA
#define CS 4
#define CLK 3
#define SDA 2
#define RESET 1
////////////////////////////////////
// Font sizes
#define SMALL 0
#define MEDIUM 1
#define LARGE 2
//////////////////////////////////////
// 12-bit color definitions
#define WHITE 0xFFF
#define BLACK 0x000
#define RED 0xF00
#define GREEN 0x0F0
#define BLUE 0x00F
#define CYAN 0x0FF
#define MAGENTA 0xF0F
#define YELLOW 0xFF0
#define BROWN 0xB22
#define ORANGE 0xFA0
#define PINK 0xF6A
///////////////////////////////////
#define USR UCSRA
#define UCR UCSRB
#define UBRR UBRRL
#define BAUD_RATE 38400
//#define MODE565
////////////////////////////
#define cbi(reg, bit) (reg&=~(1<<bit))
#define sbi(reg, bit) (reg|= (1<<bit))
#define CS0 cbi(SPIPORT,CS);
#define CS1 sbi(SPIPORT,CS);
#define CLK0 cbi(SPIPORT,CLK);
#define CLK1 sbi(SPIPORT,CLK);
#define SDA0 cbi(SPIPORT,SDA);
#define SDA1 sbi(SPIPORT,SDA);
#define RESET0 cbi(SPIPORT,RESET);
#define RESET1 sbi(SPIPORT,RESET);
#define byte unsigned char
byte n=0;
byte s1,s2;
byte r,g,b;
///////////////////////////////////
void sendCMD(byte cmd);
void sendData(byte cmd);
void shiftBits(byte b);
void setPixel(byte r,byte g,byte b);
///////////////////////////
const unsigned char FONT6x8[97][8];
const unsigned char FONT8x8[97][8];
const unsigned char FONT8x16[97][16];

int main(void)
{

InitLCD();
//LCD_Circle(40,30,30,LightGreen);
//LCD_Fill(0,0,132,132,0,255,0);
//LCD_Fill(50,50,90,90,0,0,255);
//LCD_Box(0,10,50,100,0,255,0);
//LCD_Circle(40,30,30,0,255,0);

//draw();
//ShowImage(0,0,bmp[6206]);

LCDPutChar('Eeeeeeee', 20, 20, MEDIUM,0,255,0);

//LCDSetCircle(50,50,100,0,255,0);



}
void InitLCD(void)
{
SPIDDR=(1<<SDA)|(1<<CLK)|(1<<CS)|(1<<RESET); //Port-Direction Setup

CS0
SDA0
CLK1

RESET1
RESET0
RESET1

CLK1
SDA1
CLK1

waitms(10);
sendCMD(SWRESET);
sendCMD(SLEEPOUT);
sendCMD(BSTRON);
waitms(10);
sendCMD(DISON);
sendCMD(NORON);
sendCMD(INVON);
sendCMD(DOR);
sendCMD(MADCTL);
//sendCMD(RGBX);
sendData(RGBY);
//sendCMD(INVOFF);
#ifdef MODE565
sendCMD(COLMOD);
sendData(5); //16-Bit per Pixel
#else
//sendCMD(COLMOD);
//sendData(3); //12-Bit per Pixel (default)
#endif


/* sendCMD(RGBSET); // setup color lookup table
// Setup the color lookup table by choosing evenly spaced color values
// for a nice even spread. Blue only has 2 bits, so the spacing is wider
// but still spans 0x00 - 0x0f
// Bit organisation is RRRGGGBB

sendCMD(RGBSET);
sendData(0x00); // RED
sendData(0x02);
sendData(0x04);
sendData(0x06);
sendData(0x08);
sendData(0x0a);
sendData(0x0c);
sendData(0x0f);
sendData(0x00); // GREEN
sendData(0x02);
sendData(0x04);
sendData(0x06);
sendData(0x08);
sendData(0x0a);
sendData(0x0c);
sendData(0x0f);
sendData(0x00); // BLUE
sendData(0x04);
sendData(0x09);
sendData(0x0f);

sendCMD(NOP); // nop

sendCMD(INVON); // Inverted display mode

int i;;
for (i = 0; i < 160; i++)
{ // this loop adjusts the contrast, change the number of iterations to get
sendCMD(SETCON);
sendData(63); // desired contrast. This might be different for individual LCDs
waitms(2);
}*/



}









void waitms(int ms)
{
int i;
for (i=0;i<ms;i++) _delay_ms(1);
}
//////////////////////////////////
void shiftBits(byte b)
{

CLK0
if ((b&128)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&64)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&32)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&16)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&8)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&4)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&2)!=0) SDA1 else SDA0
CLK1

CLK0
if ((b&1)!=0) SDA1 else SDA0
CLK1

}
///////////////////////////////////
//send data
void sendData(byte data)
{

CLK0
SDA1 //1 for param
CLK1

shiftBits(data);
}

/////////////////////////////////
//send cmd
void sendCMD(byte data)
{

CLK0
SDA0 //1 for cmd
CLK1

shiftBits(data);
}
//////////////////////////////////
//converts a 3*8Bit-RGB-Pixel to the 2-Byte-RGBRGB Format of the Display
void setPixel(byte r,byte g,byte b)
{
#ifdef MODE565
sendData((r&248)|g>>5);
sendData((g&7)<<5|b>>3);
#else
if (n==0)
{
s1=(r & 240) | (g>>4);
s2=(b & 240);
n=1;
} else
{
n=0;
sendData(s1);
sendData(s2|(r>>4));
sendData((g&240) | (b>>4));
}
#endif
}
/////////////////////////////////////////
void LCDSetXY(int x, int y)
{
// Row address set (command 0x2B)
sendCMD(PASET);
sendData(x);
sendData(x);
// Column address set (command 0x2A)
sendCMD(CASET);
sendData(y);
sendData(y);
}
//////////////////////////////////////////////
void LCDSetPixel(int x, int y, int color)
{
LCDSetXY(x, y);
sendCMD(RAMWR);
sendData((unsigned char)((color >> 4) & 0xFFFF));
sendData((unsigned char)(((color & 0x0F) << 4) | 0x00));
sendCMD(NOP);
}
///////////////////////////////////
void draw()
{
//Column Adress Set
sendCMD(0x2A);
sendData(0);
sendData(131);

//Page Adress Set
sendCMD(0x2B);
sendData(0);
sendData(131);

//Memory Write
sendCMD(RAMWR);

int i;
//Test-Picture

//red bar
for (i=0;i<132*33;i++)
{
setPixel(255,0,0);
}

//green bar
for (i=0;i<132*33;i++)
{
setPixel(0,255,0);
}

//blue bar
for (i=0;i<132*33;i++)
{
setPixel(0,0,255);
}

//white bar
for (i=0;i<132*33;i++)
{
setPixel(255,255,255);
}
}
//////////////////////////////////////////
//*****************************************************************************
// Name: GotoXY(u_char x, u_char y)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: Sets position to x-y location on LCD
// Useage: GotoXY(param 1,param 2)
// param 1: x direction 0-131
// param 2: y direction 0-131
//
// Example: GotoXY(32,17);
//
// Notes: No bounds checking
//*******************************************************************************
void GotoXY(unsigned char x, unsigned char y)
{
sendCMD(PASET); // page start/end ram
sendData(y); // Start Page to display to
sendData(131); // End Page to display to

sendCMD(CASET); // column start/end ram
sendData(x); // Start Column to display to
sendData(131);
}

//*****************************************************************************
// Name: LCD_PixelPut(u_char x, u_char y, u_char color)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: Put One Pixel on LCD
// Useage: LCD_PixelPut(param 1,param 2,param 3)
// param 1: x direction 0-131
// param 2: y direction 0-131
// param 3: Color of Pixel, RRRGGGBB format
// Example: LCD_PixelPut(30,30,0x62) // put a purple pixel @ 30,30
//
// Notes: No bounds checking
//*******************************************************************************
void LCD_PixelPut(unsigned char x, unsigned char y, unsigned char color)
{
GotoXY(x,y);
sendCMD(RAMWR); // Now write the pixel to the display
sendData(color); // Write the data in the specified Color
}
void pixel(unsigned char x, unsigned char y, byte r, byte g, byte b)
{
GotoXY(x,y);
sendCMD(RAMWR);
setPixel(r,g,b);
}

//*****************************************************************************
// Name: LCD_Fill (u_char xs,u_char ys,u_char width,u_char height, u_char color)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: Fills an area starting @ xs,ys to width @ heighth with color
// Useage: LCD_Fill(param 1,param 2,param 3,param 4,param 5)
// param 1: x start direction: 0-131
// param 2: y start direction: 0-131
// param 3: width: 0-131
// param 4: heighth: 0-131
// param 5: Color of Pixel, RRRGGGBB format
//
// Example: LCD_Fill(0,0,132,132,Black); // fill entire screen with black color
//
// Notes: No bounds checking
//*******************************************************************************
void LCD_Fill (unsigned char xs,unsigned char ys,unsigned char width,unsigned char height, byte r, byte g, byte b)
{
unsigned char i,j;
//
for (i=0;i < height;i++) // Number of horizontal lines
{ //
GotoXY(xs,ys+i); // Goto start of fill area (Top Left)
sendCMD(RAMWR); // Write to display
//
for (j=0;j < width;j++) // pixels per line
{ //
setPixel(r,g,b); //
} //
//
sendCMD(NOP); // End
}
}

///******************************************************************************
// Name: LCD_Funct_A(x1, y1, x2, y2, pixel_on_off, ram_or_lcd)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: Used with LCD line function
//*******************************************************************************
void LCD_Funct_A(unsigned char x1, unsigned char y1, unsigned char x2, unsigned char y2, unsigned char color )
{
float a,b;
unsigned char x,y; //
//
//
b = (float)((y2 - y1) + 1) / (float)((x2-x1) + 1); //
//
a = y1; //
//
//
for(x = x1;x <= x2; x++) //
{ //
//
for(y=(unsigned char)a;y <= (unsigned char)(a + b); y++) //
{ //
if(y <= y2) //
{ //
GotoXY(x,y); // Goto start of fill area (Top Left)
sendCMD(RAMWR); // write to display
sendData(color); //
} //
} //
//
a+=b; //
} //
}
//******************************************************************************
// Name: LCD_Funct_B(x1, y1, x2, y2, pixel_on_off, ram_or_lcd)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: Used with LCD line function
//*******************************************************************************
void LCD_Funct_B(unsigned char x1, unsigned char y1, unsigned char x2, unsigned char y2, unsigned char color )
{
float a,b;
unsigned char x,y; //
//
b = (float)((y2 - y1) + 1) / (float)((x1-x2) + 1); //
//
a = y1; //
//
for(x = x1;x >= x2; x--) //
{ //
for(y=(unsigned char)a;y <= (unsigned char)(a + b); y++) //
{ //
if(y <= y2) //
{ //
GotoXY(x,y); // Goto start of fill area (Top Left)
sendCMD(RAMWR); // write to display
sendData(color); //
} //
} //
a+=b; //
} //
}
//******************************************************************************
// Name: LCD_Line(x1, y1, x2, y2, pixel_on_off, ram_or_lcd)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: To draw or remove a line from the LCD
// Notes: No bounds checking
//*******************************************************************************
void LCD_Line(unsigned char x1, unsigned char y1, unsigned char x2, unsigned char y2, unsigned char color)
{

if( (x1 <= x2) && (y1 <= y2) ) //
{ //
LCD_Funct_A(x1,y1,x2,y2,color); //
} //
//
else if( (x1 > x2) && (y1 < y2) ) //
{ //
LCD_Funct_B(x1,y1,x2,y2,color); //
} //
//
else if( (x1 >= x2) && (y1 >= y2) ) //
{ //
LCD_Funct_A(x2,y2,x1,y1,color); //
} //
//
else if( (x1 < x2) && (y1 > y2) ) //
{ //
LCD_Funct_B(x2,y2,x1,y1,color); //
} //
//
}
//******************************************************************************
// Name: LCD_Box(x1, y1, x2, y2, pixel_on_off, ram_or_lcd)
// Copyright: Free to use at will & at own risk.
// Author: JCP
// Date: 03.30.06 17:10
// Description: To draw a BOX on the LCD
// Notes: No bounds checking
//*******************************************************************************
void LCD_Box(unsigned char x1, unsigned char y1, unsigned char x2, unsigned char y2, byte r, byte g, byte b)
{
unsigned char x,y;

x = x1; //
y = y1; //
//
while(x <= x2) //
{ //
pixel(x,y1,r,g,b); //
pixel(x,y2,r,g,b); //
//
x++; //
} //
//
while(y <= y2) //
{ //
pixel(x1,y,r,g,b); //
pixel(x2,y,r,g,b); //
//
y++; //
} //
}
//******************************************************************************
// Name: LCD_Circle
// Copyright: Free to use at will & at own risk.
// Date: 03.30.06 17:10
// Description: To Draw a Circle on LCD
// Useage: LCD_Circle(param 1,param 2,param 3,param 4)
//
// param 1: x location on screen, 0 - 127
// param 2: y location on screen, 0 - 63
// param 3: diameter of circle
// param 4: Color of Pixel, RRRGGGBB format
//
// Example: LCD_Circle(40,30,30,LightGreen);
// Notes: No bounds checking
//*******************************************************************************
void LCD_Circle(unsigned char center_x, unsigned char center_y, unsigned int rad, unsigned char color)
{
unsigned int x;
unsigned int y;

x = 0;
y = rad;

while (x <= y)
{
// We make use of 8 axes of symmetry in a circle.
// This way we have fewer points to calculate on its circumference.
pixel (center_x + (unsigned char)x, center_y + (unsigned char)y,r,g,b);
pixel (center_x - (unsigned char)x, center_y + (unsigned char)y,r,g,b);
pixel (center_x + (unsigned char)x, center_y - (unsigned char)y,r,g,b);
pixel (center_x - (unsigned char)x, center_y - (unsigned char)y,r,g,b);
pixel (center_x + (unsigned char)y, center_y + (unsigned char)x,r,g,b);
pixel (center_x - (unsigned char)y, center_y + (unsigned char)x,r,g,b);
pixel (center_x + (unsigned char)y, center_y - (unsigned char)x,r,g,b);
pixel (center_x - (unsigned char)y, center_y - (unsigned char)x,r,g,b);

// This is the most important part of the function.
// We go to the right in all cases (x++).
// We need to decide whether to go down (y--).
// This depends on which point is
// closest to the path of the circle.
// Good old Pythagoras will tell us what to do.
x++;


if( abs( (x * x) + (y * y) - (rad * rad) ) > abs( (x * x) + ((y-1)*(y-1)) - (rad * rad)) )
{
y--;
}
}



}
//******************************************************************************
// Name: LCD_Thick_Circle
// Copyright: Free to use at will & at own risk.
// Date: 03.30.06 17:10
// Description: To Draw a Definable Thickness Circle on LCD
// Useage: LCD_Thick_Circle(param 1,param 2,param 3,param 4,param 5)
// param 1: x start direction: 0-131
// param 2: y start direction: 0-131
// param 3: diameter: 0-255
// param 4: Thickness of circle wall in pixels
// param 5: Color of Pixel, RRRGGGBB format
//
// Example: LCD_Thick_Circle(66,66,30,2,0x62);
// start @ 66,66, with a diamater of 30, 2 pixels thick in purple
//
// Notes: No bounds checking
//*******************************************************************************
void LCD_Thick_Circle(unsigned char center_x, unsigned char center_y,unsigned char diameter, unsigned char thick,unsigned char color)
{
unsigned int a;

for(a=0;a < 360;a++)
{
// LCD_Circle_Line(center_x,center_y,diameter,(diameter + thick),a,color);
}
}
/////////////////////////////////////////////////////////////////////////////////////////
/*void ShowImage(unsigned char x, unsigned char y, const unsigned char *location)
{
unsigned char x_max,y_max;
unsigned char x_logo,y_logo;

x_max = *location;
location++;
y_max = *location;
location++;

for(y_logo=0;y_logo <y_max;y_logo++)
{
GotoXY(x,y + y_logo);
sendCMD(RAMWR); // Now write the pixel to the display

for(x_logo=0;x_logo < x_max;x_logo++)
{
sendData(*location); // Write the data in the specified Color

location++;
}
}



}

//******************************************************************************
// Name: LCD_String
// Copyright: Free to use at will & at own risk.
// Date: 03.30.06 17:10
// Description: To print a string of characters to LCD
// Useage: LCD_String(param 1,param 2,param 3,param 4,param 5,param 6)
//
// param 1: String data
// param 2: pointer to data lookup table (I.E. Font table)
// param 3: x start direction: 0-131
// param 4: y start direction: 0-131
// param 5: Font Color, RRRGGGBB format
// param 5: Background color, RRRGGGBB format
//
// Example: sprintf(thestring,"Hello World");
// LCD_String(thestring,_FONT6x8,52,25,White,Black);
//
// print "Hello World" in white text on a black background
//
// Notes: No bounds checking
//*******************************************************************************
void LCD_String (unsigned char *the_string, unsigned char Size,unsigned char x, unsigned char y, unsigned char fcolor, unsigned char bcolor)
{
unsigned int i,j;
unsigned char Mask,z,xme,yme,mult; //
unsigned char *slave; //
unsigned char *Data; //
//
unsigned char FONT8x8F; //
//
if(Size==FONT8x8F) //
{ //
slave = FONT8x8F; //
xme = 8; //
yme = 8; //
mult= 8; //
} //
//
//
//
do //
{ //
//
Data = slave + (mult * (int)(*the_string - 32)); //
//
for (i=0;i < yme;i++) // 10 bytes per char 15
{ //
Mask |=0x80; //
//
for (j=x;j < (x + xme);j++) //
{ //
//
z= y + i; //
//
if (*Data & Mask) //
{ //
pixel (j,z,0,255,0); //
} //
else //
{ //
pixel (j,z,0,0,255); //
} //
//
Mask>>=1; //
} //
//
Data++; //
} //
//
x+=xme; //
//
the_string++; //
//
}while(*the_string !='\0'); // keep spitting chars until end
//
sendCMD(NOP); // Recomended to send now and then
}
*/


void LCDPutChar(char c, int x, int y, int size, byte r, byte g, byte b)
{
extern const unsigned char FONT6x8[97][8];
extern const unsigned char FONT8x8[97][8];
extern const unsigned char FONT8x16[97][16];
int i,j;
unsigned int fColor ;
unsigned int bColor;
unsigned int nCols;
unsigned int nRows;
unsigned int nBytes;
unsigned char PixelRow;
unsigned char Mask;
unsigned int Word0;
unsigned int Word1;
unsigned char *pFont;
unsigned char *pChar;
unsigned char *FontTable[] = {(unsigned char *)FONT6x8,(unsigned char *)FONT8x8,(unsigned char *)FONT8x16};// get pointer to the beginning of the selected font table
pFont = (unsigned char *)FontTable[size];// get the nColumns, nRows and nBytes
nCols = *pFont;
nRows = *(pFont + 1);
nBytes = *(pFont + 2);// get pointer to the last byte of the desired character
pChar = pFont + (nBytes * (c - 0x1F)) + nBytes - 1;// Row address set (command 0x2B)
sendCMD(PASET);
sendData(x);
sendData(x + nRows - 1);// Column address set (command 0x2A)
sendCMD(CASET);
sendData(y);
sendData(y + nCols - 1);// WRITE MEMORY
sendCMD(RAMWR);// loop on each row, working backwards from the bottom to the top
for (i = nRows - 1; i >= 0; i--)
{
// copy pixel row from font table and then decrement row
PixelRow = *pChar--;
// loop on each pixel in the row (left to right)
// Note: we do two pixels each loop
Mask = 0x80;
for (j = 0; j < nCols; j += 2)
{
// if pixel bit set, use foreground color; else use the background color
// now get the pixel color for two successive pixels
if ((PixelRow & Mask) == 0)
{
Word0 = bColor;
setPixel(r,g,b);
}
else
Word0 = fColor;
setPixel(0,255,0);
Mask = Mask >> 1;
if ((PixelRow & Mask) == 0)
{
Word1 = bColor;
setPixel(r,g,b);
}
else
Word1 = fColor;
setPixel(r,g,b);
Mask = Mask >> 1;
// use this information to output three data bytes
sendData((Word0 >> 4) & 0xFF);
sendData(((Word0 & 0xF) << 4) | ((Word1 >> 8) & 0xF));
sendData(Word1 & 0xFF);
}
}
// terminate the Write Memory command
sendCMD(NOP);
}


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 09, 2008 16:38 
Offline

Joined: Mon Jun 20, 2005 23:03
Posts: 161
Location: Hong Kong
A 3D raycaster in the vain on Wolfenstein3D using Henri's USB13700 board
more info here.
Image


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 09, 2008 21:32 
Offline

Joined: Sat Aug 09, 2008 21:11
Posts: 8
Hi guys, and galls ?? :-)

I've ordered a Sparkfun Nokia 6100 breakout board.
I'm not a total newbie.
Here's one of my previous 'projects'.
http://myweb.tiscali.co.uk/taximania/pic2.html
The pic code was pure MPLAB asm

Couple of questions:
1> Has anyone got a 6100 lcd working via pure MPLAB asm ?

2> Will a LM317 voltage regulator, 3.3V, power the LCD and a PIC ,
or will I need an extra power supply for the PIC ?

3> If I run the PIC at 5-6V, can I interface it directly with the LCD thats connected to a 3.3V supply.
Or would I need a voltage converter board between the lines ?

TIA
Barry


Top
 Profile  
 
PostPosted: Wed Aug 13, 2008 23:53 
Offline

Joined: Wed Aug 13, 2008 23:01
Posts: 1
Hello-

The posts I've read here make it seem like everybody is having no trouble at all getting the screen to do things- I can't even seem to get it to come on.

I purchased the screen with the breakout board from Sparkfun:

http://www.sparkfun.com/commerce/produc ... ts_id=8600

My first attempt was to connect this to the 18F66J10 from Microchip. The Reset, DIO, SCK, and CS lines are connected to PORTD pins on the 66J10. The 3.3V line goes into regulated voltage and I attach the Vbatt line to 6 - 7.5V (in my experiments I've varied how I source this voltage).

When I power the system, the screen lights up and has a dark blue color. I follow the routine outlined in the 'tutorial' provided by Sparkfun:

http://www.sparkfun.com/tutorial/Nokia% ... Driver.pdf

Since the 18F66J10 has 8-bit SPI only, I had to write a bit-bang routine for 9-bit SPI. Since there are no connections to receive data from the screen, I can look at my SPI output on the o'scope and my transmissions look correct but I can't be sure the screen likes them. I follow the recommended Reset process and then I send all the Epson initialization commands mentioned in the tutorial document (including all the additional delays specified by that document). Afterwards I send the PASET/CASET/RAMWR values with values I expect to produce a red color, but the screen has no change. In fact, once power is applied to the screen the appearance never changes at all. After sending all the commands in the tutorial, I would expect at least something to happen on the screen.

Just in case my SPI is at fault, I then attached the screen to the ColdFire M52233 demo board, which gives me 9-bit hardware SPI. But I get the same results here, after following the steps from the tutorial, the screen has no changes in appearance.

Something else that is odd, on the Sparkfun schematic for their board, the Vbatt line goes to a voltage-boosting circuit and then connects to the Vled line on the screen. However, if I don't source this line, then the whole screen goes black just as when it has no power at all. Sparkfun's website gives examples of attaching up to 6V to the Vbatt line, but if this somehow ties into the main voltage lines for the display, then maybe the Vbatt line should not be used on voltages over 3.3V? This whole process has been very confusing.

If anybody (especially people using PICs) can explain exactly how they wired up the screen to get it to work it might help me. It really frustrates me that the Slave-Out SPI lines are unimplemented since there is no way to check if the commands being sent are even getting through.


Top
 Profile  
 
PostPosted: Mon Aug 25, 2008 22:40 
Offline

Joined: Mon Aug 25, 2008 22:33
Posts: 1
Eqqman wrote:
Hello-

The posts I've read here make it seem like everybody is having no trouble at all getting the screen to do things- I can't even seem to get it to come on.
<snip>

Are you sure that the LCD you have is indeed using the Epson controller? I bought the breakout board with included LCD from SparkFun just a few weeks ago and it turned out it was using the Phillips controller. I'm going to post a question of my own beneath here and I'm including the initialization code that worked for me (it's a horrible cut and paste job from several different code snippets and tutorials that finally made it wake up. I'm not even sure I need half of the stuff to be honest).

################################################

After a couple of weeks of on and off trying to get this to work I'm turning to you guys to put me out of my misery.

I'm trying to use the display in 4096 colour mode sending the colour in this format to the display "0000RRRR GGGGBBBB" as shown here. However, it seems that my display is receiving data in a RBG order rather than the more sane RGB order.

In the pic below I'm drawing a box of Red, Green and Blue however, it is showing Red, Blue, Green. By reversing the last byte of the colour it seems to display normally (see code at the end of the post). I guess I could live with that for simple stuff. However, when trying to display a picture this doesn't seem to work out.

At the top of the image you'll see 8 strips of random junk which should actually be displaying the colours of the rainbow (you can see the blurry original on my computer above the LCD). I'm using the program found here to convert the 24bit BMP that I created as a test. I'm telling the program to spit the data out in its "12bit B" format which looks like this "XXXXRRRR GGGGBBBB".

The 8 strips of garbled coloured dots represent me sending the data from the program in different ways. Top to bottom and non reversed, one byte reversed, last reversed and finally all reversed. Nothing seems to do the trick.

The colours are also very washed out (tweaking the contrast doesn't do much more than either blowing them completely or making the screen darker than is useful while still having washed out colours).

Image

Right, time for the guts. I'm using this to initialize the display (Phillips btw):
Code:
// From http://www.idcomm.com/personal/lorenblaney/lcdcode.txt
void initLcd(void) {       

   LCD_RES = 0;  // reset the controller
   DelayMs(10);
   LCD_RES = 1;
   DelayMs(10);
   LCD_CS = 0;     // enable the chip
   
   LCD_command(DISCTL); // Display control
   LCD_data(0);  //0    // 2 divisions, switching period=8 (default)
   LCD_data(32); //32    // nlines/4 - 1 = 132/4 - 1 = 32)
   LCD_data(0);  //0     // no inversely highlighted lines

   LCD_command(COMSCN); // Common scan directions
   LCD_data(1);     // Scan 1->80, 160<-81
   
   LCD_command(OSCON);  // turn on internal oscillator
   
   LCD_command(SLEEPOUT); // Sleep out
   
   LCD_command(SETCON);   //Set Contrast(PHILLIPS)
   //LCD_data(0x30);   //ebay
   LCD_data(0x33);   //sparkfun
   
   LCD_command(BSTRON);
   
   LCD_command(PWRCTR); // Power control
   LCD_data(0x0F);  // everything on: reference voltage, regulator,
                   //  circuit voltage follower, and boosters
   //LCD_command(DISINV); // Inverse display (for proper colors)
   
   LCD_command(INVON);
   
   LCD_command(MADCTL);   //Memory Access Control(PHILLIPS)
   LCD_data(0xC8);
   //LCD_data(0xC0);
   
   LCD_command(DATCTL); // Data control
   LCD_data(0x03);  // page address inverted, column address normal,
                   //  address scan in page direction
   LCD_data(0x00);  // RGB sequence (default) Yes, I've tried both 0x01 and 0xFF
   LCD_data(0x04);  // special mode selects 12-bit color for single pixels <==
   
   LCD_command(VOLCTR); // Voltage control
   LCD_data(5);    // contrast setting: 0..63
   LCD_data(3);     // resistance ratio (only value that works)
   
   LCD_command(DISPON);  // turn on the display
   
   fillWin(setWin(0, 0, 130, 130), 0x0000); // clear display memory
   
   DelayMs(100);   // wait for power supply voltage to stabilize
   

} // initLcd


Functions for defining "window" size and filling said "window"
Code:
int setWin(int x0, int y0, int x1, int y1) {
// Set rectangular area for a window on the LCD
// Returns its area (in pixels)
    int t;

    if (x0>x1) {t=x0; x0=x1; x1=t;}     // put coordinates into ascending order
    if (y0>y1) {t=y0; y0=y1; y1=t;}

    LCD_command(CASETP);      // set column address
    LCD_data(x0);      // start (visible area starts in column 2)
    LCD_data(x1);      // end

    LCD_command(PASETP);      // set page (row) address
    LCD_data(y0);        // start
    LCD_data(y1);        // end

return (x1-x0+1) * (y1-y0+1);   // area
} // setWin
void fillWin(int area, int color) {     // Fill window with specified color
    int i;
    LCD_command(RAMWRP);
    for (i=0; i<area; i++) {
        LCD_data(color>>8);
       LCD_data(color);      // Reversing the order of this fixes the small boxes
    }
} // fillWin


This is the data I'm using for displaying the image (can't seem to fit much more than this into the 16f886 so I guess I need to learn how to handle external EEPROMs now too...):
Code:
const unsigned char bitmap[]=
{
      0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x01, 0x0F, 0x02, 0x0F, 0x02, 0x0F, 0x03, 0x0F, 0x04, 0x0F, 0x05, 0x0F, 0x06, 0x0F, 0x07, 0x0F, 0x08,
      0x0F, 0x09, 0x0F, 0x0A, 0x0F, 0x0B, 0x0F, 0x0C, 0x0F, 0x0C, 0x0F, 0x0D, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F,
      0x0D, 0x0F, 0x0D, 0x0F, 0x0C, 0x0F, 0x0B, 0x0F, 0x0A, 0x0F, 0x0A, 0x0F, 0x09, 0x0F, 0x08, 0x0F, 0x07, 0x0F, 0x06, 0x0F, 0x06, 0x0F, 0x05, 0x0F,
      0x04, 0x0F, 0x03, 0x0F, 0x03, 0x0F, 0x02, 0x0F, 0x01, 0x0F, 0x01, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x1F, 0x00, 0x1F, 0x00, 0x2F,
      0x00, 0x3F, 0x00, 0x4F, 0x00, 0x4F, 0x00, 0x5F, 0x00, 0x6F, 0x00, 0x7F, 0x00, 0x8F, 0x00, 0x9F, 0x00, 0xAF, 0x00, 0xBF, 0x00, 0xBF, 0x00, 0xCF,
      0x00, 0xDF, 0x00, 0xEF, 0x00, 0xEF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFE, 0x00, 0xFD, 0x00, 0xFD, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0xFB,
      0x00, 0xFA, 0x00, 0xF9, 0x00, 0xF9, 0x00, 0xF8, 0x00, 0xF7, 0x00, 0xF6, 0x00, 0xF5, 0x00, 0xF4, 0x00, 0xF4, 0x00, 0xF3, 0x00, 0xF2, 0x00, 0xF2,
      0x00, 0xF1, 0x00, 0xF1, 0x00, 0xF0, 0x00, 0xF0, 0x00, 0xF0, 0x01, 0xF0, 0x02, 0xF0, 0x02, 0xF0, 0x03, 0xF0, 0x04, 0xF0, 0x04, 0xF0, 0x05, 0xF0,
      0x06, 0xF0, 0x07, 0xF0, 0x08, 0xF0, 0x09, 0xF0, 0x09, 0xF0, 0x0A, 0xF0, 0x0B, 0xF0, 0x0C, 0xF0, 0x0D, 0xF0, 0x0D, 0xF0, 0x0E, 0xF0, 0x0E, 0xF0,
      0x0F, 0xF0, 0x0F, 0xF0, 0x0F, 0xE0, 0x0F, 0xE0, 0x0F, 0xD0, 0x0F, 0xC0, 0x0F, 0xC0, 0x0F, 0xB0, 0x0F, 0xA0, 0x0F, 0x90, 0x0F, 0x80, 0x0F, 0x70,
      0x0F, 0x60, 0x0F, 0x50, 0x0F, 0x50, 0x0F, 0x40, 0x0F, 0x30, 0x0F, 0x20, 0x0F, 0x20, 0x0F, 0x10, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00,
      0x0F, 0x00, 0x0F, 0x01, 0x0F, 0x02, 0x0F, 0x02, 0x0F, 0x03, 0x0F, 0x04, 0x0F, 0x05, 0x0F, 0x06, 0x0F, 0x07, 0x0F, 0x08, 0x0F, 0x09, 0x0F, 0x0A,
      0x0F, 0x0B, 0x0F, 0x0C, 0x0F, 0x0C, 0x0F, 0x0D, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0D, 0x0F, 0x0D, 0x0F,
      0x0C, 0x0F, 0x0B, 0x0F, 0x0A, 0x0F, 0x0A, 0x0F, 0x09, 0x0F, 0x08, 0x0F, 0x07, 0x0F, 0x06, 0x0F, 0x06, 0x0F, 0x05, 0x0F, 0x04, 0x0F, 0x03, 0x0F,
      0x03, 0x0F, 0x02, 0x0F, 0x01, 0x0F, 0x01, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x1F, 0x00, 0x1F, 0x00, 0x2F, 0x00, 0x3F, 0x00, 0x4F,
      0x00, 0x4F, 0x00, 0x5F, 0x00, 0x6F, 0x00, 0x7F, 0x00, 0x8F, 0x00, 0x9F, 0x00, 0xAF, 0x00, 0xBF, 0x00, 0xBF, 0x00, 0xCF, 0x00, 0xDF, 0x00, 0xEF,
      0x00, 0xEF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFE, 0x00, 0xFE, 0x00, 0xFD, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0xFB, 0x00, 0xFA, 0x00, 0xF9,
      0x00, 0xF9, 0x00, 0xF8, 0x00, 0xF7, 0x00, 0xF6, 0x00, 0xF5, 0x00, 0xF4, 0x00, 0xF4, 0x00, 0xF3, 0x00, 0xF2, 0x00, 0xF2, 0x00, 0xF1, 0x00, 0xF1,
      0x00, 0xF0, 0x00, 0xF0, 0x00, 0xF0, 0x01, 0xF0, 0x02, 0xF0, 0x02, 0xF0, 0x03, 0xF0, 0x04, 0xF0, 0x04, 0xF0, 0x05, 0xF0, 0x06, 0xF0, 0x07, 0xF0,
      0x08, 0xF0, 0x09, 0xF0, 0x0A, 0xF0, 0x0A, 0xF0, 0x0B, 0xF0, 0x0C, 0xF0, 0x0D, 0xF0, 0x0D, 0xF0, 0x0E, 0xF0, 0x0E, 0xF0, 0x0F, 0xF0, 0x0F, 0xF0,
      0x0F, 0xE0, 0x0F, 0xE0, 0x0F, 0xD0, 0x0F, 0xC0, 0x0F, 0xC0, 0x0F, 0xB0, 0x0F, 0xA0, 0x0F, 0x90, 0x0F, 0x80, 0x0F, 0x70, 0x0F, 0x60, 0x0F, 0x50,
      0x0F, 0x50, 0x0F, 0x40, 0x0F, 0x30, 0x0F, 0x20, 0x0F, 0x20, 0x0F, 0x10, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x01,
      0x0F, 0x02, 0x0F, 0x02, 0x0F, 0x03, 0x0F, 0x04, 0x0F, 0x05, 0x0F, 0x06, 0x0F, 0x07, 0x0F, 0x08, 0x0F, 0x09, 0x0F, 0x0A, 0x0F, 0x0B, 0x0F, 0x0C,
      0x0F, 0x0C, 0x0F, 0x0D, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0D, 0x0F, 0x0D, 0x0F, 0x0C, 0x0F, 0x0B, 0x0F,
      0x0A, 0x0F, 0x0A, 0x0F, 0x09, 0x0F, 0x08, 0x0F, 0x07, 0x0F, 0x06, 0x0F, 0x06, 0x0F, 0x05, 0x0F, 0x04, 0x0F, 0x03, 0x0F, 0x03, 0x0F, 0x02, 0x0F,
      0x01, 0x0F, 0x01, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x1F, 0x00, 0x1F, 0x00, 0x2F, 0x00, 0x3F, 0x00, 0x4F, 0x00, 0x4F, 0x00, 0x5F,
      0x00, 0x6F, 0x00, 0x7F, 0x00, 0x8F, 0x00, 0x9F, 0x00, 0xAF, 0x00, 0xBF, 0x00, 0xBF, 0x00, 0xCF, 0x00, 0xDF, 0x00, 0xEF, 0x00, 0xEF, 0x00, 0xFF,
      0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFE, 0x00, 0xFE, 0x00, 0xFD, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0xFB, 0x00, 0xFA, 0x00, 0xF9, 0x00, 0xF8, 0x00, 0xF8,
      0x00, 0xF7, 0x00, 0xF6, 0x00, 0xF5, 0x00, 0xF5, 0x00, 0xF4, 0x00, 0xF3, 0x00, 0xF2, 0x00, 0xF2, 0x00, 0xF1, 0x00, 0xF1, 0x00, 0xF0, 0x00, 0xF0,
      0x01, 0xF0, 0x01, 0xF0, 0x02, 0xF0, 0x02, 0xF0, 0x03, 0xF0, 0x04, 0xF0, 0x04, 0xF0, 0x05, 0xF0, 0x06, 0xF0, 0x07, 0xF0, 0x08, 0xF0, 0x09, 0xF0,
      0x09, 0xF0, 0x0A, 0xF0, 0x0B, 0xF0, 0x0C, 0xF0, 0x0D, 0xF0, 0x0D, 0xF0, 0x0E, 0xF0, 0x0E, 0xF0, 0x0F, 0xF0, 0x0F, 0xF0, 0x0F, 0xE0, 0x0F, 0xE0,
      0x0F, 0xD0, 0x0F, 0xC0, 0x0F, 0xC0, 0x0F, 0xB0, 0x0F, 0xA0, 0x0F, 0x90, 0x0F, 0x80, 0x0F, 0x70, 0x0F, 0x60, 0x0F, 0x60, 0x0F, 0x50, 0x0F, 0x40,
      0x0F, 0x30, 0x0F, 0x20, 0x0F, 0x20, 0x0F, 0x10, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x01, 0x0F, 0x02, 0x0F, 0x02,
      0x0F, 0x03, 0x0F, 0x04, 0x0F, 0x05, 0x0F, 0x06, 0x0F, 0x07, 0x0F, 0x08, 0x0F, 0x09, 0x0F, 0x0A, 0x0F, 0x0B, 0x0F, 0x0C, 0x0F, 0x0C, 0x0F, 0x0D,
      0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0F, 0x0F, 0x0F, 0x0E, 0x0F, 0x0E, 0x0F, 0x0D, 0x0F, 0x0D, 0x0F, 0x0C, 0x0F, 0x0B, 0x0F, 0x0A, 0x0F, 0x0A, 0x0F,
      0x09, 0x0F, 0x08, 0x0F, 0x07, 0x0F, 0x06, 0x0F, 0x06, 0x0F, 0x05, 0x0F, 0x04, 0x0F, 0x03, 0x0F, 0x03, 0x0F, 0x02, 0x0F, 0x01, 0x0F, 0x01, 0x0F,
      0x00, 0x0F, 0x00, 0x0F, 0x00, 0x0F, 0x00, 0x1F, 0x00, 0x1F, 0x00, 0x2F, 0x00, 0x3F, 0x00, 0x4F, 0x00, 0x4F, 0x00, 0x5F, 0x00, 0x6F, 0x00, 0x7F,
      0x00, 0x8F, 0x00, 0x9F, 0x00, 0xAF, 0x00, 0xBF, 0x00, 0xBF, 0x00, 0xCF, 0x00, 0xDF, 0x00, 0xEF, 0x00, 0xEF, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0xFF,
      0x00, 0xFE, 0x00, 0xFE, 0x00, 0xFD, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0xFB, 0x00, 0xFA, 0x00, 0xF9, 0x00, 0xF9, 0x00, 0xF8, 0x00, 0xF7, 0x00, 0xF6,
      0x00, 0xF5, 0x00, 0xF5, 0x00, 0xF4, 0x00, 0xF3, 0x00, 0xF2, 0x00, 0xF2, 0x00, 0xF1, 0x00, 0xF1, 0x00, 0xF0, 0x00, 0xF0, 0x01, 0xF0, 0x01, 0xF0,
      0x02, 0xF0, 0x02, 0xF0, 0x03, 0xF0, 0x04, 0xF0, 0x04, 0xF0, 0x05, 0xF0, 0x06, 0xF0, 0x07, 0xF0, 0x08, 0xF0, 0x09, 0xF0, 0x09, 0xF0, 0x0A, 0xF0,
      0x0B, 0xF0, 0x0C, 0xF0, 0x0D, 0xF0, 0x0D, 0xF0, 0x0E, 0xF0, 0x0E, 0xF0, 0x0F, 0xF0, 0x0F, 0xF0, 0x0F, 0xE0, 0x0F, 0xE0, 0x0F, 0xD0, 0x0F, 0xC0,
      0x0F, 0xC0, 0x0F, 0xB0, 0x0F, 0xA0, 0x0F, 0x90, 0x0F, 0x80, 0x0F, 0x70, 0x0F, 0x60, 0x0F, 0x60, 0x0F, 0x50, 0x0F, 0x40, 0x0F, 0x30, 0x0F, 0x20,
      0x0F, 0x20, 0x0F, 0x10, 0x0F, 0x00, 0x0F, 0x00
   };



And finally a slice from the main program:
Code:
   color = 0b0000111100000000; // Displays Red
   setWin(20,60,40,80);
   fillWin(400, color);
   
   color = 0b0000000011110000; // Displays Blue
   setWin(40,60,60,80);
   fillWin(400, color);

   color = 0b0000000000001111; // Displays Green
   setWin(60,60,80,80);
   fillWin(400, color);

   
   
   setWin(0,0,129,129);
   LCD_command(RAMWRP);

   for(x = 1040; x > 0; x--){
      if(x%2 == 0){
         LCD_data(bitmap[x]);
      }else{
         LCD_data(bitmap[x]);
      }
   }

   for(x = 1040; x > 0; x--){
      if(x%2 == 0){
         LCD_data(reverse(bitmap[x]));
      }else{
         LCD_data(bitmap[x]);
      }
   }
   for(x = 1040; x > 0; x--){
      if(x%2 == 0){
         LCD_data(bitmap[x]);
      }else{
         LCD_data(reverse(bitmap[x]));
      }
   }
   for(x = 1040; x > 0; x--){
      if(x%2 == 0){
         LCD_data(reverse(bitmap[x]));
      }else{
         LCD_data(reverse(bitmap[x]));
      }
   }
   
   
   
   for(x = 0; x < 1040; x++){
      if(x%2 == 0){
         LCD_data(bitmap[x]);
      }else{
         LCD_data(bitmap[x]);
      }
   }
   for(x = 0; x < 1040; x++){
      if(x%2 == 0){
         LCD_data(reverse(bitmap[x]));
      }else{
         LCD_data(bitmap[x]);
      }
   }
   for(x = 0; x < 1040; x++){
      if(x%2 == 0){
         LCD_data(bitmap[x]);
      }else{
         LCD_data(reverse(bitmap[x]));
      }
   }
   for(x = 0; x < 1040; x++){
      if(x%2 == 0){
         LCD_data(reverse(bitmap[x]));
      }else{
         LCD_data(reverse(bitmap[x]));
      }
   }



Also as a side note, the really annoying high pitched whine from the SparkFun breakout board is normal, right?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 08, 2008 20:28 
Offline

Joined: Mon Sep 08, 2008 20:14
Posts: 2
Hi
I have been having trouble powering up my LCD, I'm unsure which controler is inside and as such have taken two programs that should work and modified/hacked them up to output over the parallel port on my computer.
(I do plan on writing my own code after I have established which controller it uses :) )

This has proven unsucessfull and I am unsure what to do next, I have tested the circuit I built and everything seems to be working correctly.
Can anyone here have a look over the code or advise on how to get it turning on over parallel?
Here is the Epson version: http://pastebin.com/m7017f694

And here is the Philips version: http://pastebin.com/m47cc8164

Thankyou very much in advance.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Sep 19, 2008 20:02 
Offline

Joined: Sat Aug 09, 2008 21:11
Posts: 8
Just a quick update on my progress with a Microchip 16f628 PIC
I'm using MPLAB asm code for a Phillips controller.

My 9 bit SPI code must be working as I can actually set the contrast of the screen,
it turns blue when powered up,
then turns a shade of white,
depending on the value I send it.

If anyone wants my code, let me know.

Sod all else works yet though :roll:


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 22, 2008 21:38 
Offline

Joined: Sat Aug 09, 2008 21:11
Posts: 8
:D

DISPON and DISPOFF also work


Last edited by taximania on Fri Sep 26, 2008 19:30, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Thu Sep 25, 2008 3:50 
Offline

Joined: Thu Sep 25, 2008 3:44
Posts: 1
hi

I have this display:

Front:
ImageImage

back:
ImageImage

Marks on the front: Victory WDL 08 2 3
Marks on the back: 6P030809BD 3768970056

And has a small red circle around the "BD" part. Front has a yellow tab.

Can you identify it by the markings (or anyone have anyhting similar)?

Thanks
smnt


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 29, 2008 19:08 
Offline

Joined: Mon Sep 22, 2008 19:14
Posts: 2
Hey,
I am interfacing nokia 6100 lcd with atmega 16
I did not keep 5 to 3.3 voltage dividers between the lcd and the controller (data,clk,CS,reset)
I have philips graphics controller in the LCD
Are there any chances of graphics controller getting damaged ??


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 288 posts ]  Go to page Previous  1 ... 14, 15, 16, 17, 18, 19, 20  Next

All times are UTC + 2 hours


Who is online

Users browsing this forum: No registered users and 23 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