Skip to content

Upload direct to Arduino bootloader with arduino-cli #39

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

Closed
wants to merge 1 commit into from
Closed

Upload direct to Arduino bootloader with arduino-cli #39

wants to merge 1 commit into from

Conversation

AshleighWilson
Copy link

Upload direct to Arduino bootloader with arduino-cli when g:arduino_upload_using_programmer is false. Without this the plugin always attempts to program the Arduino via an external programmer.

Change tested on Manjaro Linux and Neovim 0.4.4.

stevearc added a commit that referenced this pull request Jun 12, 2021
Addresses #39 in an alternate way. When set to None, no programmer will
be passed to the CLI. This will upload directly to the Arduino
bootloader.
@stevearc
Copy link
Owner

Thanks for the PR @AshleighWilson! I would prefer to make the "no programmer" option more integrated and not require another global var. I just added a commit to master attempting to do this. Can you give that a try and see if it works for you? When you choose the programmer there should now be a "-None-" option that should do what you want.

@AshleighWilson
Copy link
Author

Hi @stevearc, just checked and working as intended. Thanks for the quick response.

Actually, this was what I was attempting to do at first, but then I noticed the global variable g:arduino_upload_using_programmer was already being used in the plugin so thought that would have been a better option.

Also, do you think this should be the default option? I'm guessing the majority of people, especially those new to Arduino, would be using the bootloader upload via USB?

@stevearc
Copy link
Owner

Ah I see, yes that was added in a previous PR. I'll refactor it out and make that codepath respect the -None- option as well.

I've personally only used arduinos that require a programmer, but I guess that might be unusual and defaulting to none makes more sense to me than defaulting to a random programmer

stevearc added a commit that referenced this pull request Jun 12, 2021
Relevant to #39. To achieve the same behavior you can `let
g:arduino_programmer = ''`
@AshleighWilson
Copy link
Author

Great, thanks! I guess this PR can now be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants