JTAGICE3 not seeing ATSAMC21J18AU

Go To Last Post
10 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi,

After many years with the AVR, I am starting with ARM, specifically ATSAMC21J18AU. The JTAGICE3 works fine with AVRs, but fails to recognize the ARM part (using SWD interface.)

The "Tools | Device Programming | Apply" command appears to succeed, but when I click "Device Signature", it returns:

Timestamp:    2019-09-10 13:55:01.203
Severity:        ERROR
ComponentId:    20100
StatusCode:    131101
ModuleName:    TCF (TCF command: Device:startSession failed.)

Unexpected Chip Identifier 0x11010400 (expected 0x1101050f).

 

Since both 1 and 0 bits are seen, it appears the wiring is correct.

 

The Atmel Studio software is newly installed (using the web installer), Atmel Studio 7.0 1931; ATSAMC21_DFP.1.2.176

 

I have seen several similar queries on the boards, the usual answer is to update the Studio tools. But these are newly downloaded, afaik all latest versions.

 

Any further suggestions?

TIA

 

 

Dave

Last Edited: Tue. Sep 10, 2019 - 08:51 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

No,  I am not familiar with the Device Packs.

But on my PC C:\Program Files (x86)\Atmel\Studio\7.0\packs\atmel\SAMC21_DFP\1.2.176\samc21\include\samc21j18au.h

#define DSU_DID_RESETVALUE    _UL_(0x1101050F)

And on C:\Program Files (x86)\Atmel\Studio\7.0\packs\atmel\SAMC21_DFP\1.2.176\samc21\include\samc21j18a.h

#define DSU_DID_RESETVALUE    _UL_(0x11010500)

And on C:\Program Files (x86)\Atmel\Studio\7.0\packs\atmel\SAMC20_DFP\1.1.95\samc20\include\samc20j18a.h

#define DSU_DID_RESETVALUE    _UL_(0x11000400)

Edit.  I was intrigued.   So I updated the SAMC20 Pack e.g. C:\Program Files (x86)\Atmel\Studio\7.0\packs\atmel\SAMC20_DFP\1.1.151\samc20\include\samc20j18a.h

#define DSU_DID_RESETVALUE    _UL_(0x11000500)

So I suspect that AS7.0 is expecting the wrong ID.    Or perhaps your chip is actually samc20j18a

What is printed on the chip?

 

The header files should be generated from an accurate XML file.   There is something going wrong!!

 

David.

 

Edit again.   I did an "@-egrep -H 0x11010[45]0[0F]" through the SAMC21 Pack headers and got:

.\1.1.105\samc21\include\samc21j18a.h:#define DSU_DID_RESETVALUE    _UL_(0x11010400)
.\1.1.105\samc21\include\samc21j18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1101040F)
.\1.1.144\samc21\include\samc21j18a.h:#define DSU_DID_RESETVALUE    _UL_(0x11010500)
.\1.1.144\samc21\include\samc21j18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1101050F)
.\1.2.176\samc21\include\samc21j18a.h:#define DSU_DID_RESETVALUE    _UL_(0x11010500)
.\1.2.176\samc21\include\samc21j18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1101050F)
.\1.2.176\samc21\include_mcc\component\dsu.h:#define DSU_DID_RESETVALUE                    _U_(0x1101050F)                                      /**<  (DSU_DID) Device Identification  Reset Value */

 

Last Edited: Tue. Sep 10, 2019 - 08:53 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi David,

Thanks for the quick reply.

My 3 include files have the same #defines as you. Which would seem to indicate a ATSAMC20J18A.

 

The marking on the package reads (newlines as on the package):

Atmel

ATSAMC21J18A

-U

1825 E ARM

18253UP TW

 

The "1" in the part number is quite distinct.

 

 

Dave

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ah-ha.   Did you see my second edit?    The SAMC20 and SAMC21 ID have got different hex digits.

 

You have clearly got a ATSAMC21J18A chip and not the USB version ATSAMC21J18AU

The -U refers to package spec.   It is not part of the model number.

 

I would trust the chip Foundry more than the Pack maintenance intern.    I am suspicious of the 500 that seems to be introduced  in 1.1.144 and 1.1.176

 

Sh*t happens.    Perhaps Morten can offer a fix.

 

David.

Last Edited: Tue. Sep 10, 2019 - 09:04 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

"You have clearly got a ATSAMC21J18A chip and not the USB version ATSAMC21J18AU

The -U refers to package spec.   It is not part of the model number."

 

SOLVED!

 

I had looked at the chip, read it as ATSAMC21J18AU, & so set up the tool.

Once I reset the tool to expect a ATSAMC21J18A, everything works!

Since I am not using the USB, it's no problem.

 

Many thanks, everyone.

 

Dave

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I am even more intrigued.

 

What ID is reported by the programmer hardware?

 

David.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Tool info:

JTAGICE3
Debug host        127.0.0.1
Debug port        54955
Serial number     J30200007368
Connection        com.atmel.avrdbg.connection.cmsis-dap
Features          1
Firmware Version  3.36
Hardware Version  0

 

Device info:

Detected device
Device signature  0x11010400
Revision          E

Datasheet information
                          SAMC21J18A-MU  SAMC21J18A-MN  SAMC21J18A-MZ  SAMC21J18A-AU  SAMC21J18A-AN  SAMC21J18A-AZ
CPU                                                            CORTEX-M0PLUS
Flash size                                                         264 KB
SRAM size                                                          32 KB
VCC range                  2.7 - 5.5 V    2.7 - 5.5 V    2.7 - 5.5 V    2.7 - 5.5 V    2.7 - 5.5 V    2.7 - 5.5 V
Maximum operating speed      48 MHz         48 MHz         48 MHz         48 MHz         48 MHz         48 MHz

 

Regards

 

Dave

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I ran Device Information for the SAM21G18A device in my Arduino M0_Pro

 

Detected device
Device signature  0x10010205
Revision          C

Datasheet information
                          SAMD21G18A-MU  SAMD21G18A-MF  SAMD21G18A-AU  SAMD21G18A-AF
CPU                                             CORTEX-M0PLUS
Flash size                                          256 KB
SRAM size                                           32 KB
VCC range                 1.62 - 3.63 V  1.62 - 3.63 V  1.62 - 3.63 V  1.62 - 3.63 V
Maximum operating speed      48 MHz         48 MHz         48 MHz         48 MHz

 

And did a search over Packs

ff -c "@-egrep -H DSU_DID_RESETVALUE" SAMD21_DFP "*G18*.h"
SAMD21_DFP\1.0.222\samd21a\include\samd21g18a.h:#define DSU_DID_RESETVALUE    0x10010005UL
SAMD21_DFP\1.0.222\samd21a\include\samd21g18au.h:#define DSU_DID_RESETVALUE    0x1001000FUL
SAMD21_DFP\1.0.231\samd21a\include\samd21g18a.h:#define DSU_DID_RESETVALUE    0x10010005UL
SAMD21_DFP\1.0.231\samd21a\include\samd21g18au.h:#define DSU_DID_RESETVALUE    0x1001000FUL
SAMD21_DFP\1.2.280\samd21a\include\samd21g18a.h:#define DSU_DID_RESETVALUE    _UL_(0x10010305)
SAMD21_DFP\1.2.280\samd21a\include\samd21g18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1001030F)
SAMD21_DFP\1.3.304\samd21a\include\samd21g18a.h:#define DSU_DID_RESETVALUE    _UL_(0x10010305)
SAMD21_DFP\1.3.304\samd21a\include\samd21g18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1001030F)
SAMD21_DFP\1.3.331\samd21a\include\samd21g18a.h:#define DSU_DID_RESETVALUE    _UL_(0x10010305)
SAMD21_DFP\1.3.331\samd21a\include\samd21g18au.h:#define DSU_DID_RESETVALUE    _UL_(0x1001030F)

So there seems to be a certain amount of latitude over the ID in AS7.0

 

Hey-ho.   If you use Rowley IDE,   it identifies whichever ARM is connected by the SWD debugger.

With AS7.0 you have to know the device in advance.    And it is a little frightening that AS7.0 can't guess that readers might confuse an A device with an AU device.

 

David.

Last Edited: Tue. Sep 10, 2019 - 12:36 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Do note that parts of the DID is revision and other stuff, not only ID. Also, studio is supposed to tell what device goes to an ID when there's a mismatch... But apparently not... Hmmm.

:: Morten

 

(yes, I work for Atmel, yes, I do this in my spare time, now stop sending PMs)

 

The postings on this site are my own and do not represent Microchip’s positions, strategies, or opinions.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

As above, it's a SAMC21J18A, not SAMD21G18A.

The reported ID (11010400) is right for that part.

 

Dave