I take it you want to use a USBASP programmer to program a Arduino Uno or Nano? Or do you mean a new bootloader? I’ll assume it’s the former for now, as whilst I know it’s possible to install a new bootloader via PlatformIO, I’ve not tried it myself yet.
In the case of uploading a new program, you’ll want to refer to the Upload via Programmer documentation. But in a nutshell:
- Add the following to your projects
platformio.ini
file
upload_protocol = usbasp
upload_flags =
-Pusb
- Use the
Upload with Programmer
target rather than theUpload
one.