This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

RTL function disables jtag

I am trying to use RTL for the tcp communication part on the lpc2368 project. The stack ran ok on the lpc2378, but on 2368 it appears that the function Init_Tcpnet() somehow disables a jtag. After this function is executed, jtag doesn't connect anymore, giving an error "can't stop arm device". The only way to restore connection is to erase a chip with Flashmagic.
If I insert a loop before Init_Tcpnet(), connection never fails.
Pins and functions for ethernet are exactly the same for 2378 and 2368, so the reason is not in pin configuration, but somwhere else.
Did anybody have a similar problem?

Gennady

  • The devices have deticated JTAG pins and therefore the JTAG cannot be disabled there.

    Do standard examples work on the MCB2360 Board that you have?

  • I don't have mcb2360, only mcb2370, and the code works fine on it.
    According to the Keil's article "ULINK: PHILIPS LPC2000 ARM DEVICE DOES NOT REACT":
    'Your application program has most likely disabled the JTAG port during program execution. ARM devices start program execution even when the JTAG adapter is connected. When your application software disables the JTAG port, it is no longer possible to connect to the device via the JTAG interface.' ...

    Again, the only thing I know for sure, is that after the function Init_Tcpnet() is accessed, I can't access the jtag anymore and need to erase the chip.

  • Do standard examples work on the MCB2360 Board that you have?

  • I've put a delay of 2S at the beginning of main().
    Now behaviour is a little bit different.
    Debug session always starts, and if Init_Tcpnet() is not there, everything is ok.
    If Init_Tcpnet() is present, any attempt to stop a processor leads to the following:
    - message "Could not stop ARM device!" appears.
    - on 'OK' 'Stop' icon greys out and 'Run' icon appears.
    - attempt to run leads to dropping out of the debug session.

    There are 2 things I can think about:
    1. hardware - PHY initialization. I beleive that Init_Tcpnet() includes PHY initialization, so possible hardware problems probably can lead to the above behavior.
    2. I am using ULINK jtag, not ULINK2. Fmax is 200KHz (I also tried 100KHz). Are there any issues with ULINK that can lead to the problem?

  • Yes, it was a hardware problem. PHY oscillator was connected incorrectly and gave non-standard clock (and consequently no clock to the processor from PHY).
    Absence of this clock somehow affected jtag connection.
    Anyway, I am glad it's resolved now.

    Thank you for the response.