Per Upload and Debug for ATmega328P with Atmel ICE - #6 by maxgerhardt you should try adding
board_upload.require_upload_port = no
to the platformio.ini
while removing upload_port = usb
and retry.
Per Upload and Debug for ATmega328P with Atmel ICE - #6 by maxgerhardt you should try adding
board_upload.require_upload_port = no
to the platformio.ini
while removing upload_port = usb
and retry.