Problems MikroC for 8051 with LCD lib, HELP ME!!

General discussion on mikroC PRO for 8051.
Post Reply
Author
Message
vibonesi
Posts: 3
Joined: 17 Sep 2015 13:47
Location: São Paulo, Brazil

Problems MikroC for 8051 with LCD lib, HELP ME!!

#1 Post by vibonesi » 14 Jun 2016 18:10

Can anybody help me?

I'm working on this code for an lcd display and when compiled presents the following errors:

  • "__Lib_System.mcl" "__Lib_Delays.mcl" "__Lib_LcdConsts.mcl" "__Lib_Lcd.mcl"
    0 122 Compilation Started lcd_8051.c
    45 123 Compiled Successfully lcd_8051.c
    0 127 All files Compiled in 78 ms
    22 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    33 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    37 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    39 438 Call signature does not match the function definition signature 'Delay_50us' __Lib_Lcd.c
    83 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    84 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    85 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    96 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    98 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    101 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    103 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    106 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    108 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    114 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    116 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    125 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    130 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    132 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    138 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    142 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    144 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    149 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    153 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    155 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    160 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    168 438 Call signature does not match the function definition signature 'Delay_1us' __Lib_Lcd.c
    171 438 Call signature does not match the function definition signature 'Delay_5500us' __Lib_Lcd.c
    0 102 Finished (with errors): 14 jun 2016, 13:44:03 lcd_8051.mcp51

This is the code:

Code: Select all

//configuracao dos ports

sbit LCD_RS at P2_2_bit;
sbit LCD_EN at P2_3_bit;

sbit LCD_D4 at P2_4_bit;
sbit LCD_D5 at P2_5_bit;
sbit LCD_D6 at P2_6_bit;
sbit LCD_D7 at P2_7_bit;

char txt1[] = "***************";
char txt2[] = "***************" ;
char txt3[] = "******************************";
char txt4[] = "******************************";
char txt5[] = "***************";

#define tempoI Delay_ms(100)
#define tempoII Delay_ms(5000)
#define tshift Delay_ms(800)

void main() {
     signed int cont = 0;
     Lcd_Init();
     Lcd_Cmd(_LCD_CLEAR);
     Lcd_Cmd(_LCD_CURSOR_OFF);
     Lcd_Cmd(_LCD_CURSOR_OFF);
     tempoI;

     while(1){
      Lcd_Out(1,1,txt1);
      Lcd_Out(2,1,txt2);
      tempoII;
      Lcd_Out(1,1,txt3);
      Lcd_Out(2,1,txt4);

        for(cont=0;cont<=16;cont++){
         Lcd_Cmd(_LCD_SHIFT_RIGHT);
         tshift;
        }
      Lcd_Out(1,1,txt1);
      Lcd_Out(2,1,txt5);
      tempoII;

     }
}
Thanks in advance!

User avatar
nadir.celebic
mikroElektronika team
Posts: 465
Joined: 15 Jun 2016 13:19

Re: Problems MikroC for 8051 with LCD lib, HELP ME!!

#2 Post by nadir.celebic » 15 Jun 2016 15:19

Hello,

You must turn on libraries which you use.
For start, you can use example project for LCD and then upgrade the code according to your needs.

Regards,

vibonesi
Posts: 3
Joined: 17 Sep 2015 13:47
Location: São Paulo, Brazil

Re: Problems MikroC for 8051 with LCD lib, HELP ME!!

#3 Post by vibonesi » 15 Jun 2016 16:27

nadir.celebic wrote:Hello,

You must turn on libraries which you use.
For start, you can use example project for LCD and then upgrade the code according to your needs.

Regards,
The LCD library is on, and I tested the demo code, I believe that this error is delay of the source file of the LCD library. :(

User avatar
nadir.celebic
mikroElektronika team
Posts: 465
Joined: 15 Jun 2016 13:19

Re: Problems MikroC for 8051 with LCD lib, HELP ME!!

#4 Post by nadir.celebic » 16 Jun 2016 15:28

Hi,

Please,can you ZIP your project and attach it here?

Regards,
Nadir

Post Reply

Return to “mikroC PRO for 8051 General”