Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I2C Print function error #3

Open
Foxtrot0311 opened this issue Sep 6, 2023 · 1 comment
Open

I2C Print function error #3

Foxtrot0311 opened this issue Sep 6, 2023 · 1 comment

Comments

@Foxtrot0311
Copy link

I am using your library on a LCD2004 with PCF8574 I2C connection and I am getting an error during compiling. It seems like its an error in the library and not my code but I am not sure. The processor is an Arduino Nano ESP32 board.

I am using your full demo script with no additional code as a function test and tried to compile it and it gives me the following error:

...Arduino\libraries\LiquidCrystal_NKC\src\LiquidCrystal_NKC.cpp:428:41: note: deduced conflicting types for parameter 'const _Tp' ('unsigned int' and 'int')
len = min(strlen(inputChar), MAX_STRLEN);
^

@animevietsub
Copy link

You need to edit the file LiquidCrystal_NKC.cpp in the library folder.
In line 416:
len = min(strlen(inputChar), MAX_STRLEN);
to
len = min((int)strlen(inputChar), MAX_STRLEN);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants