在extent_template_ext项目中发送Create_DB消息时未收到的回复

了解更多FAQsTutorials

18个帖子/ 0新
Last post
Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
在extent_template_ext项目中发送Create_DB消息时未收到的回复

Hi,

我正在尝试修改empty_template_ext项目以使用cust1配置文件。我在user_custs1_def.h / .c文件中添加了我的特征详细信息,并在user_profiles_config.h中包含“custs1.h”

当我发送消息以创建CUST1 DB时,我没有收到任何回复。我附上了从主机发送和接收的邮件的屏幕截图(这是一个修改的host_proxr项目的版本)。

我通过修改Prox_Reporter_ext项目来测试特征的工作,这已按预期工作。

I'm unable to find the function which handles the UART messages on the DA14580. Is there any way to debug this function?

谢谢,

关键词:
Attachment:
设备:
PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

我道歉,但对我来说也不清楚问题是什么问题。你能澄清你的问题吗?

如果我理解正确,您想通过UART打印调试消息?如果是,请尝试使用ARCH_PRINTF()函数。查看da1458x_config_basic.h标题文件中的cfg_printf宏。

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
No, I'm not trying to print

No, I'm not trying to print debug messages.

我正在尝试使用extent_template_ext项目使用custs1配置文件。当我向DA14580发送CUSTS1_CREATE_DB_REQ消息时,我没有收到它的任何回复。

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

我的道歉 - 这是我身边的误解。让我检查一下,我会回复你..

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
Hi PM_dialog,

Hi PM_dialog,

Any update on this issue?

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

请在调试模式下运行它,并将中断Porin添加到App_custs1_create_db()函数中?它是否正确执行,或代码被困?

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

我正在使用外部UART模板,所以我相信APP_CUSTS1_CREATE_DB()不会在外部项目中调用。我确实在Custs1_create_db_req_handler()中放置了一个断点,但代码永远不会达到此断点

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
Hi PM_dialog,

Hi PM_dialog,

Any update on this issue?

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

我的推荐将是按照PXP_Reporter_ext遵循自定义配置文件。在PXP_Reporter_ext项目中,您可以遵循邻近监视器和光盘配置文件的方式。然后,您应该在调试模式下运行它,尝试发送以发送相应的命令,通过UART发送并检查App_custs1_create_db()。请在那里添加一个断点并检查该功能是否触发。

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

You have mentioned pxp_reporter_ext project but I couldn't find such a project under the target_apps folder. I take it that you meant the prox_reporter_ext project. I have a modified version of it where I have added the cust1 task and it works perfectly for prototyping. I don't have any issues in creating the db or connectiong to a device or sending data, it works as expected. But this is only for the prox_reporter_ext project.

But now I would like to make a project for production code and that's why I used empty_template_ext.

And as I have mentioned in one of my older comments, since this is an external program, is it required for app_custs1_create_db() to be called?? Because in user_custs_config.c when BLE_APP_PRESENT is 0 (which I believe is the case for external), app_custs1_create_db and app_custs1_enable are replaced by NULL and NULL. And the prox_reporter_ext project didn't have a definition for it.

谢谢

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

Any progress on this issue? I'm close to my deadlines and it would be great if this can be solved soon

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

我的道歉 - 它是一个错字,我的意思是SDK的Prox_Reporter_ext项目。

Let me ask you some questions in order to understand the steps that you have already done :

In case of prox_reporter_ext project, the custom 1 profile is not included – only the proximity Monitor and the DISC profiles are enabled.

为此,您修改了Pro_reporter_ext项目并添加了自定义1配置文件。

在此步骤中,如果我正确地理解没有任何问题 - App_custs1_create_db()正确执行。

Did you add a break point to verify it?

So, in case of empty_template_ext, you have followed exactly the same steps in order to include the custom1 profile. Is that correct?

However, the app_custs1_create_db() is never executed – (this is the problem). Please correct me if it is anything wrong.

您可以在调试模式下运行empty_template_ext项目,并在该功能中添加一个断点吗?行为是什么?断点是否命中,或固件是否会堆栈任何地方(WDOG,NMI,任何断言等)?

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

以下是您提出的问题的答案

Q : " the app_custs1_create_db() is executed correctly. Did you add a break point to verify it?"

Ans: On my proxr_reporter_ext, I am able to connect to it and view the profile. So I believe the DB creation is occuring.

About if app_custs1_create_db is executed, I had tried it sometime ago and it did not hit the breakpoint. I will verify it again tomorrow and get back to you on that.

此外,如果我正确地理解了以下代码Snipppet,则不应该调用APP_CUSTS1_CREATE_DB以用于EXT项目。

const struct cust_prf_func_callbacks cust_prf_funcs [] = {#if(ble_custom1_server){task_custs1,custs1_d_db,cust1_idx_nb,#if(ble_app_present)app_custs1_create_db,app_custs1_db,#else null,null,#endif custs1_init,null},#endif #if(ble_custom2_server){task_custs2,null,0,#if(ble_app_present)app_custs2_create_db,app_custs2_enable,#else null,null,#endif custs2_init,null},#endif {task_none,null,0,null,null,null,null},//不要移动。必须始终持续};

I believe that BLE_APP_PRESENT is 0 for external projects.

Q: "in case of empty_template_ext, you have followed exactly the same steps in order to include the custom1 profile. Is that correct?"

Ans: Yes, I have followed the same steps

问:“但是,从未执行app_custs1_create_db() - (这是问题)”

ANS:我相信它没有执行,我不确定是否应该为外部项目执行。

I'll place breakpoints in the function and check for assertions and confirm the behaviour tomorrrow. Please do let me know if app_custs1_create_db is supposed to be called for ext projects

谢谢

编辑:我无法在我的项目文件夹中找到app_custs1_create_db。这个功能是否存在于DA14580或Master MCU的代码上?

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

Just to summarize : In case of prox_reporter_ext, did you add a BKPT into the app_custs1_create_db() ? Can you please indicate if the app_custs1_create_db() is getting triggered?

如果是,您是否可以将相同的empty_template_ext()验证吗?

我假设应该调用app_custs1_create_db()。是否有可能与您所做的修改分享两个项目?

谢谢,PM_Dialog

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
Hi PM_dialog,

Hi PM_dialog,

对不起,the delay in replying. I got confused and was checking the target project for the definition of app_custs1_create_db. app_custs1_create_db is being called in the host project when I ran it with empty_template_ext.

我明天会分享项目

谢谢

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

我正在将链接连接到Proxr_reporter_ext和empty_template_ext和主机Windows Proxr项目的2个目标项目。

https://drive.google.com/file/d/1LUbIPkL4PQhfg8T8tT-a_YadCQJolqZm/view?u...

I couldn't upload them as it exceeded the size limit.

谢谢

Tsgowtham.
Offline
Last seen:2周6天前
加入:2020-05-04 12:39
嗨pm_dialog,

嗨pm_dialog,

你能尝试我分享的项目吗?对此有任何更新?

谢谢

PM_Dialog
Offline
Last seen:6 hours 1 min ago
Staff
加入:2018-02-08 11:03
Hi tsgowtham,

Hi tsgowtham,

Apologies for my late response. Just run your projects, so find below my comments :

In case of prox_reporter_ext, the project is running properly ( as you have already mentioned ) – the device starts advertising - I can connect and see the PROXR, DISS , SPOTAR and CUSTS1 profiles. I am running both \binaries\host\windows\proximity\reporter\host_proxr_sdk.exe and your provided application.

In case of empty_template_ext, the device cannot start advertising neither with the usage of SDK host_proxr_sdk.exe nor your provided Windows application.

Can you please check in your side if it is starts advertising?

如果您在user_profiles_config.h中注释出以下内容,则可以在prox_reporter_ext中复制这一点:

#include "proxr.h"

#include "diss.h"

#include "spotar.h"

This is expected because the host_proxr_sdk.exe send GTL commands for the creation of the aforementioned profiles too. If you include all the above profiles in your provided empty_template_ext project, you will see that the device will start advertising and the Custom 1 profile is also included.

如果您有兴趣仅包括自定义1个配置文件,那么您应该自己修改host_proxr_sdk.exe,只能为特定配置文件发送GTL命令。这不是一个直接的执行,因为您应该删除许多GTL命令。例如,您可以在UART信号上使用逻辑分析器并检查您应该发送的命令。为此,我的建议将在Prox_reporter_ext上基于您的项目。

谢谢,PM_Dialog