Intellisence/Autocompletion on mbed platform

Hello everyone,

My problem is that while I’m using mbed plarform, autocompletion does not work as expected.I have searched everything about the intellisence (engines, fallbacks etc.) and still I run into many problems. For example, I call DigitalOut digitalout(...) and inside digitalout I never get to know with what should I complete it. And of course this happens also with dot(.) and arrow(->) operator, I never get to know what methods a class contains etc etc.

My intellisence configuration is:

C_Cpp.intelliSenseEngine: Default
C_Cpp.intelliSenseEngineFallback: Enabled

Also does anyone know why mbed.h is not included in the include path?

Thank you in advance!

Try to use default values by CPP extension. I’ve just tried mbed project and it works well. Please sure that you use the latest VSCode, PIO Core 3.5.0rc6 and restart VSCode.

These are the default values of cpp extension, I have not change any setting in any extension. I also have the lastest vs code and pio core. I will try to reinstall and I will update.

Did you press Ctrl+Space to show completion?

Yes, but either it shows all of the available functions etc, or nothing.

So, although I have cleaned VScode and reinstalled platformio, nothing changed.

To help furthermore, I will attach some screenshots:

The only way I can get some suggestions is with the double colon operator(::). See below:

Now I understand your problem. Do you use the latest VSCode and our extension? Also, what is your PIO Core version?
Please open PIO IDE Terminal and type pio --version. It seems that index was not built correctly. You should see :fire: icon in the right bottom corner.

I have the latest VSCode (downloaded yesterday) and PIOCore (from pio --version: PlatformIO, version 3.50rc7).
The index is rebuilded as it should every time I open VSCode, showing the icon in the right bottom corner.
One simple but not complete solution I found was that I tuned "C_Cpp.intelliSenseEngineFallback": from "Enabled" to "Disabled". With this I managed to get these results:

However, this effect is not applied everywhere as it should:

As you can see it does not show the constructors arguments even when I press Ctrl+Space.

Do you have any other idea what this could be?

It works for me when I open ( and does not work with Ctrl+Space. I do not know, maybe, that is by VSCode design.