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.

C28xx: Error connecting to the target: (Error -1015 @ 0x0)

Other Parts Discussed in Thread: UNIFLASH

Hi,

Processor is an F28335.

Getting this error when trying to download code:

C28xx: Error connecting to the target: (Error -1015 @ 0x0) Device is not responding to the request.  Device may be locked, or the debug probe connection may be unreliable. Unlock the device if possible (e.g. use wait in reset mode, and power-cycle the board). If error persists, confirm configuration and/or try more reliable JTAG settings (e.g. lower TCLK). (Emulation package 5.1.641.0) 

Started to get this error message this afternoon.  What does it mean?  I can't find any documentation for it.  I suspect the device may well be permanently locked...  Is there anyway of finding out?  

The connectivity from the JTAG is fine, the issue seems to be a Locked Device...

I've seen the Uniflash tool and wondered if I can unlock using this?  The problem is I have never set a password and wouldn't know what it is - unless there is a default?

  • Hi Mike,

    As suggested in error message, please use "Wait in reset mode" (or Wait BOOT) to power-up the device and then you should be able to connect to JTAG if issue is related to "LOCK".

    Once connected, please check the value at password location in Flash (refer TRM for the address) using CCS memory watch window. If you see all the content as 0x0 then device is indeed LOCK.

    Regards,

    Vivek Singh

  • Hi Vivek,

    Thankyou for this. One question - how do I enter the "Wait in reset mode" ? Is this via a setting within Code Composer? I'm just looking into it now....

    Thankyou,
    Mike.
  • Hi Mike,

    "Wait in reset mode"  need to be supported by emulator. It's basically driving the EMU0/EMU1 pins on the devices with proper value which is supported by some emulator.

    Alternatively, you could also use the "Branch to check boot mode" option by setting the BOOT Mode pins as mentioned in table below to connect to device.

    Regards,

    Vivek Singh

  • Thankyou,

    I've managed to hold it in Reset, as when I try to debug I get:

    C28xx: Failed CPU Reset: (Error -1137 @ 0x0) Device is held in reset. Take the device out of reset, and retry the operation. (Emulation package 5.1.641.0)
    C28xx: Trouble Reading Register PC: (Error -1137 @ 0x0) Device is held in reset. Take the device out of reset, and retry the operation. (Emulation package 5.1.641.0)
    C28xx: Trouble Reading Register ST1: (Error -1137 @ 0x0) Device is held in reset. Take the device out of reset, and retry the operation. (Emulation package 5.1.641.0)
    C28xx: GEL: Error while executing OnReset(1): Target failed to read register ST1
    at (ST1&~(0x0100)) [f28335.gel:312]
    at C28x_Mode() [f28335.gel:38]
    at OnReset(1)
    C28xx: Flash Programmer: Device is locked or not connected. Operation cancelled.
    C28xx: File Loader: Memory write failed: Unknown error

    So... now it is in reset, when I click on the Memory Browser within CCS there is nothing there.

    Is there anything else I can try?

    Thankyou,
    Mike.
  • Look like you held the XRSn pin low of the device which is not the correct method (it's not same as "Wait In Reset"). You should be using the other BOOT mode which I mentioned.

    Regards,

    Vivek Singh
  • Hi,

    Ok, I have an XDS200 Emulator - is this capable of the Wait in Reset function? I can't seem to find anywhere that suggests it is.
    Unfortunately I cannot see a table in your second from last post to try the "Branch to check boot mode" option. I'm just browsing the Datasheets now to see if I can find the table.

    Thankyou,
    Mike.
  • Hi Mike,

    I need to check about XDS200.

    On BOOT Mode table, it's on page 21 (Table 2-2. Boot Mode Selection) of Boot ROM Reference Guide.

    Regards,

    Vivek Singh

  • Hi there,

    I found the table now and I see what I need to do - thankyou. I will have to speak to the Electronics Engineer.

    Assuming we can get the device into Mode 3 - "Branch to check mode", I should then be able to view the memory contents via CCS to determine if it is a permanent lock or not?

    If it's a permanent lock, then we need to replace the device.
    If it's not a permanent lock - what would I need to do to get it unlocked?

    Thankyou again, I appreciate the help.

    Mike.
  • Hi Mike,

      If it's not a permanent lock - what would I need to do to get it unlocked?

    Device get locks in two conditions.

    1) Somthing get programmed in password locations in Flash - This happens due to wrong .out file which intentionally programs the password locations in flash. User could try to check the map file to see if anything mapped to password location address and if yes, then try to extract the password values from .out file and enter those values into KEYx register (in CCS Flash plug-in GUI) to UNLOCK the device.

    2) 128bit password value in Flash get programmed with value 0x0 - This could happen if flash operation got interrupted due to power loss or for some other reason. 

    In both the cases, content in Flash (including passwords) as well as secure RAM will be seen as 0x0 in CCS memory watch window. So it'll be difficult to say what is causing the error. If there is nothing mapped at CSM password locations in map file then one need to assume that it's case -2 and device need to be replaced.

    If you find that content in Flash are not 0x0 then device is not LOCK and there could be some hardware issue on board which is preventing the JTAG connection.

    Regards,

    Vivek Singh

  • Hi Vivek, I am also going through same 1015 error. I used "branch to check mode" to read the registers but the flash register is showing message 'error: unable to read' for all type of registers for example FOPT, FPWR, FSTATUS etc. What could be the problem. Thanks and Regard.
    Shailendra kumar Gupta
  • Shailendra,

    Look like you have not connected to CCS hence getting this message. Can you confirm if you are able to connect to CCS?

    Regards,


    Vivek Singh

  • Thank you for the reply. Yes I was connected but was operating in same debug session. I then terminated the session and on again debugging I could connect to the target emu pins set for 'wait in reset mode'. On checking the registers value all the registers were not at 0x0. I then connected the JTAG with both emu pins high and could see that the target is connected as normal.
  • Great. Is the issue resolved or you have any further queries?

    Vivek Singh

  • Yes it is resolved. Thanks