[SOLVED] V5.10g - Type "connect" to establish a target connection - new

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] V5.10g - Type "connect" to establish a target connection - new

    In previous versions of JLink(Exe) it was enough to specify device and interface and you would automatically connect to the device, eg

    "JLinkExe -if swd -device nrf51"

    and you could start typing commands and doing things.

    However starting around 5.10g you now get the following line output after the information about the connected Segger.

    Type "connect" to establish a target connection, '?' for help

    If you type connect, then it connects. It seems that if you don't but type a command which requires connection, it complains there's no connection and connects for you.

    However, if you're running JLink(Exe) from a tool, like make, which is pretty common, the terminal stops after the 'Type "connect" .. ' line and the rest of the script doesn't execute as it used to because it's waiting for keyboard input.

    Is this an intentional change? I would have expected if you specify the interface and device on the command line, it would auto connect. Is there another argument you can add to the command line to tell it to actually connect and keep processing? You can't add the 'connect' to the makefile script because it stops for keyboard input before it gets there. You can put the script in a file on the command line, but that's not really how most of those makefile build-and-upload scripts work.
  • try

    Source Code

    1. JLinkExe -if swd -device nrf51 -AutoConnect 1 -CommanderScript (your_file_name.jlink)


    I think the change was to know what special handling is needed befor probing for connection.
    The config option/command should not apply to SWD?
  • I'll try Autoconnect .. can't find that in the manual or the list of commands which' ? gives you'.

    I did find a note in the release notes back to 5.02 that JLink no-longer performs an auto-connect with searches on all interfaces by default. However this isn't a search on all interfaces so that shouldn't seem to apply.

    As I said at the end of the question - putting the commands into a file to be run isn't really how these makefile build-and-loads work. It needs to work if you were typing from the keyboard or there are a lot of makefiles going to need to be rewritten.
  • Hi,

    I'll try Autoconnect .. can't find that in the manual or the list of commands which' ? gives you'.

    thanks for pointing that out, we will update the manual and the command list provided by "?" regarding "autoconnect".


    Are you facing any other issues, or does "autoconnect" solve all problems caused by the switch from 5.02 to 5.10?

    Best regards,
    Niklas
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Thanks for the reply, sorry I missed it for a day.

    Yes Autoconnect seems to return it to doing almost what it did before, close enough at least. One person on the Nordic forums claims it still hung at the end of his script and never returned, but I can't make that happen myself.