#Include issues with Workbench

I’m new to using Workbench. After opening Workbench today, I am suddenly getting these errors. In my .ino file i manually added #include statements because they were not loading in my .cpp file. I added #include <Adafruit_ADS1X15.h> and #include <Ubidots.h>. This was working but now I’m getting the following error: "Cannot open source file “Adafruit_ADS1X15.h” etc. Also, in my .cpp file, I’m getting this error: "Cannot open source file “Particle.h”. I’m not sure what I’m doing wrong. Any help is appreciated.

When was it working and in what project?

Merely adding an include statement does not import the library into your project.
To do that you'd use the Particle: Import Library task.

Could it be that you also have another package installed that may deal with .ino files? (e.g. Arduino for Visual Studio Code)
If so, it might be that this other package hogs your project.

Maybe you can post a screenshot of your entire VSCode Window (particularly the status bar and the project explorer.

Here is the Explorer. It shows that I did download the required libraries.

image

Here is the top of my .ino file where I manually added the Include statements and the squiggly errors:

image

And here is what It shows in the terminal:

Have you tried to build the project?

These squiggly lines are (often) misleading as the “Intellisense” core (configurationProvider) just doesn’t know how to look properly :wink:

This thread may help

I can’t do anything actually. I keep getting this error: Could not find task: Flash application & DeviceOS (local)…

That brings us back to my thought from earlier

No, I don’t have any other package installed.

I guess the issue is related to the compiler path. But what compiler was installed with Particle Workbench? When I try to specify the path, none are detected.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.