OLED Display Noise problem


Closed Thread
Results 1 to 25 of 25

Hybrid View

  1. #1
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103

    Default OLED Display Noise problem

    Hello everyone ;

    I've been working on a project which requires an LCD display then I decided to get an oled in order to free some pins also to ease the PCB design
    and I purchased an OLED code named EA W162-XBLW (ICEWHITE) of Electronic Assembly but I have a disturbing problem with the LCD .. After I power the circuit up I can perfectly display all the characters on whereever I want on the lcd but there is an incredible noise moving all around the LCD in a form of a pixel , So far I have tried using capacitors even those larger ones and even added the define LCD command and data line parameters with several tries ,, but no lock so far .. Here I share the code and a picture ... I hope any of you had such a weird problem in the past and solved it ...


    The code is for 16F1827
    Code:
    #config
     __CONFIG _CONFIG1, _FOSC_INTOSC & _WDTE_OFF & _PWRTE_ON & _MCLRE_OFF & _CP_OFF & _CPD_OFF & _BOREN_OFF & _CLKOUTEN_OFF & _IESO_OFF & _FCMEN_OFF 
     __CONFIG _CONFIG2, _WRT_OFF & _PLLEN_OFF & _STVREN_OFF & _BORV_19 & _LVP_OFF
    #ENDCONFIG
    
    
    '-------------------------------------------------------------------------------
    define OSC 4
    OSCCON=%01101010    'OSC is @ 4 MHZ
    
    
    '------------- LCD DEFINES ------------------------
    DEFINE LCD_DREG PORTB 'LCD data port 
    DEFINE LCD_DBIT 4 'LCD data starting bit 0 or 4 
    
    
    DEFINE LCD_RSREG PORTA 'LCD register select port 
    DEFINE LCD_RSBIT 7 'LCD register select bit
    
    
    DEFINE LCD_RWREG PORTA   ' LCD read/write port
    DEFINE LCD_RWBIT 0   ' LCD read/write pin bit  
    
    
    DEFINE LCD_EREG PORTA 'LCD enable port 
    DEFINE LCD_EBIT 6 'LCD enable bit
    
    
    DEFINE LCD_BITS 4 'LCD bus size 4 or 8 
    DEFINE LCD_LINES 2 'Number lines on LCD
    
    
    '------------- LCD DEFINES -------------------------
    
    
    
    
    '-------------------------------------------------------------------------------
    PORTA=%00000000     :      PORTB=%00000000
    TRISA=%00000000     :      TRISB=%00000000 
    'ADCON0=%00000001    :      ADCON1=%10110000
    ANSELA=%00000       :      ANSELB=%00000000
    'OPTION_REG.7=0     
    '-------------------------------------------------------------------------------
                                       
    
    
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
     
    MAIN:
                  
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    
    
    goto main
    Name:  20160528_205817.jpg
Views: 2265
Size:  527.9 KB
    - Ipsa scientia potestas est -

  2. #2
    Join Date
    Nov 2007
    Location
    West Covina, CA
    Posts
    219


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Hi,

    I would suggest writing to the LCD only when you need to update the display info.
    Constantly writing to it in a loop without any kind of delay may be causing the problem.

    Code:
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    
    
    Main:
     Do stuff
     IF something_new THEN Update_LCD
    
    GOTO Main
    
    
    Update_LCD:
    
     lcdout $FE,$80,"BU BiR DENEMEDiR"
     LCDOUT $FE,$C0,"  New data  "
    
    GOTO Main
    Louie

  3. #3
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Quote Originally Posted by LinkMTech View Post
    Hi,

    I would suggest writing to the LCD only when you need to update the display info.
    Constantly writing to it in a loop without any kind of delay may be causing the problem.

    Code:
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    
    
    Main:
     Do stuff
     IF something_new THEN Update_LCD
    
    GOTO Main
    
    
    Update_LCD:
    
     lcdout $FE,$80,"BU BiR DENEMEDiR"
     LCDOUT $FE,$C0,"  New data  "
    
    GOTO Main
    Thanks for your response .But what if I need to display some sort of ADC reading which requires an instant update on the lcd continuously ?? You know how fast those readings may change ...
    - Ipsa scientia potestas est -

  4. #4
    Join Date
    Nov 2007
    Location
    West Covina, CA
    Posts
    219


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    You can only "see" so fast before it becomes a blur.
    Try adding a PAUSE 33 in your main loop as it is, making it 30fps, just to test if the ghost dots go away.
    Louie

  5. #5
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Quote Originally Posted by LinkMTech View Post
    You can only "see" so fast before it becomes a blur.
    Try adding a PAUSE 33 in your main loop as it is, making it 30fps, just to test if the ghost dots go away.
    Tried but still no luck
    - Ipsa scientia potestas est -

  6. #6
    Join Date
    Nov 2005
    Location
    Bombay, India
    Posts
    947


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Have you got your decoupling capacitors on board?

  7. #7
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    I tried adding pause 100 command right after the lcdout commands but the noise only got lowered just a little .. This is definitely not normal .. But when I apply 1000 ms of delay it almost stops making noise on the screen(there is still a little) ... But It musn't be that bad .. It is an oled and the datasheet claims parameters for write/read around nanosecs .. Where do I do the mistake ? , May it have anything to do with the LCD or a defective circuit component ... On the other hand I think It musn't have because It can display chars succesfully with a huge amount of delay periods ...
    - Ipsa scientia potestas est -

  8. #8
    Join Date
    Sep 2009
    Posts
    737


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    That sound to me as bad PCB design and/or power supply. But sill could be bad LCD driver.
    If long delays make artifact disappear, then capacitive coupling between LCD signals and power lines can cause that.
    You can try test that. Add pull down resistor 1K to LCD Enable pin, and create easy way to disconnect LCD and resistor from PIC, as close as possible to LCD.
    Code:
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
    
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    PAUSE 10000' Disconnect only LCD enable pin before pause timeout
    Main:
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    GOTO Main
    Display shouldn't update any more. If you see dots then 99% problem is with PCB layout, and decoupling.
    If there is no dots on LCD then problem is with LCD.

  9. #9
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Quote Originally Posted by pedja089 View Post
    That sound to me as bad PCB design and/or power supply. But sill could be bad LCD driver.
    If long delays make artifact disappear, then capacitive coupling between LCD signals and power lines can cause that.
    You can try test that. Add pull down resistor 1K to LCD Enable pin, and create easy way to disconnect LCD and resistor from PIC, as close as possible to LCD.
    Code:
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
    
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    PAUSE 10000' Disconnect only LCD enable pin before pause timeout
    Main:
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    GOTO Main
    Display shouldn't update any more. If you see dots then 99% problem is with PCB layout, and decoupling.
    If there is no dots on LCD then problem is with LCD.
    Well ;

    I did exactly as you asked me to do and as you say it's got to do with the lcd then ...
    - Ipsa scientia potestas est -

  10. #10
    Join Date
    Oct 2009
    Posts
    583


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Quote Originally Posted by gunayburak View Post
    Well ;

    I did exactly as you asked me to do and as you say it's got to do with the lcd then ...
    I don't have the same chip, but used an 18F4580 with a 2 x 16 LCD and just changed the lines to run the LCD from port B to suit the EasyPIC5 development board and I don't get any strange random pixels and I'm running the chip at 20Mhz so the switching is much faster, so it would suggest that it is your hardware that is at fault.

    Code:
    ASM 
      __CONFIG    _CONFIG1H, _OSC_HS_1H
      __CONFIG    _CONFIG2L, _PWRT_ON_2L  
      __CONFIG    _CONFIG2H, _WDT_ON_2H & _WDTPS_512_2H
      __CONFIG    _CONFIG3H, _MCLRE_ON_3H & _LPT1OSC_OFF_3H & _PBADEN_OFF_3H  
      __CONFIG    _CONFIG4L, _LVP_OFF_4L & _XINST_OFF_4L
    ENDASM
    
    
    DEFINE  OSC 20    
    
    DEFINE LCD_DREG  PORTB                  ' LCD Data port
    DEFINE LCD_DBIT  0                      ' starting Data bit (0 or 4)
    DEFINE LCD_EREG  PORTB                  ' LCD Enable port
    DEFINE LCD_EBIT  5                      '     Enable bit  (on EasyPIC 5 LCD)
    DEFINE LCD_RSREG PORTB                  ' LCD Register Select port
    DEFINE LCD_RSBIT 4                      '     Register Select bit   (on EasyPIC 5 LCD)
    DEFINE LCD_BITS  4                      ' LCD bus size (4 or 8 bits)
    DEFINE LCD_LINES 4                      ' number of lines on LCD
    DEFINE LCD_COMMANDUS 2000               ' Command delay time in us 
    DEFINE LCD_DATAUS 50                    ' Data delay time in us 
    
    '-------------------------------------------------------------------------------
    PORTA=%00000000     :      PORTB=%00000000
    TRISA=%00000000     :      TRISB=%00000000 
    'ADCON0=%00000001    :      ADCON1=%10110000
    'ANSELA=%00000       :      ANSELB=%00000000
    'OPTION_REG.7=0     
    '-------------------------------------------------------------------------------                                 
    
    
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
     
    MAIN:
                  
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    
    goto main

    Replaced the 20Mhz with a 4Mhz xtal and recoded and the display was fine.

  11. #11
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Quote Originally Posted by Scampy View Post
    I don't have the same chip, but used an 18F4580 with a 2 x 16 LCD and just changed the lines to run the LCD from port B to suit the EasyPIC5 development board and I don't get any strange random pixels and I'm running the chip at 20Mhz so the switching is much faster, so it would suggest that it is your hardware that is at fault.

    Code:
    ASM 
      __CONFIG    _CONFIG1H, _OSC_HS_1H
      __CONFIG    _CONFIG2L, _PWRT_ON_2L  
      __CONFIG    _CONFIG2H, _WDT_ON_2H & _WDTPS_512_2H
      __CONFIG    _CONFIG3H, _MCLRE_ON_3H & _LPT1OSC_OFF_3H & _PBADEN_OFF_3H  
      __CONFIG    _CONFIG4L, _LVP_OFF_4L & _XINST_OFF_4L
    ENDASM
    
    
    DEFINE  OSC 20    
    
    DEFINE LCD_DREG  PORTB                  ' LCD Data port
    DEFINE LCD_DBIT  0                      ' starting Data bit (0 or 4)
    DEFINE LCD_EREG  PORTB                  ' LCD Enable port
    DEFINE LCD_EBIT  5                      '     Enable bit  (on EasyPIC 5 LCD)
    DEFINE LCD_RSREG PORTB                  ' LCD Register Select port
    DEFINE LCD_RSBIT 4                      '     Register Select bit   (on EasyPIC 5 LCD)
    DEFINE LCD_BITS  4                      ' LCD bus size (4 or 8 bits)
    DEFINE LCD_LINES 4                      ' number of lines on LCD
    DEFINE LCD_COMMANDUS 2000               ' Command delay time in us 
    DEFINE LCD_DATAUS 50                    ' Data delay time in us 
    
    '-------------------------------------------------------------------------------
    PORTA=000000     :      PORTB=000000
    TRISA=000000     :      TRISB=000000 
    'ADCON0=000001    :      ADCON1=110000
    'ANSELA=000       :      ANSELB=000000
    'OPTION_REG.7=0     
    '-------------------------------------------------------------------------------                                 
    
    
    pause 500
                            
    lcdout $FE,$28
    lcdout $FE,$17
    lcdout $FE,$06
    lcdout $FE,$08
    lcdout $FE,$01
    lcdout $FE,$02
    lcdout $FE,$0C
     
    MAIN:
                  
    lcdout $FE,$80,"BU BiR DENEMEDiR"
    LCDOUT $FE,$C0,"  iKiNCi SATIR  "
    
    goto main

    Replaced the 20Mhz with a 4Mhz xtal and recoded and the display was fine.
    What can I say .. I am so unlucky with these OLEDs .. But thanks for your effort anyway ..
    - Ipsa scientia potestas est -

  12. #12
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    So any clue how to turn off this moving cursor .. Besides these moving cursor must be moving only at the first line of each character yet I see this noise on all over the screen ..
    - Ipsa scientia potestas est -

  13. #13
    Join Date
    Jun 2016
    Location
    Melbourne, Australia
    Posts
    29


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    I recall most LCD's have a "cursor off" command? (i believe the OLED replacements for LCD's should also have cursor-off too).

    Turn the cursor off at the beginning of your code, just after the LCD initialises. If you ever need to see the cursor as a prompt, then re-enable the cursor during that part of the code only.

    hope this might help?

  14. #14
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    Do you have a data sheet available to view?
    Dave Purola,
    N8NTA
    EN82fn

  15. #15
    Join Date
    Dec 2012
    Location
    Türkiye
    Posts
    103


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    http://www.lcd-module.de/fileadmin/e...doma/olede.pdf

    Here it is .. The model code name is :
    • EA W162-XB

    - Ipsa scientia potestas est -

  16. #16
    Join Date
    Feb 2013
    Posts
    1,078


    Did you find this post helpful? Yes | No

    Default Re: OLED Display Noise problem

    I saw an article about these displays in Russian couple of months ago, that guy also had cursor issue and he dealt somehow with it. I will check my history later and let you know.

Similar Threads

  1. Winstar OLED Display Problem with lcdout comands
    By bubbleless in forum mel PIC BASIC Pro
    Replies: 32
    Last Post: - 31st December 2019, 05:53
  2. Help With OLED Display / 128X64 SSD1306
    By Denner in forum General
    Replies: 6
    Last Post: - 25th May 2013, 15:40
  3. Problem with GOSUB/GOTO and Newhaven OLED question
    By Christopher4187 in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 12th April 2013, 10:24
  4. Pretty Sure a Noise Problem
    By Tobias in forum General
    Replies: 3
    Last Post: - 10th December 2009, 00:46
  5. OLED 128x128 color display
    By Ron Marcus in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 21st May 2007, 01:45

Members who have read this thread : 1

You do not have permission to view the list of names.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts