Newhaven Products > OLEDs

NHD 2.7 Screen Image Streaking

(1/4) > >>

cherry8wild:
Hello,

I am currently working on a project using a Newhaven 2.7" OLED Graphic display. I have a problem with the screen Images turning out poorly. when some pixels in a column are on, the whole column glows (at different intensities based on the number of pixels that are on). In all of the photos, the screen is cleared, and written over as all pixels OFF, before any ON pixels are written.

Any thoughts?


Info:
Display - NHD‐2.7‐12864UCY3
Interface - SPI

Michael_L:
Is it probably something to do with your initialization.  Try using these values:


--- Code: ---comm_out(0xAE);
 
  comm_out(0xB3);
  comm_out(0x01);
  comm_out(0x90);
 
  comm_out(0xA8);
  comm_out(0x3F);
 
  comm_out(0xA2);
  comm_out(0x4C);
 
  comm_out(0xA1);
  comm_out(0x00);
 
  comm_out(0xAD);
  comm_out(0x00);
 
  comm_out(0xA0);
  comm_out(0x50);
 
  comm_out(0x84);
 
  comm_out(0xB8);
  comm_out(0x01);
  comm_out(0x11);
  comm_out(0x22);
  comm_out(0x32);
  comm_out(0x43);
  comm_out(0x54);
  comm_out(0x65);
  comm_out(0x76);
 
  comm_out(0x81);
  comm_out(0x7F);
 
  comm_out(0xB2);
  comm_out(0x51);
 
  comm_out(0xB1);
  comm_out(0x55);
 
  comm_out(0xBC);
  comm_out(0x10);
 
  comm_out(0xB4);
  comm_out(0x02);
  comm_out(0xB0);
  comm_out(0x28);
 
  comm_out(0xBE);
  comm_out(0x1C);
 
  comm_out(0xBF);
  comm_out(0x0C);
 
  comm_out(0xA4);
 
  comm_out(0xAF);
--- End code ---

cherry8wild:
Alright, Thanks. I'll try those values out.

cherry8wild:
OK,

The values I was using for the Initialization were slightly different, but the same streaking occurs with the new values as well. Here is the initialization function I am using, if there is still anything wrong.


--- Code: ---void OLED_12864_Init_test()
{
    TRIS_RS =   0;
    TRIS_SCLK = 0;
    TRIS_CS =   0;
    TRIS_SDIN = 0;

    SSPCON1bits.SSPEN = 0;
    SSPSTATbits.SMP = 1; // SPI Master Mode
    SSPSTATbits.CKE = 1;
    SSPCON1bits.SSPM3 = 0;
    SSPCON1bits.SSPM2 = 0;
    SSPCON1bits.SSPM1 = 0;
    SSPCON1bits.SSPM0 = 0;

    SSPCON1bits.SSPEN = 1;

    LAT_CS = 1;

    LAT_RS = 0;
    mDelay(40);
    LAT_RS = 1;

    SPI_Write1(0xAE); // Set display OFF

    SPI_Write1(0xB3); // Set Display Clock
    SPI_Write1(0x01);
    SPI_Write1(0x90);

    SPI_Write1(0xA8); // Set Multiplex Ratio
    SPI_Write1(0x3F);

    SPI_Write1(0xA2); // Set Display Offset
    SPI_Write1(0x4C);

    SPI_Write1(0xA1); // Start Line
    SPI_Write1(0x00);

    SPI_Write1(0xAD); // Set Master Configuration
    SPI_Write1(0x00);

    SPI_Write1(0xA0); // Set Remap Format
    SPI_Write1(0x50);

    SPI_Write1(0x84); // Set Current Range (1/4)

    SPI_Write1(0xB8); // Set Greyscale Table
    SPI_Write1(0x01);
    SPI_Write1(0x11);
    SPI_Write1(0x22);
    SPI_Write1(0x32);
    SPI_Write1(0x43);
    SPI_Write1(0x54);
    SPI_Write1(0x65);
    SPI_Write1(0x76);

    SPI_Write1(0x81); // Set Contranst Current
    SPI_Write1(0x7F);

    SPI_Write1(0xB2); // Set Row Period (Frame Frequency)
    SPI_Write1(0x51);

    SPI_Write1(0xB1); // Set Phase Length
    SPI_Write1(0x55);

    SPI_Write1(0xBC); // Set Precharge Voltage
    SPI_Write1(0x10);

    SPI_Write1(0xB4); // Set Precharge Compensation
    SPI_Write1(0x02);

    SPI_Write1(0xB0); // Set Precharge Enable
    SPI_Write1(0x28);

    SPI_Write1(0xBE); // Set V_com_H Voltage level
    SPI_Write1(0x1C);

    SPI_Write1(0xBF); // Set Segment Low voltage
    SPI_Write1(0x0C);

    SPI_Write1(0xA4); //Set Display Mode Normal

    SPI_Write1(0xAF); // Set Display On

--- End code ---
Also, the wiring diagram and the hardware setup. I have a very basic setup, pretty much taken straight from the NHD data sheet. Any suggestions appreciated! Screen is very clear and easy to read, but the streaking lines are not acceptable for my application.

Michael_L:
You are calling command 0xBE twice in your initialization.  The second one should be 0xBF.

Navigation

[0] Message Index

[#] Next page

Go to full version