DA14580.Basic Kit SDK

15 posts / 0 new
最后一篇
kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
DA14580.Basic Kit SDK

Questions about the 580 DSPS peripheral mode FW code I would like to use as the starting point for our custom embedded software development.

As of right now, i would like to understand the mechanism of how Keil IDE or SmartSnippets which downloads the FW bit stream from the Host PC thru the USB connection to the MCU on the 580 to receive the bit stream and write to flash or load it into RAM. Upon power up, I believe the 580 will load the FW from Flash into RAM and starts execution. However, when the 580 has no FW currently resides in flash, I would think there should exist a piece of code that's running in RAM that will handle writing the incoming FW from SmartSnippets or Keil to flash or to RAM. This piece of code might be called ROM code kind of like the BIOS fw in the PC. Can you point me to the part of the code that handles flash or RAM upload interface? If i am totally off base, please educate me so i understand how this process works to help me in our custom development.

If there is a document that explains this process in details, that would be even better.

谢谢,
- khai

Device:
mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

You can have a look at the AN-B-001.pdf or the UM-B-012.pdf, those documents mention how the booting sequence works, where the code is downloaded and runs. The code that exists in the 580 and loads a external fw is called the primary bootloader (or just bootloader) and its located in the ROM memory area. The source code isn't available, but its functionallity is described in the AN-B-001 document, its an ammount of options for the 580 to download code via UART/SPI/I2C.

谢谢mt_dialog.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
Thank you for the timely

谢谢你的及时回应。这2个文档帮助我了解有关580启动过程如何工作的更多信息。

It's OK the ROM code isn't available, will the secondary bootloader as described in the UM-B-012.pdf doc available or other sample code that is close to its functionality for booting from flash.
也许我会尝试描述我的开发方案,您可以推荐如何完成。使用基本套件,我可以通过将代码加载到与keil的SRAM的代码直接调试FW,我也可以用SmartSnippets写入Flash。还有智能公司的写作,我目前没有需要使用的smartsnippet。

我们的定制板很简单。它由带有电话应用程序的BLE接口的前端接口中的580组成。580将从手机接收消息,并通过580内部UART总线将其发送到显示设备。

To debug the 580 application code, we will build an external debugger board (is there such a board exist on the market?) with the Atmel chip (not on the same board with the 580 due to size constraint). Basically separating the 580 basic kit into 2 boards.

所以看待这个HW设计,将有580个应用程序代码的闪存区域。连接到580 UART接口的显示芯片也具有它需要从并执行的FW代码。我们想要580个应用程序代码和显示FW码在相同的闪存中(我认为我们不需要OTP内存,除非有原因。)

我的开发序列的问题下面是:

1.通过上面的HW设计,我需要一种读/写闪光灯的机制,将580应用程序代码从Flash加载到SRAM。这是辅助引导程序的作业吗?但是使用辅助引导加载程序需要OTP板载。是辅助引导加载程序的源代码或类似的东西?

2.假设580现在已启动并从闪存运行启动,需要充当外部主机控制器到显示设备。它需要读取显示设备FW的闪光灯,并将其发送到UART到显示设备,因此它现在可以启动。

That is my approach to the booting sequence for our dev board at the moment. From what you can see, we need code to read/write Flash and dump it to SRAM as well as dump it on to the UART bus by the 580 CPU.

您的反馈和推荐很受欢迎......

谢谢,
- khai

mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

Yes the secondary bootloader can be found in the utilities folder in the SDK and its quite similar with the primary bootloader. Regarding the debugger module you can use a Segger Jlink Lite ARM debugger, the same debugger that the expert kit uses. Regarding your questions:

1)为了将FW从Flash加载到580 Sysram,您不需要辅助引导程序,只要您遵循SPI引导的默认引脚连接,主要将能够为您执行此操作。二级引导加载程序用于分配不同的引导引脚,打开闪光灯,以便将其关闭为低功耗,加载不同的图像(拟议功能等)。如上所述,SDK中的Utilities目录中可用辅助引导加载程序源代码。

2)如果显示芯片需要FW,我想580需要发送该FW,如果芯片无法直接从闪光灯下载,所以是您需要一个例程,580将读取闪存并发送它到uart上的显示。580将验证正常启动序列,之后它将充当显示器和闪光之间的中间人。

谢谢mt_dialog.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
是否有示例代码

是否有示例代码reading/writing from/to Flash?
谢谢,
- khai

mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

There is a driver for writing in the flash and there is also an example that interacts with the flash, the example is located in the SDK at the peripheral_examples projects in the spi directory. And also as mentioned previously there is the secondary_bootloader source code in the utilities directory. Please check the below SDK directories.

da1458x_sdk \ 5.0.4 \ utilities \ secondary_bootloader:辅助引导程序

DA1458x_SDK\5.0.4\projects\target_apps\peripheral_examples\spi : the spi flash example

谢谢mt_dialog.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
关于你的回答

关于你的回答question 1 above, If I understand correctly, I don't need the secondary bootloader to do what I need. The primary bootloader can do the job. Then my questions are:

1.主引导程序是否驻留在ROM中?如果是这样,我们必须在生产时手动将主引导加载程序加载到每个芯片的ROM上?或者在我们收到DA14580S进行生产时已经为我们完成了此过程?

2. Assuming the DA application FW resides in SPI Flash, where in external SPI Flash address does the primary loader read the FW from to download to SysRAM? Is it by default address 0? Is this starting address programmable?

谢谢,
- khai

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
跟进问题:

跟进问题:

1.外部PC应用程序如SmartSnippets的直接访问(读/写/擦除FW)到580外部闪光灯。我可以将Smartsnippet用于FW应用程序的闪存数据文件吗?它是否必须绑定到某种格式,以将此数据文件上传到Flash?

2. Once FW is on external Flash, ROM primary bootloader must need to know 2 piece of info: address and size of FW to load to SRAM. Does SmartSnippets have these information set somewhere in flash so ROM has a knowledge so it can load the FW to SRAM?

3.使用Flash中的数据文件,FW应用程序代码也需要知道数据存储在Flash中的地址和大小,以便它可以读取和消耗数据。

谢谢,
- khai

mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

1)主引导加载程序在ROM中刻录,加载器的功能实体在AN-B-001.PDF文档中描述,通常它为您提供了一些标准引脚,以便通过UART / SPI / I2C引导。启动加载程序会在启动设备时立即执行,因此您不必刻录引导加载程序,因为我已经提到它已有位于ROM中即可。

2) The bootloader when the procedure is flash related and the 580 executes as master it will access the address 0 of the flash memory, in the primary bootloader this is not programmable. All those info are documented in the .pdf i mentioned.

Regarding the follow up questions:

1)当指示智能片段连接到580时,为了对闪存进行编程,它会下载一个名为Flash_Programmer或JTAG_Programmer的小FW,该FW处理来自Smart代码段(擦除/刻录等)的所有命令。是的,您可以使用智能片段闪烁您的FW应用程序。关于格式问题,我不太明白,SS将采取.hex将它转换为.bin或者您可以直接放置.bin文件,该工具将刻录闪光灯。

2)请求e read the manual i ve indicated to see the procedure that the bootloader follows.

3)正如我所提到的,SPI模式中的580将从闪存中从地址0请求数据,并且闪光灯应开始发送图像。该图像必须是可引导的,这意味着它应该具有可启动标题和代码的长度 - 如果选择可启动选项,则由Smart Scippets测量和分配。因此,智能代码段另外做的是安装0x70 0x50标题,以指示图像可引导应用一些零填充并附加.bin文件的大小。

谢谢mt_dialog.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
让我澄清我的问题

让我澄清我的问题一点。

因此,DA在Address 0启动闪存中的闪存中加载FW,因此可以从Flash读取电源时的主装载机并将其写入Sysram。在Sysram中完全启动和运行时,自定义FW需要来自Flash的一些数据来执行其任务。这是我们打算写入的自定义FW中某些算法的输入数据。这是我之前关于数据文件的问题。我可以使用ss将数据文件上传到闪存,因为我的自定义fw被启动后消耗?此数据文件不是可引导图像。它只是FW算法中需要的一些数据。对于能够将此数据文件刻录到闪存,是否需要遵循一些格式,因此SS将识别它并能够将其刻录到闪存?

谢谢,
- khai

mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

是智能代码段能够将自定义数据刻录到闪光灯中,可以使用完全标题编程器甚至闪光灯刻录机,没有任何特定的格式,以便使用智能片段将数据刻录到闪光灯中。您可以通过将随机二进制文件刻录到DEV套件闪存的某些地址来测试此问题。

谢谢mt_dialog.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
I would like to learn how

I would like to learn how SmartSnippets uses flash_programmer or jtag_programmer to /write/erase flash. Do you have source code for them?

谢谢,
- khai

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
never mind. Found it.

never mind. Found it.

kqtrinh.
离线
最后一次露面:3 years 10 months ago
加入:2016-08-24 00:17
有应用笔记吗?

有关Flash_Programmer实用程序的谈话吗?

mt_dialog.
离线
最后一次露面:3个月4天前
职员
加入:2015-06-08 11:34
嗨kqtrinh,

嗨kqtrinh,

不,没有应用程序注意,记录JTAG_Programmer的函数。此FW是由智能代码段工具使用而不是代码参考。

Also please dont post a new question on an irrelevant topic, you can always create a new post.

谢谢mt_dialog.