⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads athttps://www.dialog-seminile.com/support.。我们将在未来几天修复错误/优化搜索和标记。
14 posts / 0 new
最后一篇
rahult.
Offline
最后一次露面:3 years 6 months ago
加入:2017-07-14 13:22
Using BT HCI over UART for DA14585

Hi,

We would like to know how to enable BT HCI over UART mode of DA14585. Are there any settings that need to be done ? We want to send the BT HCI command over UART directly to BLE controller and get back the response back. We want to use another Bluetooth stack and communicate with chip directly.

Thanks,
Rahul

Keywords:
设备:
mt_dialog.
Offline
最后一次露面:2 months 1 week ago
职员
加入:2015-06-08 11:34
嗨rahult,

嗨rahult,

In order for the 585 to operate under HCI mode, you will have to download the appropriate fw, you will be able to find the fw in the SDK 6.0.4 in the following directory DA14585_SDK\6.0.4.326\projects\target_apps\hci, then you will have to provide the RX/TX/RTS/CTS connections with the corresponding pins (that depends on the device you are using) and you will be able to send UART HCI commands directly to the 585 and get back the appropriate response.

谢谢mt_dialog.

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
嗨mt_dialog,

嗨mt_dialog,

Tried building the 'DA14585_SDK\6.0.4.326\projects\target_apps\hci' project and executed in the Debug Mode with selected target hci_585, but seeing the Hardfault. Tried finding out the issue, but couldn't root cause it. Kindly do the
细节:
1. DA14585_SDK -6.0.4.326
2.DA14585.Dev Kit Pro
3. J5 configured for UART, J10 is enabled, J3 is open.
4. SDK config files needed no changes post downloading the sdk.

调试详细信息:
Crash seen at: memcpy(hci_cmd_desc_root_tab, rom_hci_cmd_desc_root_tab, 48); in arch_rom.c
R14(LR):0xFFFFFFF9,
MSP:0x07FC35F8 - 其PC:0x07F1E0AC

Kindly let us know any configurations required to use DA14585 as BT HCI UART mode.

Thanks,
Nitish

MHv_Dialog
Offline
最后一次露面:2 months 1 week ago
职员
加入:2013-12-06 15:10
嗨nitish,

嗨nitish,

I just repeated your steps and have no issues as long as I am using mass production version of the DA14585. Trying to repeat with revision AB silicon, I am getting the exact same hardfault.

如果字母AB是SOC上的修订号标记的一部分(芯片标识符DA14585下面),则您有必须更换的早期硬件。有关如何安排更换的详细信息,请联系您当地的销售代表。MP硬件上的修订号是所有零。

/MHv

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
Hello MHv,

Hello MHv,

附加DA14585的图像,以及我们看到的修订号如下。不要以为它的ab硅。请告诉我们我们可以做些什么来实现这项工作。
如果你可以帮助我们尽快享受。
DA14585-01ATDB-P(1711_00015)。

Thanks,
Nitish

MHv_Dialog
Offline
最后一次露面:2 months 1 week ago
职员
加入:2013-12-06 15:10
Thanks for providing the

Thanks for providing the pictures. Your daughter card appears to be an early engineering sample. Please ask your Dialog distributor or representative for a board replacement.

/MHv

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
Thanks MHv,

Thanks MHv,
我们采购了新硅,现在我们没有看到硬断层。但看到一些其他问题。

1. Built the project DA14585_SDK\6.0.4.326\projects\target_apps\hci for 585, started the debug session and started executing the code(F5). I now think that firmware is downloaded to SRAM (through UART1 P0_4utx, P0_5urx, P0_6ucts, P0_7urts ) and started executing. Now stopped the debug session(which was using the uart1).
2.但现在我们认为UART1将用于the BT HCI interfacing (BT host and Dialog585 BT controller ). So, removed the jumpers in J5, connecting the UART P0_4-P0_7 with USB comm pins. And interfaced the UART P0_4-P0_7 with the controller running the BT host via UART interface. And see there is no proper communication happening.
3. When i monitored the standalone Dialog585 P0_4 & P0_5 pins post downloading and running the HCI firmware, through picoscope, see some random unexpected signals (attached the images).
笔记:
1. BT host set up runs fine with the other BT controllers over UART hci interface.
2.Both the Host and Dialog uart settings are fine. configured 115K2 baud, No parity, and tried with both enabling and disabling the HW flow control.

Kindly let us know if any other settings/uart configuration to be used to make it work.

Thanks,
Nitish

mh_dialog(未经验证)
嗨nitish,

嗨nitish,

我相信拆下跳线并连接到BT主机的程序可以触发DA14585复位。你可以尝试在开头和bt主机连接uart重复步骤1?JTAG(SWDIO和SWCLK)用于将代码下载到SRAM中,但在KEIL中。

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
Thanks MH_Dialog,

Thanks MH_Dialog,

I tried the following steps, but see there is no response/activity from the P0_5 [uRx] pin or other UART pins(P0_4, P0_6 or P0_7) of the DA14585.

脚步:
1. Built the project DA14585_SDK\6.0.4.326\projects\target_apps\hci for 585 using Keil.
2.现在使用“选择DA14585选项的JTAG配置”使用SmartSnippets工具箱,打开设备并选择“Booter”工具。
- 使用da14585 \ da14585_sdk \ 6.0.4.326 \ projects \ target_apps \ hci \ hci \ keil_5 \ out_585 \ hci_585.hex二进制使用keil生成的。
- Options was kept as it is. SysCtrlReg=0xA6 for 585
- 尝试使用启用和禁用“关闭调试会话”。
3.下载FW的发布成功。现在,不要看到UART端口P0_4-P0_7中的随机信号,但我也不看出任何响应(通过Pycope监视P0_4 UTX通过PicoSce)从主机发送的HCI RESET命令。

Kindly suggest.

Thanks,
Nitish

Booter Logs:
[INFO General @17-09-14 17:30:26] Firmware File C:\DiaSemi\SmartSnippetsStudio\Toolbox\common_resources\jtag_programmer_585.bin has been selected for downloading.
[INFO General @17-09-14 17:37:41] Could not measure total IR len. TDO is constant high.
[INFO General @17-09-14 17:37:41] Could not measure total IR len. TDO is constant high.
[信息概述@ 17-09-14 17:37:41]找到了带ID 0x0BB11477的SWD-DP
[INFO General @17-09-14 17:37:41] FPUnit: 4 code (BP) slots and 0 literal slots
[INFO General @17-09-14 17:37:41] Found Cortex-M0 r0p0, Little endian.
[信息常规@ 17-09-14 17:37:41]选择了BTLE设备。
[信息Booter @ 17-09-14 18:48:27]找到了带ID 0x0BB11477的SWD-DP
[info booter @ 17-09-14 18:48:27] FpUnit:4代码(BP)插槽和0个字幕插槽
[INFO Booter @17-09-14 18:48:27] Found Cortex-M0 r0p0, Little endian.
[INFO Booter @17-09-14 18:48:28] Successfully downloaded firmware file to the board.

mh_dialog(未经验证)
嗨nitish,

嗨nitish,

没有响应DA14585的可能原因。

1. Is there a XTAL 32K on the board ? if not, please define CFG_LP_CLK as LP_CLK_RCX20 because LP_CLK is used to wake up the chip.

2.if you have XTAL 32K, then please disable the sleep mode to see if there is any response. Change app_default_sleep_mode = ARCH_SLEEP_OFF;

3.如果步骤2工作,请恢复睡眠模式并定义CFG_EXTERNAL_WAKEUP

Please let me know if these recommendations fix the problems

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
Thanks MH_Dialog,

Thanks MH_Dialog,
通过禁用睡眠模式,UART通信工作正常。请在内联的评论中找到。

1. Is there a XTAL 32K on the board ? if not, please define CFG_LP_CLK as LP_CLK_RCX20 because LP_CLK is used to wake up the chip.
- [Nitish]根据DA14580 Dev Kit Pro文件,该DEV板对XTAL32K提供了支持。我通过将断点检查为XTAL32K来检查它来验证它。

In file: arch_system.c, init_pwr_and_clk_ble()
setbits16(sys_ctrl_reg,clk32_source,1);//选择xtal32k作为LP时钟

2.if you have XTAL 32K, then please disable the sleep mode to see if there is any response. Change app_default_sleep_mode = ARCH_SLEEP_OFF;
- [nitish]是的,现在DA585正在响应主机BT HCI命令。

3.如果步骤2工作,请恢复睡眠模式并定义CFG_EXTERNAL_WAKEUP
- [Nitish] Now even in sleep mode its working fine by enabling the external wakeup. But see following observation or performance issue.
With app_default_sleep_mode = ARCH_SLEEP_OFF; BT init happens within a second.
With app_default_sleep_mode = ARCH_SLEEP_ON && CFG_EXTERNAL_WAKEUP enabled, See that BT init takes 4-5 seconds. Not sure why DA585 is taking so much time to respond.
请告诉我们,如果可以解决任何事情以解决DA585可以解决此问题。

Regards,
Nitish.

mt_dialog.
Offline
最后一次露面:2 months 1 week ago
职员
加入:2015-06-08 11:34
Hi Nitish W,

Hi Nitish W,

我已经测试了HCI弗兰克-威廉姆斯(取决于反对figuration that you have regarding the flow control, no flow control/with flow control), as far as i can tell you dont need to define the CFG_EXTERNAL_WAKEUP unless you use an additional pin for waking up the device. Check that the HW_CONFIG is set to work with the pro dk and not and make sure that the terminal that you are issuing the HCI commands has the RTS/CTS flow control enabled. Tested on my side with the pro kit, the responses for the commands for getting the bd address and the reset command are proper and i dont see any delays between the command and the response. Also since the device is only working with the sleep deactivated i can assume that something is wrong with the flow control, so please make sure that you have enabled it from the terminal that you send the HCI commands.

谢谢mt_dialog.

nitish w.
Offline
最后一次露面:2 years 10 months ago
加入:2017-08-30 09:49
嗨支持团队,

嗨支持团队,

首先,我无法在网站上发布新询问。
Secondly, Am seeing a bug in BT firmware that am using on DA14585.

Issue: BLE Advertising Enable Command Fails post BLE Scanning is enabled(as per the BT spec, both adv & le scan can go simultaneously(by time sharing)).
脚步:
1. Built the project DA14585_SDK\6.0.4.326\projects\target_apps\hci for 585 using Keil. (Tried disabling and enabling Sleep mode app_default_sleep_mode)
2.现在使用“选择DA14585选项的JTAG配置”使用SmartSnippets工具箱,打开设备并选择“Booter”工具。
- 使用da14585 \ da14585_sdk \ 6.0.4.326 \ projects \ target_apps \ hci \ hci \ keil_5 \ out_585 \ hci_585.hex二进制使用keil生成的。
3.下载FW的发布成功。
4. Run my host stack over the DA585, then host app does the ble scan enable and then followed by ble advertising enable. But the advertising enable hci command(0x200a) fails with status 'cmd disallowed 0x0C'.
日志::
Nitish:: prepare_cmd: opcode=0x2008

Nitish:: prepare_cmd: opcode=0x2006

prepare_cmd: params[0]=0x40
prepare_cmd: params[1]=0x0
prepare_cmd: params[2]=0xa0
prepare_cmd: params[3]=0x0
prepare_cmd: params[4]=0x3
prepace_cmd:params [5] = 0x0
prepace_cmd:params [6] = 0x0
prepack_cmd:params [7] = 0x0
prepare_cmd: params[8]=0x0
prepace_cmd:params [9] = 0x0
prepack_cmd:params [10] = 0x0
prepare_cmd: params[11]=0x0
prepare_cmd: params[12]=0x0
prepare_cmd: params[13]=0x7
prepare_cmd: params[14]=0x0
nitish :: prepaser_cmd:opcode = 0x200a

prepace_cmd:params [0] = 0x1
CC_evt: opcode=0x2008, status=0x00

CC_evt: opcode=0x2006, status=0x00

cc_evt:opcode = 0x200a,status = 0x0c

但是当执行相同的adv启用命令而不发出ble scan enable命令时,它会成功。我认为这是问题的根本原因。请确认此问题并为我们分享此问题的修复。

笔记:
1.和相同的主机应用程序和堆栈在不同的BLE控制器上运行。并且已发布的命令是BT 5.0规范符合标准。
2.Attaching the hci commands and events sent & received to/from controller for reference.

Thanks,
Nitish

mt_dialog.
Offline
最后一次露面:2 months 1 week ago
职员
加入:2015-06-08 11:34
Hi Nitish W,

Hi Nitish W,

Regarding the fact that you are not able to post a new question, please open one of the three main categories on the support forum and there should be a black button indicating "New Topic" are you able to see that.

关于您的第二个问题,585的BLE堆栈不支持扫描和广告同时,当您连接时,您可以同时扫描或宣传但不同时宣传和扫描。所以在开始新的广告或扫描之前,您是否停止扫描或广告?

谢谢mt_dialog.