I have the DA14583 IoT Sensor Development Kit and am able to program the part using SmartSnippets Toolbox. However, I am unable to debug with Keil. I get the following error message:
"No Cortex-M SW Device Found"
I downloaded the latest Segger J-Link software, but it did not help.
设备:

Hi terry.lim,
Most probably the issue you are facing is because the IoT is allready programmed and its sleeping, so the debugger isn't able to attach to the device, what you can do is to reset the device and within 2 seconds attach the debugger. The device is waiting for 2 seconds before going to sleep so this is a window that you can attach the debugger. Or you can connect to the Smart Snippets Tool, connect and then erase the flash, that way the device will just run the bootloader and will have the debugger module always open for you to attach. Also make sure that the device is visible via keil, go to the "Options for Target" in the "Debug" tab, hit the "Settings" button and make sure that the "Port" filed is switched to SW and not JTAG and that you are able to see a SN of the Jlink and the IDCODE of the ARM attached.
Thanks MT_dialog
谢谢你的解释,这很有帮助。我删除了闪光灯,现在J-Link指挥官应用程序可以检测到Cortex-M0。而且,在Keil中,IDCODE的名称也会显示出来。然而,我现在面临一个新的问题。当我尝试启动调试会话时,会弹出“Cannot Access Memory”(无法访问内存)窗口,一些调试窗口会短暂出现,然后消失。
Hi terry.lim,
在下载到设备之前,你是否构建了这个项目。您将能够在下面的文档UM-B-048《开发工具包入门》第4段中找到一些关于Keil工具的指导(该文档描述了如何调试Blinky演示代码,因此忽略文档指示的设置和文件路径,设置应准备好直接从RAM运行IoT代码)。因此,打开项目,点击“Build”按钮,项目将编译,然后点击“Start/Stop Debug Session”。您确定没有更改keil中项目的默认设置吗?您是否尝试过从SDK(为583设备构建)运行任何其他项目?
Thanks MT_dialog
I am able to build and debug the "Blinky" demo program from the latest SDK without issues. I extracted a clean version of the IoT project and built and tried to debug, but get the same "Cannot Access Memory" pop-up. I am using the 32kb limited version of Keil, but the wrbl_raw project is less than that limit.
I assume the project settings would be the correct values to debug on the IoT dongle. I checked against the UM-B-048 document (even though it seems to be for different development kits) and everything seems to be correct.
Hi terry.lim,
这不是一个问题,我的意思是使用keil的评估版本,是的,所有的项目都进行了正确的配置(从keil的角度来看),以便直接在没有额外配置的工具包上运行。你试过重新下载这个项目吗?可能是下载过程中出了问题,或者是由于keil安装或版本的原因?因为我不熟悉那个具体的错误,而且我也无法复制它。使用Keil 5.22。
Thanks MT_dialog
Hi Terry,
您能否查看用户手册,特别是第4.1节,了解如何将物联网传感器套件连接到CIB?
https://support.dialog-semiconductor.com/system/files/restricted/UM-B-06...
如果这个问题没有解决,你能确保在你的项目设置下(右键点击项目,进入选项->调试->JLink设置),确保这个设置是SW而不是Standard JTAG。
/JK公司
I am pretty sure I did all that already, but when I have a chance I will try again.
我在物联网套件方面也面临同样的问题。
希望可以在这里发布这个非常相关的问题。让我知道我是否应该打开一个新的线程。
I am running Keil µVision V5.24.2.0 with the IoT firmware DA1458x_IOT\v5.160.1.19.
请找到附件的配置截图。
如果我设置“Use Target Driver for Flash Programming”日志
加载“D:\\GME\\Downloads\\Dialog\\DA1458x\u IOT\\v5.160.1.19\\projects\\target\u apps\\wrbl\\wrbl\u sfl\\Keil\u 5\\out\u 583\\wrbl\u sfl\u 583.axf”
将JLink项目文件设置为“D:\GME\Downloads\Dialog\DA1458x\u IOT\v5.160.1.19\projects\target\u apps\wrbl\wrbl\u sfl\Keil\u 5”\JLinkSettings.ini文件"
*JLink信息:已选择设备“CORTEX-M0”。
JLink info:
------------
DLL:V6.16c,编译时间:2017年6月16日18:14:49
Firmware: J-Link OB-SAM3U128 V3 compiled Jun 13 2017 10:37:47
Hardware: V3.00
S/N : 483014303
Feature(s) : RDI
*JLink信息:找到ID为0x0BB11477的SW-DP
* JLink Info: Scanning APs, stopping at first AHB-AP found.
*JLink信息:AP[0]IDR:0x04770021(AHB-AP)
*JLink信息:AHB-AP ROM:0xE00FF000(基本地址。(第一个ROM表)
*JLink信息:CPUID reg:0x410CC200。实现者代码:0x41(ARM)
* JLink Info: Found Cortex-M0 r0p0, Little endian.
* JLink Info: FPUnit: 4 code (BP) slots and 0 literal slots
* JLink Info: CoreSight components:
*链接信息:ROMTbl[0]@E00FF000
* JLink Info: ROMTbl[0][0]: E000E000, CID: B105E00D, PID: 000BB008 SCS
*链接信息:ROMTbl[0][1]:E0001000,CID:B105E00D,PID:000BB00A DWT
*链接信息:ROMTbl[0][2]:E0002000,CID:B105E00D,PID:000BB00B FPB
ROMTableAddr = 0xE00FF000
* JLink Info: Setting AIRCR.SYSRESETREQ
目标信息:
------------
设备:ARMCM0
V目标=3.300V
引脚状态:
TCK: 0, TDI: 1, TDO: 1, TMS: 1, TRES: 1, TRST: 1
Hardware-Breakpoints: 4
Software-Breakpoints: 8192
Watchpoints: 2
JTAG速度:1000 kHz
No Algorithm found for: 00000000H - 0000009FH
No Algorithm found for: 00000160H - 00000323H
找不到算法:00000340H-000003E3H
No Algorithm found for: 00000440H - 000080EBH
编程跳过!
Error: Flash Download failed - "Cortex-M0"
Flash Load finished at 11:08:06
If I set "Use External Tool for Flash Programming" the error message is the same as for the OP who mentioned
当我尝试启动调试会话时,会弹出“Cannot Access Memory”(无法访问内存)窗口,一些调试窗口会短暂出现,然后消失。
我能够快速复制调试输出中显示的内容:
Running with Code Size Limit: 32K
将JLink项目文件设置为“D:\GME\Downloads\Dialog\DA1458x\u IOT\v5.160.1.19\projects\target\u apps\wrbl\wrbl\u sfl\Keil\u 5”\JLinkSettings.ini文件"*JLink信息:已选择设备“CORTEX-M0”。
JLink info:
------------
DLL:V6.16c,编译时间:2017年6月16日18:14:49
Firmware: J-Link OB-SAM3U128 V3 compiled Jun 13 2017 10:37:47
Hardware: V3.00
S/N : 483014303
Feature(s) : RDI
*JLink信息:找到ID为0x0BB11477的SW-DP
* JLink Info: Scanning APs, stopping at first AHB-AP found.
*JLink信息:AP[0]IDR:0x04770021(AHB-AP)
*JLink信息:AHB-AP ROM:0xE00FF000(基本地址。(第一个ROM表)
*JLink信息:CPUID reg:0x410CC200。实现者代码:0x41(ARM)
* JLink Info: Found Cortex-M0 r0p0, Little endian.
* JLink Info: FPUnit: 4 code (BP) slots and 0 literal slots
* JLink Info: CoreSight components:
*链接信息:ROMTbl[0]@E00FF000
* JLink Info: ROMTbl[0][0]: E000E000, CID: B105E00D, PID: 000BB008 SCS
*链接信息:ROMTbl[0][1]:E0001000,CID:B105E00D,PID:000BB00A DWT
*链接信息:ROMTbl[0][2]:E0002000,CID:B105E00D,PID:000BB00B FPB
ROMTableAddr = 0xE00FF000
* JLink Info: Setting AIRCR.SYSRESETREQ
目标信息:
------------
设备:ARMCM0
V目标=3.300V
引脚状态:TCK:0、TDI:1、TDO:1、TMS:1、TRES:1、TRST:1
Hardware-Breakpoints: 4
Software-Breakpoints: 8192
Watchpoints: 2
JTAG速度:1000 kHz
加载“D:\\GME\\Downloads\\Dialog\\DA1458x\u IOT\\v5.160.1.19\\projects\\target\u apps\\wrbl\\wrbl\u sfl\\Keil\u 5\\out\u 583\\wrbl\u sfl\u 583.axf”
* * * 32768字节码尺寸L限制版本imit
*** Currently used: 32692 Bytes (99%)
无法访问内存
***错误57:非法地址(0x00000160)
Include "D:\\GME\\Downloads\\Dialog\\DA1458x_IOT\\v5.160.1.19\\projects\\target_apps\\wrbl\\wrbl_sfl\\Keil_5\\..\\..\\..\\..\\..\\sdk_580\\sdk\\common_project_files\\misc\\sysram_0x0.ini"
RESET
E长0x50000012=0xa6
__^
*** error 121, line 2: AGDI: cannot access target while executing
E长0x50003308=0x2e
__^
*** error 121, line 3: AGDI: cannot access target while executing
LOAD %L
* * * 32768字节码尺寸L限制版本imit
*** Currently used: 32692 Bytes (99%)
***错误57:非法地址(0x00000160)
SP=\RDWORD(0x00000000)//用于基址0x00000000
_____^
***错误121,第6行:AGDI:执行时无法访问目标
$ = _RDWORD (0x00000004)
____^
***错误121,第7行:AGDI:执行时无法访问目标
您好,请参阅所附的工作配置截图。
The two main differences I see in my project versus yours, is that I have load application at startup unchecked - and in utilities Use External Tool for Flash Programming (with nothing empty arguments).
Please see uploads.