The goal of this project is to expedite the delivery of quality code for the Arduino product family.
A lot of creative time is lost when spent configuring environments, researching hardware, downloading libraries and reviewing documentation. As a programmer, I find a lot of value in quality code libraries - I'm referring to both commercial and community-managed libraries. For example, when I can simply add a reference to a third-party library, #include
it in my code, start typing and - BOOM - I can see the classes and methods available.
Equally important to me is the workflow among teams I work with. I've noticed improvements in quality and turnaround time when task switching is kept to a minimum. If we can stay in one IDE, we are more productive. I appreciate having the option to view documentation in a small pop-up or simply CMD + Click
into a method and review the comments directly.
I noticed the Arduino team is refactoring their code in some major ways. If you haven't seen it, take a look over at The arduino-cli
Repo. It will be more easily leveraged from the code since they are providing the option to output as a JSON-formatted response. making the arduino-cli
easily accessed from the CLion GUI.
At the same time, I'm not an expert at C/C++ or CMake and I don't have the time it takes to master either one. Like most projects, I learn what I need to as the need arises. I want to incorporate modifications to the CMake files into this plugin as well. At a high-level, when I think of the most useful features for a developer just starting out with Arduino and CLion, they are....
- Board browser in build configurations
- Code Completion
- Select programmer and port (if applicable)
- Managed 3rd party libraries (i.e. Download/import)
- Debugging
- Automated updates to CMake files
- Advanced configuration of
arduino-cli
commands - Install/Update
arduino-cli
from CLion
...ya, basically, all the functionality available in the Arduino IDE.
Ultimately - with the right code completion/highlighting, file and project templates - I'm optimistic that this plugin could work in any JetBrains IDE. I'm not entirely convinced there will be anything amazing that CLion provides -- not like we need to use it's compiler or anything like that, it's all bundled with teh
arduino-cli
.
Name | URL | Status | Description |
---|---|---|---|
Clion | Link |
Production | A cross-platform IDE for C and C++ |
Arduino CLI | Link |
Alpha | arduino-cli is an all-in-one solution that provides builder, boards/library manager, uploader, discovery and many other tools needed to use any Arduino compatible board and platforms. |
IntelliJ | Link |
Production | |
JetBrains Plugin SDK | Link |
Production | Okay, it's not really software to download. This is a guide that ensures your environment is configured correctly. |
As it turns out, I've discovered that creating a plugin for the JetBrains IDE is incredibly difficult (...for me, anyway). The information available in the API is scant at best 1
Big Props
One of the best references I used was the code for MongoDB Integration in IntelliJ (aka -
mongo4idea
) It was helpful to see how something was properly set up, like which keys had to align for settings to be persisted.
This repository is a good example of what not to do. I have not added good documentation to my classes/methods. Mostly, this is because I didn't know how the API worked and what made the most sense. For example, how best to persist certain preferences and build configurations.
1. This is a quote from American Movie, but I couldn't find a clip with the exact quote. ...sooo, go watch the movie! ↩