Author Topic: NHD-C24064WO-ATFH-3V3 will not work  (Read 953 times)

tbagner

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
    • View Profile
NHD-C24064WO-ATFH-3V3 will not work
« on: January 05, 2017, 01:53:25 PM »
Hallo

I have a NHD-C24064WO-ATFH-3V3 but it don't work. I have made a test PCB with the capacitor used in the data sheet. I like to control the display over SPI. I have already used a NHD-C12864A1Z-FS and this worked with my SPI communication.

Now the problem is, i can't see anything on the display but if i touch the connector (it is not a loose contact) on the right side (master side) my content appears and disappears a bit later. I have measured the LCD contrast voltage which is on the master side around 10 volt, but on the slave its only 2v. I have tested some things but it will not work. I have already tested with two displays and two PCBs this is why I don't think its a short circuit or a loos contact. What could be the problem?

Here is my code. I have testet many things this is why so many code is commented out
Code: [Select]
void C12864_UpdateFull(){
//Display Master
for (U8 j = 0; j < (C12864_DISPLAY_HW_NOF_ROWS / 8); j++) { //Page manuell increase
spi_sendByteDisp0(0xB0 + j);
spi_sendByteDisp0(0x10); // High bits Column
spi_sendByteDisp0(0x00); //Low Bits --> Adress 0
spi_sendByteDisp0(0xE0); //Read/Modify/Write
PORT_set_data_instructio();//Send Data
for (U8 i = 0; i < C12864_DISPLAY_HW_NOF_COLUMNS; i++) {
spi_sendByteDisp0(C12864_DisplayBuf[j][i]); //Colum Auto increase
}
PORT_clear_data_instructio();//Send Controll bytes
spi_sendByteDisp0(0xEE); //END Write

}
//Display Slave
for (U8 j = 0; j < (C12864_DISPLAY_HW_NOF_ROWS / 8); j++) { //Page manuell increase
spi_sendByteDisp1(0xB0 + j);
spi_sendByteDisp1(0x10); // High bits Column
spi_sendByteDisp1(0x00); //Low Bits --> Adress 0
spi_sendByteDisp1(0xE0); //Read/Modify/Write
PORT_set_data_instructio();//Send Data
//for(nichts = 0;nichts<0x2fff;nichts++); //Wait
for (U8 i = 0; i < C12864_DISPLAY_HW_NOF_COLUMNS; i++) {
spi_sendByteDisp1(C12864_DisplayBuf[j][i]); //Colum Auto increase
}
PORT_clear_data_instructio();//Send Controll bytes
}

}
void C12864_init() {
init_spi_master();
volatile U16 nichts = 0;
for(nichts = 0;nichts<0xffff;nichts++); //Wait
PORT_clear_data_instructio();

//Display Master

//spi_sendByteDisp0(0xA0); //Datenblatt
//spi_sendByteDisp0(0xAE); //Display OFF
spi_sendByteDisp0(0xA2); //Bias 1/9
spi_sendByteDisp0(0xA0);
spi_sendByteDisp0(0xC8); //
spi_sendByteDisp0(0xA4); //
spi_sendByteDisp0(0x40); //
spi_sendByteDisp0(0x25); //
spi_sendByteDisp0(0x81); //
spi_sendByteDisp0(0x10); //
spi_sendByteDisp0(0x2F); //Datenblatt

//spi_sendByteDisp0(0x11); //Set the most significant 4 bits of the display Ram colum address

spi_sendByteDisp0(0xAF); //Datenblatt Disp on


//spi_sendByteDisp0(0xE3); //NOP (sicher nicht in Test?!?)
//spi_sendByteDisp0(0x40); //Display Start Adress 0

//spi_sendByteDisp0(0xA5); //All on

//Display Slave
//spi_sendByteDisp1(0xA0); //Datenblatt
//spi_sendByteDisp1(0xAE); //Display OFF
spi_sendByteDisp1(0xA2); //Bias 1/9
spi_sendByteDisp1(0xA0);
spi_sendByteDisp1(0xC8); //
spi_sendByteDisp1(0xA4); //
spi_sendByteDisp1(0x40); //
spi_sendByteDisp1(0x25); //
spi_sendByteDisp1(0x81); //
spi_sendByteDisp1(0x10); //
spi_sendByteDisp1(0x2F); //Datenblatt

//spi_sendByteDisp1(0x11); //Set the most significant 4 bits of the display Ram colum address

spi_sendByteDisp1(0xAF); //Datenblatt Disp on


//spi_sendByteDisp1(0xE3); //NOP (sicher nicht in Test?!?)
//spi_sendByteDisp1(0x40); //Display Start Adress 0

//spi_sendByteDisp1(0xA5); //All on

}

and my SPI methods (Atmel AVR)

Code: [Select]
void spi_sendByteDisp0(U8 send)
{
volatile U16 nichts = 0;
for(nichts = 0;nichts<0xffff;nichts++); //Wait
volatile U32 gaga = (SPI_CSR_DISP0_NR<<16) | send;
SPI_Port.tdr =  gaga;//SET CS and Data in tdr
while (!SPI_Port.SR.txempty);//wait until Data buffer is empty
for(nichts = 0;nichts<0xffff;nichts++); //Wait

}

void spi_sendByteDisp1(U8 send)
{
volatile U16 nichts = 0;
for(nichts = 0;nichts<0xffff;nichts++); //Wait
SPI_Port.tdr = (SPI_CSR_DISP1_NR<<16)  | send; //SET CS and Data in tdr
while (!SPI_Port.SR.txempty);//wait until Data buffer is empty
for(nichts = 0;nichts<0xffff;nichts++); //Wait
}

tbagner

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
    • View Profile
Re: NHD-C24064WO-ATFH-3V3 will not work
« Reply #1 on: January 17, 2017, 10:43:12 AM »
I have found my problem on a other Forum http://www.microchip.com/forums/m440252.aspx.

I have try this solution, but I do not understand where do I have to insert a Potentiometer...

But I found out that my Display works when I pull VR to High. If I do this, the display show my content and then went black.

You can see on the fotos how the display looks.

What can I do?

tbagner

  • Newbie
  • *
  • Posts: 3
  • Karma: 0
    • View Profile
Re: NHD-C24064WO-ATFH-3V3 will not work
« Reply #2 on: January 20, 2017, 06:51:11 PM »
Okey the problem is now Solved.

The Display have to be connected like on the schematic.

 

Contrast supply for NHD‐24064WG‐ATFH‐VZ#

Started by Shaun_CarawayBoard Graphic LCDs

Replies: 2
Views: 3701
Last post May 19, 2014, 10:01:31 AM
by Shaun_Caraway
NHD-5.0-800480TF-ATXL#-CTP why don't typical timing values work?

Started by jkelleherBoard TFTs

Replies: 2
Views: 2578
Last post August 31, 2015, 05:08:45 AM
by jmag999
OLED Character display - Some commands don't work

Started by wedgeBoard Character LCDs

Replies: 1
Views: 2987
Last post July 08, 2014, 09:29:43 AM
by Michael_L
Help Getting ArduinoPro Mini 3.3V and NHD-C12864A1Z-FSW-FBW-HTT to work via SPI

Started by dalemooreBoard Graphic LCDs

Replies: 5
Views: 1269
Last post September 23, 2016, 07:44:35 AM
by Paul_B
How work with NHD-0216AW-SB3

Started by RacursBoard OLEDs

Replies: 1
Views: 560
Last post May 17, 2017, 04:30:14 PM
by Saurabh_B