-
-
Notifications
You must be signed in to change notification settings - Fork 391
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: expose the Arduino state to VS Code extensions #2071
Conversation
Hi @dankeboy36 ! This looks like a great idea! My question is wether the extensions can have access to all board properties defined in I checked your code for the Exception Decoder and it seems that it's going through the installed tools and is searching for executable ending on An amazing thing would be to be able to listen on the Serial Monitor and print exceptions directly inline, much like |
Thanks for taking the time and looking into the PR. I also checked your original Java implementation quite a lot recently 😄 The current
On the spot. This is precisely the idea. It's not yet available from the IDE, but the CLI can print the I do not know much about the |
with access to all build variables in |
I appreciate your input! The tool paths can be inferred from the combination of the |
required tools will show only for installation from Board Manager and not when installed from git. For ESP32 platform all tools for all chips will be there (when installed from board manager), so you can not really figure out what is needed and what is where without having all build variables available. For single chip/architecture platform this might work fine, but not for ESP32 for sure. |
Could you share the procedure for how to do such an installation? |
The build properties mentioned by @dankeboy36 include those set in |
Here it is @dankeboy36: There are sets of manual installation instructions for Windows, Linux, and macOS, I linked to the Windows section simply because that is the first set of instructions. Scroll down on the page for the others. |
95097a0
to
d41c3ab
Compare
Depends on arduino/arduino-cli#2184. I have pinned the CLI version for the time being. |
258f174
to
e42d271
Compare
Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
There is a separate PR with the CLI version update. Rebasing from it should reduce the outgoing changes of this PR: #2083. |
|
workspaceState
Set the VS Code `workspaceState` on fqbn, port, and sketch path changes. VS Code extensions can read this cached state. Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
api plugin must start before any tool VSIX without explicitly updating the `extensionDependencies` with the API. Signed-off-by: dankeboy36 <dankeboy36@gmail.com>
43a703f
to
9518fdf
Compare
Bocked by arduino/arduino-cli#2197. |
Duplicate of #2110 |
Motivation
To provide a way to implement external tools for the Arduino IDE without modifying the IDE codebase. See #58.
This PR introduces a tiny layer of code to listen to Arduino context-related changes and set it on the VS Code
workspaceState
. Other VS Code extensions can import this new VSIX API and retrieve context information from the Arduino IDE—information such as the sketch path, FQBN of the currently selected board, etc. See https://github.com/dankeboy36/vscode-arduino-api for more details.I have an ongoing reference re-implementation of the ESP exception decoder. It works in the Arduino IDE. I did the reference implementation in Code and noticed that Theia has a few bugs, so the final implementation comes a bit later:
espDecoder.mp4
Change description
Other information
Reviewer checklist