implement 10 characteristics

⚠️
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.
8个帖子/ 0新
Last post
Oz
Offline
Last seen:2年5个月前
Joined:2018-10-11 07:20
implement 10 characteristics

Hi,

我正在尝试向项目BLE_APP_PROFILE的服务CUST1添加3个特征。我的成功添加一个特征,当我写在文件training_02_custom_profile_example_v1.0中,但是当我做了完全相同的过程时添加更多特征(和项目编译的项目),项目中断函数wrap_platform_reset。为什么会发生这种情况?每项服务的特征数量有任何限制?

问候,

设备:
PM_Dialog
Offline
Last seen:1天7小时前
Staff
Joined:2018-02-08 11:03
嗨盎司,

嗨盎司,

The most obvious reason that the wrap_platform_reset() is occurred is due to memory allocation failure, which means that there is a memory leakage in your software, you allocate data somewhere and you never release them (you can verify that in the parameter error of the function, which should be RESET_MEM_ALLOC_FAIL). Selecting the optimal heap for your application, you should experiment with via changing the sizes of the heaps in the da1458x_config_advanced.h file.

Thanks, PM_Dialog

Oz
Offline
Last seen:2年5个月前
Joined:2018-10-11 07:20
嗨pm_dialog,

嗨pm_dialog,

Thank for your reply, I am not using any sleep mode so it seems that the following lines are defined:
#define REINIT_DESCRIPT_BUF 1//0 //0: keep in RetRAM, 1: re-init is required (set to 0 when Extended Sleep is used)
#define use_memory_map ext_sleep_setup.
并且可以仅针对CFG_MEM_MAP_DEEP_SLEEP模式定义堆。
here is what written in the commit in da1458x_config_advanced.h file:
If CFG_MEM_MAP_EXT_SLEEP or no sleep mode is selected the heap memory sizes are automatically configured
Do you have any suggestion to solve this issue?

in your reply, you mentioned that I can verify that in the parameter error of the function, which should be RESET_MEM_ALLOC_FAIL.
which function did you mean?

问候,
Oz

PM_Dialog
Offline
Last seen:1天7小时前
Staff
Joined:2018-02-08 11:03
嗨盎司,

嗨盎司,

在一个服务中添加更多特征,没有任何限制,例如,如果添加10个特征,则没有任何问题。添加任何服务/字符,内存从db_heap_sz分配。因此,Wrap_platform_Reset命中的原因是由于我之前的帖子中提到的内存分配导致的原因。尝试定义和增加DA1458x_config_advanced的db_heap_sz,例如,您可以放置​​2048的值。关于reset_mem_alloc_fail,请检查arch.h标题文件中wrap_platform_reset()函数的注释。

Thanks, PM_Dialog

Oz
Offline
Last seen:2年5个月前
Joined:2018-10-11 07:20
嗨pm_dialog,

嗨pm_dialog,

I did like you said and it works, but my next step is to create third service, so I did like written onhttps://support.dialog-semicondiondiondum/forums/post/dialog-smartbond-bl ...
我在本指南中添加了第二个服务,但当我用第三个服务时,我收到了以下消息错误。
我怀疑它发生在同样的原因中,因为当我在评论中将下一行放在评论中时:
{task_custs1,
custs1_att_db,
cust1_idx_nb,
#if(ble_app_present)
app_custs1_create_db,app_custs1_enable,
#别的
null,null,
#endif
custs1_init, NULL
},
in the cust_prf_funcs array it look that I can compile the code.
Can you please help me to figure out this issue or you have a better suggestion?

问候,
Oz

The mantioned error:
。\ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ ... \ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6406e:执行区域中没有空间.ANY选择器匹配CUSTS1.o(.constdata)。
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching custs2.o(.constdata).
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching app_diss_task.o(.constdata).
。\ .. \ .. \ .. \ .. \ .. \ .. \。\ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6406e:与执行区域没有空间.ANY选择器匹配CUSTS3.O(.constdata)。
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching user_profile.o(.constdata).
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching atts_task.obj(.constdata).
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching llc.obj(.constdata).
。\ .. \ .. \ .. \ .. \ .. \ .. \ ... \ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6406e:没有执行区域的空格.any选择器匹配gapc_task.obj(.constdata)。
。\ .. \ .. \ .. \ .. \ .. \。\ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6406e:匹配gpio.o(.constdata)的执行区域中没有空格。
。\ .. \ .. \ .. \ .. \ .. \ .. \。\ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6406e:与执行区域没有空间.Anany选择器匹配usercusts3_def.o(.conststring)。
。\ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ ... \ da1458x_catter_config.h:错误:l6406e:与执行区域中没有空间.ANY选择器匹配mvars.o(.data)。
。\ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ .. \ ... \ da1458x_catter_config.h:错误:l6406e:与执行区域中没有空间.ANY选择器匹配mvars.o(.data)。
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching jump_table.o(.text).
.\..\..\..\..\..\sdk\common_project_files\da1458x_scatter_config.h: Error: L6406E: No space in execution regions with .ANY selector matching command_def.o(.constdata).
。\ .. \ .. \ .. \ .. \ .. \ .. \ ... \ sdk \ common_project_files \ da1458x_catter_config.h:错误:l6407e:聚合大小0x84字节的部分无法拟合.ANY选择器。
Not enough information to produce a SYMDEFs file.
没有足够的信息来生成反馈文件。
Not enough information to list image symbols.
没有足够的信息来列出图像映射中的加载地址。
Finished: 4 information, 0 warning and 15 error messages.
“。\ out_580 \ ble_app_profile_580.axf” - 15个错误,1个警告。

PM_Dialog
Offline
Last seen:1天7小时前
Staff
Joined:2018-02-08 11:03
嗨盎司,

嗨盎司,

似乎从散射文件分配的空间还不够。您问题的可能解决方法是重新排列散点文件,以便能够执行更大的应用程序。我非常建议您阅读过去的论坛帖子,您可以找到适当的步骤,以便重新排列散点文件。请按以下链接:

https://support.dialog-semicondiondiondum/how-build-program-code-larger-32kb.

As it mentioned in this post, you could find more information regarding the scatterfile in the UM-B-011 document from our support portal. You are able to download this document from the links below:

https://support.dialog-seminile.com/resource/um-b-011-da14580-memory-map-and-scatter-file.

https://support.dialog-semiconductor.com/resource/um-b-011-da14580-memory-map-excel-tool

如果您还有其他问题,或者您的问题尚未修复,我建议尝试一下,并回复我。

Thanks, PM_Dialog

Oz
Offline
Last seen:2年5个月前
Joined:2018-10-11 07:20
嗨pm_dialog,

嗨pm_dialog,

Thank you for your reply, I changed the optimization level to 3 and now it seems that it working properly. is that a problem to work in so high optimization level?

问候,
Oz

PM_Dialog
Offline
Last seen:1天7小时前
Staff
Joined:2018-02-08 11:03
嗨盎司,

嗨盎司,

优化级别高,例如O0,分辨ase the size of the application, so the space allocated from the scatterfile might be enough. Glad that you figured your issue out. I would like to let you know that If you found any of the above answers useful please mark one of them as accepted.

Thanks, PM_Dialog