12 Replies Latest reply on Jan 8, 2014 4:22 AM by DaKn_263916

    CY8CKIT-050 and Character LCD problem

    MarkH_61

      Some of you may have seen a problem with the character LCD on the CY8CKIT-050 development board when running a system clock of 24 MHz or faster.  We found a timing issue in version 1.8 of the character LCD component.  To avoid this problem I recommend that you revert to version 1.7 of the character LCD.  You most likely will not see this issue on the CY8CKIT-001 since it has a different interface to the LCD.  The CY8CKIT-001 board has a level translator between the PSoC 5LP and the LCD.  The CY8CKIT-050 has 10K resistors on the data lines between the LCD and PSoC 5LP, which make it more susceptible to timing issues.

         

      To revert to an older version of the LCD or any component, right-click on the project name in the Workspace Explorer and select "Update Components...".  Find the "CharLCD" component and select version "v1.7" form the Available Versions column.  Select the Update check box on the right, then select the "Next" button at the bottom of the dialog window.

         

      Mark

        • 1. Re: CY8CKIT-050 and Character LCD problem

          Does this problem only occur when the PSoC is powered with 5V, or does it happen with 3.3V also?

          • 2. Re: CY8CKIT-050 and Character LCD problem
            CrGa_284461

            Hi,

               

            I've an PSoC 4 with component Character LCD v1.90.

               

            I use an LCD device like Hitachi @ 5 V.

               

            I wrote this program to test the device:

               

            int main()
            {
                char init[32]="ABCdeFGHILMNOPQRSTUVWXYZ";
                LCD_WriteControl(LCD_CURSOR_BLINK);
                LCD_WriteControl( LCD_CURSOR_HOME);
                LCD_ClearDisplay();
                LCD_PrintString(init);
                LCD_WriteControl( LCD_CURSOR_HOME);
                CyDelay(1000u);
                LCD_Position(1,0);
                LCD_PrintString("abcdefghilmnopqrstuvwxyz");
                CyDelay(1000u);
                for(;;)
                {    
                
                    }
            }

               

             

               

            The output is:

               

            ABCdeFGHILMNO_ (blink Led)

               

            The Clocks Page is set like this:

               

            EXTCLK 24MHz

               

            LFCLK ?

               

            ILO 32MHZ

               

            SYSCLK ?

               

            IMO 24 MHz

               

            HFCLK 24 MHz

               

             

               

            Can you help me Please??

            • 3. Re: CY8CKIT-050 and Character LCD problem
              JoMe_264151

              This is probably an issue with the organization of the LCD. You did not tell how many lines and how many characters/line it has got.

                 

              At first:

                 

              Avoid writing more than 15 chars to one line.

                 

              Check if you can reach the second line by writing to a position different from 0 (I have seen those cases)

                 

              You will have to figure out the trick.

                 

               

                 

              Bob

              • 4. Re: CY8CKIT-050 and Character LCD problem

                A typical memory organization for a multi-line display is to have the second line start at offset 0x40 (sometimes its 0x20, but its rare). So when writing more than the number of characters in the first line the characters seem to disappear. If you would write more of them, they appear eventually in the second line.

                   

                Look at the data sheet of your display, it should tell you about this (because on low level, one need to set this memory address).

                • 5. Re: CY8CKIT-050 and Character LCD problem
                  CrGa_284461

                  Hi.

                     

                  The LCD has 2 lines, 16 ch. But

                     

                  0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
                  a b c d e f g h i l m  n  o 

                     

                  The problem is in the 1st line tipically when I wanna write the p character, or space, or "l".

                  • 6. Re: CY8CKIT-050 and Character LCD problem
                    CrGa_284461

                    Also, I can write the second line with no problem. The index of col. have no problem. But if I wirte "son Alberto di"

                       

                    in the second line I see  "son Alberto_"  and no other character

                    • 7. Re: CY8CKIT-050 and Character LCD problem

                      So you cannot write to the 12th column in your display? THis sounds like a problem of the display, not in PSoC. Can you try to reproduce that with another display? Or, for that matter, use the display with another MCU?

                         

                      (And does it happen when the LCD is not set to blinking cursor?)

                      • 8. Re: CY8CKIT-050 and Character LCD problem

                        Btw: you are writing about a PSoC4 problem in the PSoC5 forum - this might confuse users. Also, when you have a new problem please open a new thread, and don't hijack an existing one. Especially not when this one is about a different problem (you aren't using a PSoC5, are you?)

                           

                        Doing so increases your chances to get good answers (I actually wanted to recommend to you to use the LCD from the -050 kit, since this is the title of this thread...)

                        • 9. Re: CY8CKIT-050 and Character LCD problem
                          CrGa_284461

                          I'm sorry, I found this thread that may resolve my problem.

                             

                          It isn't a problem of 12th col.  because if I don't write 'o', for example i wrote this example.

                             

                          LCD_Start();
                              LCD_ClearDisplay();
                              LCD_WriteControl( LCD_CURSOR_BLINK);
                              char8 ch='a';
                              while(ch<='z'){
                                  if(ch=='o')
                                              ch++;
                                  if(ch>'a'+16){
                                          LCD_Position(1,i++);
                                         
                                  }
                                  LCD_PutChar(ch++);
                                  CyDelay(20u);
                            }
                              LCD_WriteControl(LCD_CURSOR_HOME);

                             

                           

                             

                          the cursor come to positio(0,0);

                             

                          but if I use this code:

                             

                          LCD_Start();
                              LCD_ClearDisplay();
                              LCD_WriteControl( LCD_CURSOR_BLINK);
                              char8 ch='a';
                              while(ch<='z'){
                                  if(ch=='o')
                                              ch++;
                                  if(ch>'a'+16){
                                          LCD_Position(1,i++);
                                         
                                  }
                                  LCD_PutChar(ch++);
                                  CyDelay(20u);
                            }   

                             

                          LCD_PutChar('o');
                              LCD_WriteControl(LCD_CURSOR_HOME);

                             

                          the cursor don't go @home and in debug mode the system wait forever.

                             

                          I attach the project.

                          • 10. Re: CY8CKIT-050 and Character LCD problem
                            CrGa_284461

                            Note. My LCD is 1602A by SHEZHEN EONE ELECTRONICs

                            • 11. Re: CY8CKIT-050 and Character LCD problem
                              CrGa_284461

                              I post my problem here!

                                 

                              thank you so much for all!

                                 

                               

                                 

                              http://www.cypress.com/?app=forum&id=4749&rID=90385

                              • 12. Re: CY8CKIT-050 and Character LCD problem
                                DaKn_263916

                                I posted one possible issue at

                                   

                                    

                                   

                                          http://www.cypress.com/?app=forum&id=4749&rID=90385

                                   

                                 

                                   

                                Regards, Dana.