when I compile a sketch that includes the mcufriend 2.9.9 library. beta (the one installed by the platform) gives me the following error and many others before I can’t see on the terminal (I can’t get back to the beginning)
the board is NUCLEO-64 STM32f103RB and the sketch is the example graphictest from mcufriend
I’m still having this problem in 2023 with mcufriend version 3.0.0.
All it takes is importing the library:
#include <MCUFRIEND_kbv.h>
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
Gives the following errors (and many more):
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:877:13: note: suggested alternative: 'write24'
write8(cmd);
^~~~~~
write24
In file included from C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:38:0:
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\utility/mcufriend_shield.h:1213:20: error: 'PIN_HIGH' was not declared in this scope
#define CD_DATA PIN_HIGH(CD_PORT, CD_PIN)
^
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:880:17: note: in expansion of macro 'CD_DATA'
CD_DATA;
^~~~~~~
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\utility/mcufriend_shield.h:1213:20: note: suggested alternative: 'PIN_MISO'
#define CD_DATA PIN_HIGH(CD_PORT, CD_PIN)
^
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:880:17: note: in expansion of macro 'CD_DATA'
CD_DATA;
^~~~~~~
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\utility/mcufriend_shield.h:1216:20: error: 'PIN_HIGH' was not declared in this scope
#define CS_IDLE PIN_HIGH(CS_PORT, CS_PIN)
^
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:888:13: note: in expansion of macro 'CS_IDLE'
CS_IDLE;
^~~~~~~
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\utility/mcufriend_shield.h:1216:20: note: suggested alternative: 'PIN_MISO'
#define CS_IDLE PIN_HIGH(CS_PORT, CS_PIN)
^
C:\Users\Stuart Hull\Documents\Arduino\libraries\MCUFRIEND_kbv\MCUFRIEND_kbv.cpp:888:13: note: in expansion of macro 'CS_IDLE'
CS_IDLE;
^~~~~~~
exit status 1
Compilation error: exit status 1
Did anyone find the solution to this?
And your platformio.ini
is what?