esp-modbus icon indicating copy to clipboard operation
esp-modbus copied to clipboard

Unable to create project from examples in VSCode Extension (IDFGH-14767)

Open giacomo892 opened this issue 1 year ago • 2 comments

Checklist

  • [x] Checked the issue tracker for similar issues to ensure this is not a duplicate.
  • [x] Provided a clear description of your suggestion.
  • [x] Included any relevant context or examples.

Issue or Suggestion Description

Hello,

I'm trying to create a project from the examples in the VSCode extension and it fails

Image

Image

I give a valid folder but it is complaining about a missing folder.

Image

Thanks for giving a look.

giacomo892 avatar Mar 03 '25 13:03 giacomo892

Hello, @giacomo892,

Thank you for reporting this issue. Currently, the Espressif team responsible for the VS Code Extension is working on resolving the path-related problem with the button to create a project from an example.

In the meantime, you can use the following workaround: Download the specific example using the CLI with the following command:

idf.py create-project-from-example "espressif/esp-modbus=2.0.2:tcp/mb_tcp_slave"  

For more information, refer to the idf.py create-project-from-example.

After downloading the example: Modify the ../mb_tcp_slave/main/idf_component.yml file to include the mb_example_common dependency using the path:

${IDF_PATH}/examples/protocols/modbus/mb_example_common  

Once the dependency is added, you should be able to run idf.py build without any issues. For more details on building the project, refer to the idf.py build.

Let us know if you encounter any further issues!

Godoy-Octavio avatar Mar 05 '25 13:03 Godoy-Octavio

I'll add the vscode extension bugfix in https://github.com/espressif/vscode-esp-idf-extension/pull/1485 Please take a look if you can!

brianignacio5 avatar Mar 25 '25 08:03 brianignacio5

The PR with the fix was merged https://github.com/espressif/vscode-esp-idf-extension/pull/1485. This issue is being closed

otavotavo avatar Jun 06 '25 10:06 otavotavo