加载和运行DSPS HEX文件

17 posts / 0 new
Last post
Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
加载和运行DSPS HEX文件

大家好,

我刚收到一个DA14580基本演示套件,并有一些问题激活BT。

成功安装了Keil V5,并按照UM-B-048入门文档中所述进行闪烁测试。
Then tried to run the DSPS (DA14580_DSPS_3.150.2___13_2_2015), got the application note (v1.3) from my distributor.

然后遇到麻烦,当我试图遵循§8.4的步骤:

编译SPS_DEVICE项目:OK(0错误,3个警告)
连接FTDI RS232电缆,加上§8.1指示的常规USB电缆
启动调试会话时,会弹出“未找到Cortex-M个SW设备”
和日志:
加载“... \\ da14580_dsps_3.150.2 \\ dk_apps \\ keil_projects \\ sps \\ sps_device_k5 \\对象\\ sps_device.axf”
* JLink Info: Device "DA14580" selected.
将JLink项目文件设置为“... \ DA14580_DSPS_3.150.2 \ dk_apps \ keil_projects \ sps \ sps_device_k5 \ jlinksettings.ini”
* JLink Info: Device "DA14580" selected.

JLink info:
------------
DLL:v5.02f,编译2015年10月2日20:51:34
Firmware: J-Link OB-SAM3U128 V1 compiled Aug 28 2015 19:26:23
Hardware: V1.00
S/N : 480055335

Error: Flash Download failed - Target DLL has been cancelled
闪存负荷在10:39:47完成

问题:有些我没有找到的东西:
如果我在图14中更改跳线,则SAM和DA之间没有任何连接,因此如何通过串行链路而不是jlink下载的十六进制文件?或许我错过了什么?

所以我也试过SmartSnippets:
这次打开的COM端口是串行链路,但重置按钮没有效果!!

[信息@ 15-12-09 10:50:41]从文件中读取19480年字节... \ da14580_dsps_3.150.2 \ dk_apps \ keil_projects \ sps \ sps_device_k5 \ objects \ sps_device.hex。
[INFO @15-12-09 10:50:41] Connection to COM40 port has successfully opened.
[info @ 15-12-09 10:50:41]开始下载程序...
[动作@ 15-12-09 10:50:42]请按电路板上的硬件重置按钮开始下载过程。
[错误@ 15-12-09 10:50:57]超时:重置信号未检测到超过16000毫秒。
[信息@ 15-12-09 10:50:57]成功断开了COM40端口。
[信息@ 15-12-09 10:50:57]将固件文件下载到电路板上失败。

下一步是什么?我经历了多个论坛线程,发现了几个能够连接的客户,有些不是,但无法弄清楚右/差的条件。
BTW, I modified nothing in the original source code, and da14580_config.h defines CFG_UART_HW_FLOW_CTRL. Should I change that?

谢谢。

PS:
SmartSnippets v3.9 32b.
And Keil Info:
IDE版本:
μVisionv5.17.0.0
Copyright (C) 2015 ARM Ltd and ARM Germany GmbH. All rights reserved.

工具版号码:
Toolchain:MDK-Lite版本:5.17
Toolchain路径:C:\ Keil \ ARM \ ARMCC \ BIN
C Compiler: Armcc.exe V5.06 update 1 (build 61)
Assembler: Armasm.exe V5.06 update 1 (build 61)
Linker/Locator: ArmLink.exe V5.06 update 1 (build 61)
图书馆管理器:Armar.exe V5.06更新1(Build 61)
Hex Converter: FromElf.exe V5.06 update 1 (build 61)
CPU DLL:SARMCM3.dll v5.17
对话框DLL:darmcm1.dll v1.12.0.0
目标dll:segger \ jl2cm3.dll v2.99.16.0
对话框DLL:tarmcm1.dll v1.9.0.0

关键词:
设备:
mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

要通过JLink下载代码,您是否已配置目标选项 - >设置 - >调试 - >在JTAG选项中,此外,此外,请在使用外部工具进行闪存编程的实用程序中查看要选择的实用程序。无法将代码下载到DA的代码修改。最可能是UART连接。您可以尝试使用默认的UART跳线Donwload代码,以检查智能片段中的复位功能,也是Chek Choet Setup(PIN的配置)。

谢谢mt_dialog.

Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
Hi,

Hi,

Yes it is in SW mode, and I can see the SN in the window. And External tool is selected, with blank values (this trick was not obvious and tough to find, I previously had the issue while trying to run the blink example)
Unmodified code loaded.
在“快速入门指南”中,RX / TX跳线将在P0_4,P0_5和波特率上至115K,但在SmartSnippet,P0_4,P0_5点到57K。
在115K和57K中,我得到了虚假的流量(见附件),但在115K外部串行端子I中,我有一系列“[00] [00] [00] [00] [02]”在115K中

Good news, the reset button stops the flow
Definitively an UART issue, I believe. But where is my fault?
当跳线如DSPS应用笔记中指示时,我概述了SAM / DA链接的初始问题?

Thanks a lot.

Attachment:
mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

I suppose that you mean if you remove the jumpers that connect the TMS and the TCK (the basic configuretion oin figure 14), those are the jlink's connections. The version of the basic kit in the picture is a bit outdated. Just place those two jumpers and you will be able to program your board. The data you see in the terminal is the bootloader of the da running, in 57k. The da follows a specific procedure when booting from different interfaces including uart in different pins with different baud rates. Since you want to donwload the DSPS just place the TMS and TCK pins connect through jlink and connect the ftdi as indicated in the app note.

谢谢mt_dialog.

mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

我在使用DSP项目时附上了基本开发套件的图片和正确的配置。

FTDI电缆的线条和着色是DSPS应用笔记中描述的线条和着色。尝试使用keil下载项目。在“调试”选项卡 - >“设置”中,在项目选项中(如果基本套件被Keil正确识别),则应查看此(附图)。如果您没有得到SW设备IDcode和Name,请按Dev套件上的重置按钮,然后重试。之后,您必须能够在Dev套件中下载该软件。

谢谢mt_dialog.

Attachment:
Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
Hi,

Hi,
我花了一些时间继续在装备上。
有some differences found between the pictures you sent and the instructions I followed.
在驱动程序设置中,最大时钟在我的侧面而不是2。
In the UART pinout, CTS (brown) was on P0_3 as indicated in the "DA14580 Serial Port Service reference application_v1 3" but your snapshot says P0_7

我相应地更改了配置,结果没有变化。
请注意,由于我再次返回TMS TCK,因此我能够通过柔软的步骤启动和调试。实际上它看起来像是在启动阶段骑自行车,而不是广告。

Attachment:
mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

无效的FTDI连接在附件我已发送,有效是应用笔记中的一个(在运行示例时使用IO修改的代码)。

我猜软件卡在wher()中,在附件中,等待在调试器被禁用之前。

由于您有您的TMS和TCK,并且您能够在DA中下载代码,以便查看设备广告,因此您必须在进入睡眠模式时退出调试模式。如果您要在操作时调试您必须禁用睡眠模式,可以通过转到da14580_config.h和#undef cfg_ext_sleep来执行此操作。

谢谢mt_dialog.

Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
嗨MT,

嗨MT,
I didn't really want to debug it, I just wanted to know where it was stuck. When I undef CFG_EXT_SLEEP, the execution fails in a hardware fault due to the UART, apparently, and when I put it back (and don't debug) I still have no advertising.
我的配置或HW中肯定存在一些基本缺失,但我仔细遵循(纠正的)指令,并没有取得进展。

mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

即使没有任何UART连接,您应该能够在基本套件中的Donwload代码运行并运行并可正确宣传DSP项目。现在我可以考虑在硬盘处理程序中导致的唯一原因没有选择芯片的适当项目。在每个文件夹(设备/主机)中的DSP应用程序中,有两个.uvProj文件,一个用于不同的芯片。

sps_device.uvproj - >是580

sps_device_581.uvproj - >是581

If you open, compile and download the sps_device_581.uvproj into a 580 chip this will result to a Hardfault Handler and the otherway around of course.

谢谢mt_dialog.

Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
Hi,

Hi,
我实际上是14580的工具。我在这里的差异是Doc就是我正在运行UV5,如我的第一个帖子所说的(V5.17,Windows 7)所说
Any way to have a direct call? It's been a month since I started now...
谢谢。

mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

That sounds very weird, at least are you able to download and properly run any other example from the SDK and check if its advertising properly, the app_ble_barebone or the app_ble_peripheral from the new SDK. Can you please try that ?

谢谢mt_dialog.

Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
Tried ble_app_barebone in

Tried ble_app_barebone in Keil_5, worked seamlessly, no modification of any sort, just compile and go (selected Dialog/DA14580 component); it advertised.
所以它在设置的某个地方。对于DSP来说,我必须在UV5中打开和港口原来的UV4 Projet,是它失败的地方吗?

mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

我附上了一个。在我的基本套件上测试的DSP应用程序的.hex文件并用Keil5.14编译。请您可以使用智能代码段工具将文件下载到您的基本套件中,并告诉我您是否可以看到它广告。我还附上了目标选项 - >从keil4迁移到keil5时应该拥有的设备。

谢谢mt_dialog.

Attachment:
Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
ble_app_barebone之间

ble_app_barebone之间DSPS, scatterfiles are different, and ROM areas as well (attached). Should I change the ROM area, and what to? Once the startup radio button is selected, I can't unselect it.

mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

DSPS项目应按原样运行,您不必在源代码或ROM配置中更改或更改任何内容。您可能想要更改的唯一方法是拒绝CFG_EXT_SLEEP,以便在您处于调试模式时执行代码,否则您必须退出调试模式以查看IT广告。请尝试运行.hex文件只是为了进行简单的测试。此外,您还可以上传您的.hex文件或项目,以在我的基本套件上测试它。您可以在\ da14580_dsps_3.150.2 \ dk_apps \ keil_projects \ sps \ sps_device \ out目录中找到您.hex文件。

谢谢mt_dialog.

Offline
最后一次露面:10个月前1年
Joined:2015-12-08 16:57
Hi,

Hi,
你的.hex工作,而不是我的。

Attachment:
mt_dialog.
Offline
最后一次露面:2个月2周前
Staff
Joined:2015-06-08 11:34
嗨Chui,

嗨Chui,

In the file you have uploaded you haven't icluded your configuration files da14580_config.h, da14580_scatter_config.h, da14580_stack_config.h can you please upload those as well, i was able to complile and run the project with my configuration files. Also i was able to run the .hex you ve sent me, downloading it via UART, when downloading it via the JTAG you wont be able to see it advertising (it advertises only for a couple of seconds and then waits to detach the debugger - if you have your phone scanning while downloading the code you can pick up the first two seconds of advertising) because the debbuger stays attached to it since you have the CFG_EXT_SLEEP. In order to download firmware via uart you have to set the pins in the UART configuration (right next to the j4 header), open the smart snippets and select the UART (only) option, go to the booter and download th e.hex file. My project was able to run on your board because the sleep mode was undefined.

I have attached the files i ve used and your project as well, in order to test them you can place the folder as is under this directory DSPS\DA14580_DSPS_3.150.2___13_2_2015_keil5\DA14580_DSPS_3.150.2\dk_apps\keil_projects\sps compile and execute, i ve also included in the .zip file the produced sps_device.hex file from the project and your .hex file.

谢谢mt_dialog.

Attachment: