This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TM4C1231D5PM: [ERROR] CORTEX_M4_0: Error connecting to the target

Part Number: TM4C1231D5PM
Other Parts Discussed in Thread: UNIFLASH, CC1350

Hello,

I have build new board with TM4C1231 micro-controller. Controller basic schematic i have copied from  TM4C1231  launchpad. Right now I am using EK-TM4C1294XL board for programming but I am facing [ERROR] CORTEX_M4_0: Error connecting to the target. I have checked Controller VDD(3.3V), VDDC (1.2V) also remove cap from RST pin ( Only pull up on RST pin). I have upgraded  EK-TM4C1294XLEK-TM4C1294XL ICDI firmware from LM flash tool but fail to unlock procedure. 

Please help to program device

  • Hello Supriya,

    Can you provide a schematic to review? If you do not want to share publicly I can send a friend request and get a private message for it instead.

    Without a schematic I don't really have any advice I can give based on the description.

    Best Regards,

    Ralph Jacobi

  • Hello,

    Please send friend request

  • Hello Supriya,

    I have sent it, once accepted I will start a private dialogue to receive the schematic.

    Best Regards,

    Ralph Jacobi

  • Hello Supriya,

    Reviewing the schematic I see that you don't have any pullup or pulldown resistors on the JTAG lines. That could explain this issue.

    The LaunchPad schematic is designed to be a minimal one to mass produce an affordable evaluation solution and it is not meant to be a full robust reference design.

    For JTAG you should reference our JTAG app note to see recommendations on schematic based on the connector you want to use: https://www.ti.com/lit/pdf/spma075

    That will show you which resistors to add and then you can try to program the device again.

    Also you should review our comprehensive System Design Guidelines to understand all the recommendations for different connections: https://www.ti.com/lit/pdf/spma059

    Best Regards,

    Ralph Jacobi

  • Hello,

    I have connected Pull to TMS and TCK, Pull down for TDO but still facing same issue. 

    Right now we are using 22pf capacitor for C14 and C18 instead of 24pf (32.768KHz crystal capacitors). It is makes any issue for programming 

  • Hello Supriya,

    With the resistors added do you still fail to be able to unlock the device as well?

    The capacitors on the 32kHz crystal shouldn't have an influence on programming for a new device.

    Speaking of the crystal, one of the reasons I wanted to check if the unlock procedure is now working would be that if there is an issue with the main oscillator then perhaps that could be what is causing programming issues. Before you were unable to unlock the device but if you can unlock it now, then see if you can program afterwards. If so there could be a clock setting / crystal hardware issue.

    Best Regards,

    Ralph Jacobi

  • Hello Ralph,

    I have done unlocking procedure. It is done

    After power cycling still same issue 

    Can you guide use what will be issue in crystal 

  • Hello Supriya,

    Alright so that's a positive step that you are able to unlock the device now. That means we have some level of proper communication between the ICDI and the JTAG interface.

    If you are unable to program the device at all after an unlock process, the crystal is not be an issue. In the current state of the device, it should be running from the PIOSC and not the crystal. I was only suspicious of the crystal if the device became unprogrammable after loading your firmware to it.

    I see from your original post you have checked all the voltages that we would look at for possible device issues. I presume RST is at 3.3V as well through the pull-up?

    Do you have another debug probe such as XDS100 or XDS200? The LaunchPad comes with a built-in ICDI debug probe. However, with an external debug probe such as the XDS100v2 and XDS200 you can run a JTAG scan test to see if JTAG interface is functioning correctly. You can run the JTAG scan test in CCS. It cannot be run using the built-in ICDI which is why I ask about the debug probes.

    Do you have any other boards to test to see if the problem can be replicated on other PCBs?

    Best Regards,

    Ralph Jacobi

  • Hello,

    Right now we don't have XDS200 or XDS100V2 but we already ordered. Yes RST is pull up with 10k. Also we are doing board bring up for next board. So we do same procedure and we will let you know result. 

    Is it any thing else we can do so we pin point the issue. 

    Is it we missed in layout that's cause of programming issue. 

  • Hello Supriya,

    I can't think of anything else to pinpoint the issue, getting to a point where the device unlock works but the board returns an 'Unable to initialize target - 0' error is a rare occurrence and the JTAG scan test is the next step for trying to debug the issue and having a second board to check would help a lot too.

    It is possible perhaps the device is damaged, so if the second board works then an ABA swap could be attempted next to isolate if its a device issue or a board issue.

    Layout wise I can't think of anything that would cause that sort of issue.

    Best Regards,

    Ralph Jacobi

  • Hello Ralph,

    Right now we have CC1350-A Launchpad having onboard XDS110. I have try to read device info using uniflash tool.

    facing below issue 

    Is there any setting i need to change.

  • Hello Supriya,

    I'm not familiar with how to use the XDS110 from a CC1350 LaunchPad. 

    The test to do would be a JTAG Scan Test which I don't believe can be done in Uniflash but needs to be done with Code Composer Studio. I don't know if I'd trust the results of bootlegging the XDS110 from a LaunchPad over using a proper debug probe however.

    Best Regards,

    Ralph Jacobi