Be aware you must use 1.7.0 or higher version of bossac to program SAMD21 and SAMD51 boards! Versions of BOSSA before version 1.7.0 won't work because it doesn't support the SAMD21/51 chips. Also note that bossac versions 1.9.0 and newer have incompatibly changed their command-line parameters, and can erase your bootloader if it is not protected. (Adafruit boards ship with protected bootloaders.) Follow the directions below carefully, depending on which version you have.
Make sure you see BOSSA version 1.7.0 or higher! And see the warning below about version 1.9.0 and higher. If you see a lower version then you accidentally downloaded an older version of the tool and it won't work to flash SAMD21 chips. Go back and grab the latest release from this BOSSA GitHub repository as mentioned above. 2b1af7f3a8