Programming the DA14531 TINY with STM32/Arduino

⚠️
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 at//www.wsdof.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
13个职位/0个新职位
Last post
西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
Programming the DA14531 TINY with STM32/Arduino

你好:)

I just discovered both the product and this company, and it looks very promising! I have a project/product which needs bluetooth and I decided to go with the DA14531 TINY instead of the ESP32 :) Thank you for the opportunity, and looking forward to using the product!

我买了这个小模块,但我想知道是否有一个简单的方法来编程它(在SWDF.x上),使用Arduino或STM32。例如,我有许多STM32程序员,他们也使用SWD,那么我在寻找一个现成的代码/二进制文件,我可以上传到arduino或STM32上,然后它将与我的计算机上的IDE(或任何软件)通信来编程模块?

谢谢您!

Simon

PM\U对话框
Offline
最后一次见到:3天18小时前
Staff
加入:2018-02-08 11:03
Hi simonlasnier,

Hi simonlasnier,

Thanks for your question and for posting on our public BLE forums. Would it be possible to share a high level of your application? Are you planning to use the TINY module as the basic microcontroller, or use together with another MCU?

为了对模块进行编程,您可以使用JTAG或1线UART接口(P0\ U 5)。对于JTAG,您可以使用我们的任何开发板或任何外部JTAG接口。如果是1线UART接口(P0\ U 5),则应重置DA14531。这可以通过向模块循环供电或使用RST输入(高电平有效)来实现。

特别是对于小的,你也可以使用Dialog Smartbond Flash Programmer for Windows OS以便对模块SPI闪存编程。

在TINY module and DA14531 product页面中,您将找到开始使用Dialog产品所需的所有可用文档软件示例和硬件辅助资料。雷电竞官网登录

还有一些参考设计可以帮助您减少开发阶段,因为您不需要花费太多时间来开发应用程序代码。

//www.wsdof.com/雷电竞官网登录products/connectivity/bluetooth-low-energy/products/da14531

//www.wsdof.com/雷电竞官网登录products/bluetooth-module-da14531-smartbond-tiny

无代码的

The CodeLess allows you to quickly get started with wireless IoT applications with a set of AT Commands. The CodeLess AT commands platform allows control over a local UART connected device as well as a remote device via BLE. You can create simple demos / applications / proof of concepts without any code development or build you own application on top!

//www.wsdof.com/products/smartbond-codeless-commands

Dialog Serial Port Service (DSPS)

The DSPS emulates a serial cable communication. It provides a simple substitute for RS-232 connections, including the familiar software flow control logic via Bluetooth low energy. The SPS software distribution includes the application and profile source codes and supports GAP Central/Peripheral roles.

//www.wsdof.com/雷电竞官网登录products/dialog-serial-port-service-dsps

由于您对我们的产品还不熟悉,因此建议您开始使用以下文档雷电竞官网登录:

http://lpccs-docs.dialog-semiconductor.com/Tutorial_SDK6/index.html

http://lpccs-docs.dialog-semiconductor.com/UM-B-117-DA14531-Getting-Started-With-The-Pro-Development-Kit/index.html

http://lpccs-docs.dialog-semiconductor.com/UM-B-119_DA14585-DA14531_SW_Platform_Reference/index.html

谢谢,下午好

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
Thank you very much for the

非常感谢您的快速回复-这是非常好的信息!:)

应用程序将主要在STM32 MCU上运行,因此该模块将仅用作蓝牙模块。我还没有决定他们将使用什么样的通信通道,但两个单片机都有很多的可能性(I2C,SPI,UART),所以它真的应该不会有任何问题。此外,一旦进入市场,我的产品将有一种方法来升级其固件(即STM32的闪存),我想确保同时升级DA14531的固件也是可能的。

我对JTAG/SWD的了解非常有限-我认为它们是不同的东西,但似乎我错了-通过数据表我可以看到这两个术语可以互换使用。所以我猜你是说我可以简单地使用我的ST/Link V2,并把SWDIO和SWCK引脚连接到模块上的正确引脚-这太好了!D级

你知道什么固件是加载在模块时,它是新的(我买的Digikey)?

Thank you again for the links, I will go through them all.

PM\U对话框
Offline
最后一次见到:3天18小时前
Staff
加入:2018-02-08 11:03
Hi simonlasnier,

Hi simonlasnier,

You could connect the module with the other MCY over UART (UTX/URX/RTS/CTS), so that you can easily use CodeLess or DSPS! Software Update Over The Air (SUOTA) is available on DA14531 too. Regarding your last question, the DA14531 modules come without any pre0installed firmware, so you should program them in your side.

谢谢,下午好

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
Ok thank you.

Ok thank you.

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
又来了!

又来了!

我知道这是非常具体的,但ST链接V2是不承认所有提供的工具(f.x.的Smartbond闪存程序员)。正如我所说的,我对JTAG和SWD的了解是非常有限的,但是我猜它不属于“任何JTAG程序员”的范畴?

我会继续努力让它工作,但我想我可能不是唯一一个在这种情况下,本土的支持将真的非常感谢:)

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
Ok this is interesting -

Ok this is interesting - following the blinky example (http://lpccs-docs.dialog-semiconductor.com/UM-B-117-DA14531-Getting-Started-With-The-Pro-Development-Kit/06_Your_First_DA145x_Applications/Your_First_DA145x_Applications.html#),但是在Keil“Options for Target”中选择ST-Link而不是J-Link,我成功地在芯片上以调试模式执行了一些代码!blinky代码在RAM中运行,效果很好。

This works as the Keil software supports communication with the ST-Link and then communicates with the ARM Cortex chip like any other chip I suppose. But when t comes to writing a hex/binary file to the SPI Flash I have to use the Dialog tools, and none of them detect the ST-Link. Is there any way to upload the code to the SPI Flash directly from Keil uVision?

FYI I am attaching my configuration in Keil uVision for those who have the same issue.

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
或者,CMSIS

或者,CMSIS-DAP interface instead of a J-Link interface work with the tools provided by Dialog?

PM\U对话框
Offline
最后一次见到:3天18小时前
Staff
加入:2018-02-08 11:03
Hi Simon,

Hi Simon,

谢谢你的问题-让我内部检查一下。

谢谢,下午好

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
Ok great thanks. Just FYI it

好的,太好了,谢谢。仅供参考似乎Keil-uVision有一种方法可以使用ST-Link上传到SPI,ST-Link调试器的“设置”窗口有一个“Flash Download”选项卡,这似乎是前进的方向。我只是不知道该放什么:/

PM\U对话框
Offline
最后一次见到:3天18小时前
Staff
加入:2018-02-08 11:03
Hi simonlasnier,

Hi simonlasnier,

I saw your attached screenshot and I assume that you are trying to program the SPI flash. Please correct me if I am mistaken. In that case, we provide a tool named SmartSnippets Toolbox. You will find it under “Development Tools” section in the DA14531 product page.

//www.wsdof.com/雷电竞官网登录products/connectivity/bluetooth-low-energy/products/da14531

如果您使用的是keilide,那么只能将fw下载到系统RAM中。

谢谢,下午好

西蒙拉斯尼尔
Offline
最后一次见到:8 months 2 weeks ago
加入:2020-07-20 10:37
谢谢你的回复,但是

谢谢你的回复,但是yes I already know about the SmartSnippets Toolbox - the tool does not work with ST/Link, only with your programmers and Segger's. It would be really nice in the future if you could add ST/Link to your tools - Segger tools cost a fortune while you can get a "copy" ST/Link from ebay for a few bucks.

就我而言我觉得没有多大关系apart from buying one of your boards og a Segger Jlink :/

PM\U对话框
Offline
最后一次见到:3天18小时前
Staff
加入:2018-02-08 11:03
Hi simonlasnier,

Hi simonlasnier,

Thanks for your suggestion and let the Team know.

谢谢,下午好