I'm trying to flash the samd21j18a microchip from Linux but I'am unable to do so. I've compiled toggle Led example from Atmel Framework. I tried to flash it using bossac tool and I received the following error message:
No device found on ttyACM0
The device /dev/ttyACM0 exists and I tried to run it under superuser to avoid problems with lack of permissions.
When I used the proprietary SAM-BA programmer it got stuck while connecting. I tried to flash it from Atmel Studio on Windows. It worked fine however it required an update of embedded debugger firmware to 2.10 version. After booting back to Linux and attempting to flash it again I received a different error message. Here is the whole output of bossac:
honza@honza-MS-7823:~/Downloads/BOSSA-1.6.1-arduino$ sudo '/home/honza/Downloads/BOSSA-1.6.1-arduino/bin/bossac' --info --port ttyACM0 --erase --write --verify --reset --debug -U false .pioenvs/samd21_xpro/firmware.bin Send auto-baud Set binary mode readWord(addr=0)=0xfcfc00fc readWord(addr=0xe000ed00)=0xfce01c readWord(addr=0x400e0740)=0x1cfcfce0 version()= chipId=0x1cfcfce0 Unsupported Cortex-M4 architecture No device found on ttyACM0
And the proprietary SAM-BA programmer also fails on the following message:
Invalid chip ID
It seems to be returning ID of Cortex M4 based chip even though it's Cortex M0+ based one.
I don't want to use Atmel Studio because I'm used to JetBrains IDEs and Linux environment.
I'm new to electronics and I'm kind of lost.
Thanks in advance