Hello guys,
i´ve the following Problem. I ´ve imported a arduino project with libs that are written in arduino in cpp. All the the called functions in the ino are member function of class which is defined in the header. When I´m writing a member variable in the member function I get a undefined refrences error.
I´m using the C/C++ Intellisense extension in VS Code. I´ve installed the mingw64 compiler properly and it is in system path. But I still get these errors. Probably because platformio isnt recognizing the compiler.
Do you have any suggestion how to include the compiler in platformio? Is there any build tags I should use ?
Hard to say what is wrong. Either the file which implements myNFL is not being compiled in because ti’s in the wrong spot, or there’s a name-mangling error when interfacing C and C++ code. Can you show the project’s full code?
PlatformIO will always use its own compiler, for AVR that’s <home folder>/.platformio/packages/toolchain-atmelavr, it is never needed to set-up a compiler yourself.
Also be careful there, you cannot place that file directly in lib/. lib/ is supposed to have folders in it, each of which has the library files in it. Refer to the the README