CMSIS-DAP Debug

IDAP-LinkTM
CMSIS-DAP JTAG



Available on

https://www.crowdsupply.com/i-syst/blyst-nano


and
I sell on Tindie




The IDAP-LinkTM/M is a very low cost CMSIS-DAP JTAG debug probe with enhanced features.  It can do more with it than just debugging.  It will appears as a USB disk drive.  This allows firmware flashing easily by copying the firmware file over without requiring any special flashing software and work instantly with any operating system.  It provides a UART to USB bridge for communication between the target device and the PC.  It also provides a regulated 3.3V to directly power the target device without addition power source by taking advantage of the USB power source.  These feature turn the target device into mBed enable.  It can be used as an ultra low cost solution to production programming.  The IDAP firmware is written from scratch with optimization for performance and strictly  adhering to ARM specifications.    

  • Support both SWD & JTAG mode
  • It is just plug & play with most IDE such as Keil, CrosWorks, Eclipse, etc.. Works instantly, no driver to install
  • Onboard 3.3V regulator to power the target device
  • UART to USB bridge for communication between target and PC up to 3 MBaud
  • Dynamic embedded target device selection
  • microSD slot for flash programming without a PC
  • mBed enabled the target device
  • Firmware flashing by drap & drop simply by copying file over in BIN or Intel Hex format

IDAP-LinkTM is the full Debug JTAG probe : Data sheet & User guide
IDAP-M is the CMSIS-DAP on module : Data sheet & User guide
IDAP-Link/M Software Download now supports readback protection

Current firmware status :

All features are implemented.  Current supported targets
  • Nordic nRF51, nRF52
  • Epson S1C31D01, S1C31W74 (custom target implemented & maintained by Epson)
  • Supports USB-UART baudrate up to 3 MBaud streaming
  • More to come (NXP LPC, Freescale up next)
  • Works with all MCUs supported by OpenOCD, KEIL, CrossWorks, etc...



For maker who wants to add JTAG onboard


IDAP-M is the IDAP-Link core foundation. It is a small footprint 16 x15 mm module designed to be integrated onto your board design to provide a CMSIS-DAP and mBed functionality.

IDAP-M module
The core CMSIS-DAP of the IDAP-Link
available on Tindie





Onboard target connection

Flash programming without PC using microSD


The IDAP-Link can Flash program the target using a micro-SD containing the firmware.  It is done simply by a press of a button.  Gang programming by using multiple IDAP-Link this way no PC is require


  • Connect the IDAP-Link to PC.  Run the command line IDAPSetTarget program to select the target device. Pass the index number of the target device as argument to the IDAPSetTarget program.  Running the IDAPSetTarget without argument will display a list of supported target device along with its index number.  Once the target is successfully programmed into the IDAP-Link, the a list of require firmware file name is listed.  This is require only done once unless a different target is needed.
  • Copy the the firmware files with predefined file names onto the microSD card.  The firmware file name must be exactly the same as those listed during the target selection step above.
  • Power up the IDAP-Link or press the Reset button (S2) with the microSD in the slot. The microSD card must be inserted prior to power up the IDAP-Link otherwise it will not switch to microSD programming mode
  • If the IDAP-Link is still connected to the PC.  The USB mass storage device will show up.  Eject it from the PC prior to start flashing.  Keeping the USB mass storage connected to the PC will have a huge impact on the Flashing performance as PC will try to access the microSD card at the same time.
  • A USB power source is require to power the IDAP-Link if not connected to PC.  
  • Press ISP/PROG button (S1) to start Flashing.  The green LED will turn on or blink.  The programming status will be also be printed to the USB CDC COM port.
  • Once programming completed, the green LED will turns off.  If programming failed, the red LED will blink at 1 sec interval.  All LED are off when programming is successful.   



Gang programming with PC via USB


With the drag & drop feature, it would be easy to do gang programming by connecting multiple IDAP-Link to a single PC via a USB hub.  Each IDAP-Link then would appears to the PC as a USB drive.  All that is left to do is to copy firmware file over to each drive.  This could be accomplished by a batch command.  Using IDAPnRFProg command line program to flash using multiple IDAP-Link at the speed of 12KB / s.  Flashing SD + APP + DFU in 16 s.


Parallel gang Flashing nRF51 with IDAPnRFProg on OS X and Windows


On OS X using IDAPnRFProg (click to download) flashing Softdevice + Firmware + DFU
Windows version of IDAPnRFProg (click to download) :

IDAPnRFProg s110_nrf51822_7.1.0_softdevice.hex Blinky_ble.hex dfu_sdk7.hex


$ ./IDAPnRFProg s110_nrf51_8.0.0_softdevice.hex Blinky_ble.hex dfu_nrf51.hex
IDAPnRFProg version 0.2
Copyright 2015, I-SYST inc. All rights reserved

Found IDAP-Link - S/N : 0000000000001
Found IDAP-Link - S/N : 0000000000002
IDAP-Link-0030415000005 : nRF51822-QFAA R2, Rev.2, HWID = 0x003C, DEVID = 0x299C1D17BD361134
IDAP-Link-0030415000005 : Flash size = 262144, Ram size = 16384
IDAP-Link-0030415000017 : nRF51822-QFAA R1, Rev.1, HWID = 0x001D, DEVID = 0x32B4DDFECEE22394
IDAP-Link-0030415000017 : Flash size = 262144, Ram size = 16384

IDAP-Link found : 2

IDAP-Link-0030415000005 : Erase Flash
IDAP-Link-0030415000017 : Erase Flash
IDAP-Link-0030415000005 : Blank checking...
IDAP-Link-0030415000017 : Blank checking...
IDAP-Link-0030415000005 : Programming...
IDAP-Link-0030415000017 : Programming...
IDAP-Link-0030415000005 : Firmware start address 0x18000
IDAP-Link-0030415000005 : DFU start address 0x3c000
IDAP-Link-0030415000017 : Firmware start address 0x18000
IDAP-Link-0030415000017 : DFU start address 0x3c000
IDAP-Link-0030415000005 : Programmed 256 KB in 21.524 sec at rate 11.894 KB/s
IDAP-Link-0030415000005 : Verifying...
IDAP-Link-0030415000017 : Programmed 256 KB in 21.524 sec at rate 11.894 KB/s
IDAP-Link-0030415000017 : Verifying...
IDAP-Link-0030415000005 : Flashing succeeded.
IDAP-Link-0030415000017 : Flashing succeeded.

Total Flashed 2 nRF51 devices in 51.112 sec, 1024 KB R/W transfered, rate = 20.035 KB/s



Flashing using OpenOCD


The current HEAD OpenOCD is performance has improved 10 fold.  It is now flashing at 9 KB/s.


nRF51:

openocd -f interface/cmsis-dap.cfg -f target/nrf51.cfg -c "program s110.hex verify"



LPC17xx :

openocd -f interface/cmsis.cfg -f target/lpc17xx.cfg -c "program blinky.hex verify"


LPC11xx:


openocd -f interface/cmsis-dap.cfg -f target/lpc11xx.cfg -c "program blinky.hex verify"


Freescale:

Note : kinetis.cfg of the current OpenOCD 0.9xx does not work with KL26.  Use the one in EHAL. 

openocd -f kinetis.cfg -c "program blinky.hex verify"



Debugging with OpenOCD



To enable debugging in Eclipse, select the menu Run/Debug Configuration.   A popup as bellow will appear.  Then create new GDB OpenOCD debugging configuration.


In the OpenOCD configuration popup,  select the Debugger tab to configure OpenOCD.   OpenOCD requires configuration files .cfg for the target device and the interface device.  The interface device should be set with -f interface/cmsis-dap.   The target device depends on which MCU being used.   The picture bellow shows configuration example for the nRF51 series.




OpenOCD with multi-board


When multiple IDAP-Links are connected to the PC, OpenOCD needs to know which is to be used for the debug session.  This can be accomplished using the OpenOCD command 'cmsis_dap_serial' to select the target board to use using its serial #.  Type in the Config options box -c “cmsis_dap_serial #######” where ###### is the serial number.  The image above shows the selection of the IDAP-Link with serial number '0030415000000' for the debug session.

Semihosting with OpenOCD

In order for semihosting to work.  It needs to be enabled both in OpenOCD and code initialization.

The code initialization is as follow :

extern void initialise_monitor_handles(void);

int main(void) {
    initialise_monitor_handles();

    printf("hello world!\n");
}

These linker flags are also required

--specs=rdimon.specs -lrdimon

The semihosting support in OpenOCD debug session is done in the Startup tab of the Debug configuration.  See picture bellow.





126 comments:

  1. Hello Nguyen,

    Does the IDAP-Link work with any Cortex M MCU? I am working with LPC824, KL27, and a few others and I'm hoping I can use IDAP-Link as J-Link alternative?

    Or is it just for nRF51 based boards?

    Thanks!

    ReplyDelete
    Replies
    1. Yes, it does. Any cortex-m (m0-m4) supported by OpenOCD or other IDE such as Keil, CrossWorks, IAR, etc...
      I used it on LPC11xx, LPC17xx, Freescale KL26Z, K22, Atmel SAM3
      The SD card, Drag & Drop and the parallel programming IDAPnRFProg are only for nRF5x at the moment. I am working on a more generic version that can support other MCU as well.

      Delete
  2. Programming is combination of intelligent and creative work. Programmers can do anything with code. The entire Programming tutorials that you mention here on this blog are awesome. Beginners Heap also provides latest tutorials of Programming from beginning to advance level.
    Be with us to learn programming in new and creative way.

    ReplyDelete
  3. Hi, I build a homemade IDAP-Link. I have the two led blinking, however my windowns 10 put "unknow usb device". I try to install CDC as in the doc, but there is an error too.
    I want to use with Keil. The question is if the IDAP has HID interface as CMSIS DAP?

    ReplyDelete
    Replies
    1. Yes, the IDAP-Link is CMSIS-DAP. You can use it with Keil or other directly selecting CMSIS-DAP device. CDC driver is not required for Windows 10. The IDAP-Link firmware can only work on IDAP hardware. For your board, you can use this open source firmware https://github.com/I-SYST/CMSIS-DAP_IDAP-Link. This firmware is from mBed which I adapted for IDAP-Link for people who wants to use mBed firmware. IDAp-link firmware is written from scratch based on ARM CMSIS-DAP & Coresight specs.
      If you wish to build the IDAP-Link, you can use the IDAP-M for it. It's on this page.

      Delete
    2. Hi. I try to made the IDAP-M trying to compare the pin out of the module and the LPC11U37. So the IDAP-M is not hardware open?
      So for the firmware I need to try to compile the GIT you gave me? Becuase I see there is no .bin in the folders.
      Thank!

      Delete
    3. Sorry, it is not open. I got knock off by the Chinese so now my software won't work any boards other than the IDAP-Link or IDAP-M. yes, use that firmware. You need Keil to compile it. There is a Keil project for it. I haven't touched it for over a year now. The pin map is probably a little old. You need to check it.

      Delete
    4. Thank you Nguyen for your words! I compiled the proyect after fighting with the GIT and the "version_git.h" error! The Keil recognize it as DAP and SWD. However every time I plug and unplug appear a virtual unit to format (as a pendrive & I don't have any uC in the chain). I suppose this is the feature of the mbed to drag & drop the .bin.
      I like your project becuase you have JTAG & SWD, and the standard CMSIS-DAP is only SWD (I believe) and the CDC is really interesting.
      Great work and thank you for your comments!

      Delete
  4. It appears that IDAPnRFProg leaves the nRF51822 in debug mode after flashing. This leaves the nRESET pin inoperative and is causing me other problems. I would like to see a command-line option to cause IDAPnRFProg to terminate debug mode after flashing.

    ReplyDelete
    Replies
    1. I don't quite understand what you mean by leaving the nRESET pin inoperative on the nRF51822. That pin is not available after the processor is started. It's a shared pin with SWDIO. After programming the IDAPnRFProg sends a debug reset command which causes the processor to perform a reset and start executing the code that was flash. Though it is no longer in debug mode. It does not however precluded that your code can cause a hard fault. Have your code run in the debugger ? You can use the IDAP-Link with OpenOCD or any other IDE that support CMSIS-DAP to debug your code.

      Delete
  5. From the rRF1822 manual, "In debug interface mode, the SWDIO/nRESET pin will be used as SWDIO. The pin reset mechanism will
    therefore be disabled as long as the device is in debug interface mode."

    With the IDAP-Link attached, bringing the nRESET pin low does not reset the chip. If I disconnect the IDAP-Link and hard power cycle the chip bringing nRESET low will reset the chip as expected.

    Exiting debug mode appears to involve more than what you are doing. From the manual...

    "Normal mode can always be resumed by performing a "hard-reset" through the SWD interface:
    1. Enter debug interface mode.
    2. Enable reset through the RESET register in the POWER peripheral.
    3. Hold the SWDCLK and SWDIO/nRESET line low for a minimum of 100 ┬Ás"

    I haven't run OpenOCD yet. That will be my next step.

    One other thing I've encountered is that the nrf_drv_gpiote driver does not function with the IDAP-Link attached. Button presses do not register. It seems like interrupts are not firing, although it's hard to say for sure what's going on. When I detach the IDAP-Link and hard power-cycle the chip the button presses do register.

    ReplyDelete
    Replies
    1. I see what you are referring too. The IDAP-Link is a generic interface. It does not know the specific register for enabling reset pin. So it leaves the register as it. It does however sends a jtag reset code to the target when the ISP button is pressed. This used in the case of the nRF51 where no dedicated reset pin is available. The IDAPnRFProg program also does a jtag reset at the end of programming but does not change the register. I can add an option to enable reset pin in the next version.

      For the button, is that gpio pin connected to the IDAP-Link ? Please note, at power on, the IDAP-Link will put the target in halt mode. Use the ISP pin to perform a Reset on the target to start it.

      Delete
    2. It appears that interrupts are not firing or their vectors are not being executed after the chip is programmed using IDAPnRFProg. The program executes normally in all other respects. Everything works as expected if I use only OpenOCD. The solution for me is to use OpenOCD during development and to use IDAPnRFProg for bulk flashing.

      Delete
  6. I never got round to using the IDAP-LINK I purchased a while back, for various reasons. I am currently working with Kinetis MKL26Z parts, are you supporting them yet?

    Thanks

    ReplyDelete
    Replies
    1. Hi,
      It does work with anything that is supported by OpenOCD or by the IDE such as KEIL, CrossWorks, IAR... I used it to develop on Eclipse with OpenOCD on LPC17xx, LPC11xx, KL26, nRF51, nRF52. If the OpenOCD default .cfg for KL26 does not work properly, you can used my kinetis.cfg in the EHAL libary, see the EHAL page for the link to GitHub repo.

      Thanks

      Delete
  7. This would support traditional jtag style debugging on an nrf52xxx mcu? I'm looking to investigate their softdevices for a full open source stack.

    ReplyDelete
    Replies
    1. Yes, it is ARM standard debug jtag. It can be used to debug any Cortex-M series either SWD or JTag mode. As for the softdevice, it is not open source. Nordic provide bin only. There are however other initiatives already making open source Bluetooth stack. You can easily google for it.

      Delete
  8. I'm aware the softdevices are bin only, but one could debug them with jtag to gain insight. I've actually been looking for an open source stack for them, but google fails me. Do you think you could provide some project names?

    ReplyDelete
    Replies
    1. just google 'bluetooth stack open source', you'll find a bunch.

      Delete
  9. Just bought and received this programmer. Tried it in uVision and using IDAPnRFProg and it works great! Thank you for developing and selling it!

    ReplyDelete
  10. I'm interested in talking to you about licensing this work on a different processor. I'm dgrobinson at dgrobinson dot com.

    ReplyDelete
  11. How do you power it when doing programming without PC (using the miniSD)?

    ReplyDelete
  12. When using IDAP for SWD programming. Why is TVCC needed?
    In our case, we use the 3.3V from IDAP to power the device.
    Can we just connect TVCC to the 3.3V as well?

    ReplyDelete
    Replies
    1. The TVCC is the power that comes from the target. It is used for level shifter so the IDAP-Link can be used to program targets with power ranging from 1.8-3.6V. It is required to operated properly.

      Delete
  13. Can you be more specific? Say I want to program nrf51822. Which pin on the nrf51822 is suppose to be connected to TVCC?

    ReplyDelete
    Replies
    1. You need to connect
      nRF5x --- IDAP-Link
      SWDIO --- SWDIO
      SWCLK --- SWCLK
      GND --- GND
      VCC --- TVCC

      Delete
  14. OK. That's what I thought. Thank you!

    ReplyDelete
  15. Great post! I am actually getting ready to across this information, It's very helpful for this blog.Also great with all of the valuable information you have Keep up the good work you are doing well.
    Embedded Training in Chennai

    ReplyDelete
  16. Hi,
    I am trying to flash nRF52 development kit using IDAPLink. The connection are as follows:
    nRF52(P20) --- IDAP
    VDD --- TVCC
    SWDIO --- SWDIO
    SWDCLK --- SWDCLK
    GND DETECT --- GND

    I tried using IDAPnRFProg_0.9 and IDAPnRFProg_1_0_Alpha3 both to flash the nRF52 target it is showing the error "Failed connecting to target".Please let me know,What went wrong?

    ReplyDelete
    Replies
    1. Hi,

      P20 is the JLink output. P18 (Debug In) is the one to use for the nRF52. The DK already have the JLink on board. Why would you need an external jtag ?

      Delete
  17. Hi,

    I am trying to flash nRF52 development kit with IDAPLink. The connections are as follows:

    Method 1:
    nRF52 (P20) -- IDAP
    VDD -- TVCC
    SWDIO -- SWDIO
    SWDCLK -- SWDCLK
    GND DETECT -- GND

    Method2:
    nRF52 (P20) -- IDAP
    VDD -- TVCC
    SWDIO -- SWDIO
    SWDCLK -- SWDCLK

    GND DETECT to GND (nRF52) -- GND (IDAP)

    I power up the target by using 3.3 volt and GND pin on IDAPLink. Afterwards,I tried using both IDAPnRFProg_0.9 and IDAPnRFProg_1_0_Alpha3 one after the other but it is giving error "Failed Connecting to Target".Please feel free to let me know,What would went wrong??

    ReplyDelete
    Replies
    1. Hi,

      P20 is the JLink output. P18 (Debug In) is the one to use for the nRF52. The DK already have the JLink on board. Why would you need an external jtag ?

      Delete
    2. Thanks for letting me know about it.I just wanted to check whether the DAPLink with nRF52 DK. So,I need to connect to Debug In (P18) in order to make it work.

      Apart from that,I had another query "Can I use 10-pin Cortex Debug Connector (P2) on IDAPLink to flash nRF52?"

      Once again,Thanks for letting me know.

      Delete
    3. Yes, exactly connect the P2 of IDAP-Link to P8 of DK. That should work. The IDAPnRFProg_0.9 is for use with older firmware 0.6. The newer IDAPnRFProg is for the new beta firmware.

      Delete
  18. I am extremely grateful for your prompt responses.One last concern after connecting P18 on nRF52 DK to P2 on IDAPLink. Can I drag-n- drop any hex file into the "IDAP_FLASH" drive in order to flash corresponding hex file into nRF52 DK?

    ReplyDelete
    Replies
    1. Yes, you can do that or you can use the IDAPnRFProg which is faster. The drag & drop has a limitation that only one hex file can be flashed. Which means you need to merge SD + firmware all into 1 hex file.

      Delete
  19. Thanks!!Good luck with your project.

    ReplyDelete
  20. Hi,

    Can I able to debug the IDAP Link using P3 by connecting it to Segger Jlink?Since,I developed interface firmware for nRF52 DK using the IDAPLink github repo and Keil MDK. When I trying to drop ".bin" example in MBED drive,It was asserting an error "RESERVED BITS" in "fail.txt"

    ReplyDelete
    Replies
    1. Yes, of course you use the JLink or IDAP-Link to debug mBed DAPLink code on IDAP-Link with KEIL.

      Delete
  21. Thanks,Do you have any clue why it was asserting an error "RESERVED BITS" in "fail.txt" when trying to develop interface firmware for nRF52 DK using the IDAP Link github repo and Keil MDK?

    ReplyDelete
    Replies
    1. I don't know what that could be. The mBed firmware is bigger than 32KB, I couldn't compile it.

      Delete
    2. Thanks for your reply,I am trying to figuring it out.Btw.You can set the optimization level in order to reduce the code size.I set it to "O-2" level then it compiles successfully for me.Hope that helps.

      Delete
    3. I tried all optimization settings no luck. Which version of KEIL are you compiling with ?

      Delete
    4. I tried with Keil uVision5. It works foe me but you have to install one software pack for uVision5 in order to make it run

      Delete
    5. could you tell me which pack did you install ? I can help debugging if I can have it compiled.

      Delete
    6. This comment has been removed by a blog administrator.

      Delete
    7. Sorry for delay in the reply. It's "MDK Version 4 Legacy Pack".Feel free to go through the below link,
      http://www.keil.com/support/man/docs/uv4/uv4_ca_migrate2v5.htm

      Delete
  22. Hi,

    I had another concern,When I am plugging IDAP Link board to desktop it says "format the disk in drive E: before you can use it".Please let me know,What would be the issue?

    ReplyDelete
    Replies
    1. It's the usb drive emulation. Which version of Windows are you using ? Which IDAP firmware version ?

      Delete
    2. This comment has been removed by a blog administrator.

      Delete
    3. It works for me just updated the firmware version thanks for letting me know and for your reply as well

      Delete
    4. I tried drag n drop programming after this error "format the disk in drive E: before you can use it" but can't able to program the nRF52 DK and it doesn't return the "fail.txt" file as well. Meanwhile,When I am trying to program with IDAPnRFProg it works well without any issue.

      Can you please let me know,What exactly the problem is?

      Delete
    5. Which WIndows version are you using ?
      You need to set the target device with IDAPSetTarget first. You need to do this only once until you change target device. For example 'IDAPSetTarget 2' will set nRF52832 as target. The IDAP firmware is not is not mBed firmware, there is no fail.txt.

      Delete
    6. I am using Windows 7

      Delete
    7. Do you still have issues ? Could you email me your hex file so I can debug it, thanks.

      Delete
    8. It works fine with ".hex" files but can't able to do it ".bin" files.Trying to figuring it out and let you know if I encounter any problem.Thanks for helping a lot Nguyen.

      Delete
    9. I am having the same issue and sending the ".bin" file wanted to flash onto nrf52 DK. Apart from that,I am sending the mBed firmware ".hex" file as well just let me know if you are able to help me in debugging it.I am sending files to support@i-syst.com

      Delete
    10. I received your email. Thanks for sending the files for debugging.

      Delete
    11. You are welcome,Looking forward for your response.

      Delete
  23. Dear Nguyen,

    We successfully flashed our nRF52 with your programmer. However, we found it to be extremely slow.
    Here is the report:


    IDAPnRFProg Ver. 1.0.170624
    Copyright 2015, I-SYST inc. All rights reserved

    Found IDAP-Link/M - S/N : 0030416000085, Firmware : 1.0.170423

    Target device found : 1


    IDAP-Link/M-0030416000085 : nRF52832-QFAAB0, Rev.-1, HWID = 0x52832, DEVID = 0xF26ADEA2AFB56FCD
    IDAP-Link/M-0030416000085 : Flash size = 524288, Ram size = 65536
    IDAP-Link/M-0030416000085 : Erase all
    IDAP-Link/M-0030416000085 : Blank checking...
    IDAP-Link/M-0030416000085 : Chip erased
    IDAP-Link/M-0030416000085 : Programming...
    IDAP-Link/M-0030416000085 : Programmed 508 KB in 45.745 sec at rate 11.105 KB/s
    IDAP-Link/M-0030416000085 : DFU start address 0x7a000
    IDAP-Link/M-0030416000085 : Verifying...
    IDAP-Link/M-0030416000085 : Programming succeeded.
    Total programmed 1 nRF51 devices in 50.128 sec, 2032 KB R/W transfered, rate = 40.536 KB/s

    First, what speed should we expect to get? Is 40KB/s reasonable?
    Second, the hex we flashed was ~700KB. That shouldn't have taken 50 sec.
    Third, why does it say nRF51 device programmed?

    ReplyDelete
    Replies
    1. Thanks, for reporting. It was just a wrong message. I though it was corrected. The verify was changed to do checksum instead of read back the whole flash and compare. The previous version, it reads back the whole and compare with the original in memory. There was 700KB initial write, then a read back 700KB, then a compare of 700KB. The new verify is not the same case. I'll readjust the calculation. Thanks

      Delete
    2. Where is this new version? Is this in firmware or a new IDAPnRFProg?

      Delete
    3. Also, what is the expected transmit speed with SWD using IDAP?

      Delete
    4. The maximum speed is about 1MHz. The latest version of firmware software is at https://sourceforge.net/projects/idaplinkfirmware/?source=directory

      Delete
  24. Another problem we experienced is that one in a while, we get the following error:
    IDAP-Link/M-0030416000085 : nRF52832-QFAAB0, Rev.-1, HWID = 0x52832, DEVID = 0x21F7A5356665163E
    IDAP-Link/M-0030416000085 : Flash size = 524288, Ram size = 65536
    IDAP-Link/M-0030416000085 : Erase all
    IDAP-Link/M-0030416000085 : Blank checking...
    IDAP-Link/M-0030416000085 : Flash NOT BLANK. Device may be protected
    IDAP-Link/M-0030416000085 : Atempting to unprotect and erase Flash again

    And then programming does not work correctly (even though it says successful).
    Chips are not protected. When we execute the IDAPnRFProg again, it usually works the second time.

    ReplyDelete
    Replies
    1. Thi happens when there was a bad chip or an Engineering version of it. Eventually, it will stop working.

      Delete
    2. Is there a way to catch this event or test for it? (Flash NOT BLANK). Maybe with a different executable return code?

      Delete
    3. Yes, it is certainly possible. I'll add it to the next release of the software.

      Delete
  25. I see that these cannot be ordered now from the store and that only 2 are left in stock. Is that accurate?

    ReplyDelete
    Replies
    1. Sorry, I am travelling right now. I switched production to China to reduce cost in order to reduce the sale price but the yield was terrible. Many soldering issues. I hope to get production running again soon. I usually keep a few on reserve if you need more.

      Delete
    2. Sounds good. We definitely want to order a couple more as soon as they are available.

      Delete
    3. Ping me when you are back from your vacation. We would like to order a couple more.

      Delete
  26. What is the maximum number of IDAPlinks you managed to simultaneously connect to a PC?
    We are trying to figure out an optimal strategy for gang programming.

    ReplyDelete
    Replies
    1. That's depend on how many USB connection your PC can handle. The IDAPnRFProg does not have a limit. It will scan for all that it can find on the USB bus.

      Delete
  27. I am having trouble getting serial information read from the UART 16 pin connector.
    I have a circuit that is sending characters over 115200 baud (verified via nrf52dk board), however, when I connect the it to the idaplink port, I don't see anything on the corresponding com port.
    Any ideas how to proceed?

    ReplyDelete
    Replies
    1. Connect nRF RX pin to IDAP T_RXD (12) pin and nRF TX to IDAP T_TXD (11) pin

      Delete
    2. This comment has been removed by the author.

      Delete
    3. My circuit only outputs over UART, so I don't have a RX pin on nRF.
      I connected nRF TX to pin 11 on IDAP as well as GND.
      Still - there I don't get anything on the terminal.

      Delete
    4. UART has TXD & RXD. What is you TX & RX pin config in the nRF code ? If you tested on the DK then look under the DK PCB. It will indicate which pin of the nRF.

      IDAP Pin --- nRF Pin
      TVCC --- nRF VCC
      GND --- nRF GND
      T_TXD --- nRF TXD pin (pin number configured by your code)
      T_RXD --- nRF RXD pin (pin number configured by your code)



      Delete
    5. Let me elaborate. I am connecting a custom device with nrf52832 (or nrf51822). The board is running mbed os with Serial defined over two pins. the RX is a dummy pin and not actually connected to anything. The TX pin outputs debugging messages from the device. I've been using this device with many other debuggers that have UART (MK20, NRF51DK, NRF52DK) and in all of those cases, I never connected the device RX pin to the debugger.
      Perhaps it is because I didn't connect TVCC. Let me check.

      Delete
    6. The IDAP-Link has a level shifter so TVCC is required.

      Delete
    7. Yes. That was the issue. Everything works now.

      Delete
  28. I have a question regarding the buttons. We are thinking about connecting several IDAPlink to an arduino/other MCU to do the gang programming from the SD card (and then additional testing). It is possible to solder out the three buttons and connect them to a digital out of the arduino? Do they pull high/low?

    ReplyDelete
    Replies
    1. Yes, it is possible to hack it. You can tie them all together to a single button. The button is pullup internally so no pullup is required on the Arduino side. The button is active low.

      Delete
    2. Note that SD card programming is slower than using the IDAPnRFProg program.

      Delete
  29. IDAPSetTarget on OSX hangs problem.
    I just tried to run IDAPSetTarget for the first time on my mac and it get stuck with the following message:
    ./IDAPSetTarget 2

    IDAPSetTarget Ver.: 1.1.170624
    Copyright 2015, I-SYST inc.

    This program is used to set the runtime target for the IDAP-Link/IDAP-M

    I'm running 10.12.5 (macOS Sierra).

    ReplyDelete
    Replies
    1. I am not sure what could be the problem. I work on MAC as well and could not reproduce the problem with and without the IDAP-Link connected. When there is no IDAP-Link connected. It took about 3 secs to timeout but no hanging. Running on Sierra 10.12.6

      Delete
  30. Is there a way to instruct IDAPlink to perform a target device reset from the command line?

    ReplyDelete
    Replies
    1. Currently not. IDAPnRFProg does reset the target after programming is completed.

      Delete
  31. Is there a way to restrict IDAPnRFProg to program only one of the IDAPlink modules if multiple of them are connected to the PC? If not, can you please add this feature for the next software release? (maybe with a specific flag and the serial number of the IDAPlink?)

    ReplyDelete
  32. Hi,I brought the new IDAP-Link and trying to debug using P3 on board when I am starting the debug session it is showing "Cannot Write to RAM for Flash Algorithms !" in the output console


    ReplyDelete
    Replies
    1. Hi,
      P1 & P2 are for debugging target deviice. P3 is reserve for IDAP-Link itself.

      Delete
  33. Hi I just received a IDAP-LINK. The PCB is rev 4 and the firmware version is 1.2.170814. The firmware folder on sourceforge only has folders for IDAP-Link_R2 and _R3 and IDAP-M. What firmware should I use for the rev 4 PCB?
    Thanks.

    ReplyDelete
    Replies
    1. Hi,
      The firwmare r3 is for board rev3 and above. Your board should use r3 fiwrmware

      Delete
  34. OK. I keep getting the following message:
    IDAP-Link/M-2030417000009 : nRF52832-QFAAB0, Rev.-1, HWID = 0x52832, DEVID = 0xEA5E62639D28766F
    IDAP-Link/M-2030417000009 : Flash size = 524288, Ram size = 65536
    IDAP-Link/M-2030417000009 : Erase all
    IDAP-Link/M-2030417000009 : Blank checking...
    IDAP-Link/M-2030417000009 : Flash NOT BLANK. Device may be protected
    IDAP-Link/M-2030417000009 : Atempting to unprotect and erase Flash again
    IDAP-Link/M-2030417000009 : nRF52 Locked. Unlocking...
    Total programmed 1 nRF5x devices in 124.125 sec, 508 KB R/W transfered, rate = 4.093 KB/s

    But nothing is actually transferred to the device.
    The chip is not locked. When I connect with nRFgo studio, it shows that everything is blank.
    Any idea?

    ReplyDelete
    Replies
    1. I'm using IDAPnRFProg Ver. 1.3.170826 on my mac

      Delete
    2. This does not happen with Ver. 1.1.170722

      Delete
    3. Sorry about, bad target file was introduced into the build. New is build is uploaded now. Thanks for reporting. If possible please use support at i-syst dot com for bug report, thanks.

      Delete
    4. IDAPnRFProg Ver. 1.3.170826 works great again.
      Thank you for the quick fix!

      Delete
  35. Hi,

    Sometimes I'm able to program at ~12 KB/s but often the IDAP only programs at ~6 KB/s. Can you shed any light on this?
    IDAPnRFProg Ver. 1.3.170826
    Found IDAP-Link/M - S/N : 2030417000017, Firmware : 1.2.170817

    Target device found : 1

    IDAP-Link/M-2030417000017 : nRF52832-CIAAB0, Rev.-1, HWID = 0x52832, DEVID = 0x414E08278E348C52
    IDAP-Link/M-2030417000017 : Flash size = 524288, Ram size = 65536
    IDAP-Link/M-2030417000017 : Erase all
    IDAP-Link/M-2030417000017 : Blank checking...
    IDAP-Link/M-2030417000017 : Chip erased
    IDAP-Link/M-2030417000017 : Programming...
    IDAP-Link/M-2030417000017 : Programmed 512 KB in 80.589 sec at rate 6.353 KB/s
    IDAP-Link/M-2030417000017 : Application Firmware start address 0x23000
    IDAP-Link/M-2030417000017 : DFU start address 0x78000
    IDAP-Link/M-2030417000017 : Verifying...
    IDAP-Link/M-2030417000017 : Programming succeeded.

    Total programmed 1 nRF5x devices in 84.063 sec, 512 KB R/W transfered, rate = 6.091 KB/s

    ReplyDelete
    Replies
    1. Hi,
      There can be many explanations. The target swd signal lines could be weak, your pc could be busy with other tasks such as virus scans, Flashing big files would be slower than small files. At 6KB is quite slow. Most likely the weak SWD connection.

      Delete
  36. Hello,
    Can IDAP-Link be used with Segger IDE to debug nordic nrf52 chip? I was able to successfully flash programs onto custom board using IDAP-Link. Now I am trying to figure out how to debug. Thanks in advance.
    Regards,
    Anoop Joseph

    ReplyDelete
    Replies
    1. Hi,
      The Segger IDE only works with Segger products. It is a strip down version of CrossWorks. You use the IDAP-Link with CrossWorks and other IDE such as KEIL, Eclipse (OpenOCD),... Select CMSIS-DAP as JTag interface.
      Best,
      Hoan

      Delete
    2. Dear Hoan, Thank you for your quick reply.

      Delete
  37. Can your hardware run the Black Magic probe firmware?

    ReplyDelete
    Replies
    1. I haven't tried that. I guess if you do the port, it should work. The MCU on the IDAP is a Cortex-M0 with 64KB FALSH, 10KB RAM. Be aware that if you flash an other firmware on it you may not able to revert to the IDAP firmware. It is at your own risk all guarantees are voided. Send me private message if you wish to know the pin maps to do port.

      Delete
  38. Hello,

    I recently got an IDAP-Link rev4.1. I tried upgrading the firmware on it following these steps:

    1. push s1 and s2 together
    2. release s2 and hold s1 for 3 seconds
    3. inside volume 'CRP DISABLD' replace firmware.bin with R3_build_1_6_181013 firmware.bin
    4. unplug usb and plug it back in

    Now IDAP-Link seems to be bricked, it doesn't come up.

    What do I do ? Did I do something wrong ?

    ReplyDelete
    Replies
    1. You might have unplug too soon, before it has time to finish flashing firmware. You can re-try the steps and wait at least 3 sec before restarting the IDAP

      Delete
    2. How do you propose I restart IDAP, because I tried this again and waited for more than 2 minutes still nothing?

      Delete
    3. should I try a different build, currently I am trying "R3_build_1_6_181013" ? I work on a linux PC, are there any special instructions for linux ?

      Delete
    4. I think you misunderstood what I meant. Here are the steps.
      1 - Press and hold S1 (ISP) button
      2 - Press and release S2 (IRESET) while holding S1
      3 - Release S1
      4 - If you are using Windows, delete firmware.bin from 'CRP DISABLD' drive and copy over the new firmware.bin
      5 - Wait for 3 sec.
      6 - Press S1 again to restart IDAP.

      For Linux may be use the cp command from the Shell. I know that for OSX, cp command must be used.

      Delete
    5. I tried the exact steps you mentioned multiple times, but nothing's happening. Step-6(press S1 again) doesn't seem to do anything, volume still shows up as 'CRP DISABLED' and if I unplug and plug it back in LED-3 doesn't lit up and
      IDAP doesn't show up as USB device, however I still can go to 'CRP DISABLED' mode and repeat same steps but again nothing. I am stuck.

      Delete
    6. Could you try that on a window machine ? or may be the firmware.bin you downloaded was corrupted. Try to download again.

      Delete
    7. Thank you for your assistance. I was able to make it work using a windows machine. I am on to next step, that is, programming nrf51422. I keep getting this error 'No target device found', when I try programming softdevice using IDAPnRFProg. I can give more details on it like what connections I have made. I also have some doubts. Do you prefer to start a new conversation thread in nRF51/nRF52 post or can I keep asking here ?

      Thank you!

      Delete
    8. There are info for connecting nRF5x series to the IDAP on the nRF51/nRF52 page. If you still have issue, please post your related questions on that page.

      Delete
  39. I am trying to connect via J-Link from Segger embedded studio but I get an error message "No emulators connected via USB. Do you want to connect to a J-Link via TCP-IP instead?" I presumed you supported J-Link but from this message it appears you do not. What is true? Can I connect via J-Link?

    ReplyDelete
    Replies
    1. BTW target is NRF52 board but I cannot even "connect J-Link"
      Segger Studio free now so is good option.
      I can connect to standard NRF52 evaluation board this way but I wanted IDAP link so I could run my target at lower voltage.

      Delete
    2. The Segger Studio only works with J-Link. It does not support anything else. The IDAP-Link is a standard CMSIS-DAP JTag. It can be used with OpenOCD, Keil, Crosworks,... but not Segger Studio. Segger Studio is a downgrade version of CrossWorks. You can try CrossWorks or use Eclipse with OpenOCD. See my blog nRF51/nRF52 and Eclipse pages how to setup Eclipse. It is not that difficult.

      Delete
  40. Hi, very nice project but I didn't have any success programming my target.
    I have feather board from Adafruit (link attached) https://learn.adafruit.com/bluefruit-nrf52-feather-learning-guide
    connected 4 pins swclk, swdio, swo, and reset,
    Tried to drop generated by Arduino .hex file but the target is not getting updated, it tries to copy but then there is an error.
    Am I missing something? did someone had the same problem? please help






    ReplyDelete
    Replies
    1. Hi, the pin swo is not used. There are 2 pins missing. The VCC and the GND pins. VCC of your board should be connected to the TVref pin 1 of the IDAP-Link and GND to any GND pin on the IDAP

      Delete