27 posts / 0 new
Last post
katya
Offline
Last seen:6 years 9 months ago
Joined:2014-08-14 09:13
GAP Role Combinations

Hi,

GAPM_SET_DEV_CONFIG_CMD takes Device Role as parameter.
Will it work if I try to set a combination of roles, such as:
Broadcaster + Observer (0x03)
Peripheral + Observer (0x0B)

提前致谢。

FvD_Dialog
Offline
Last seen:1 month 1 week ago
Staff
Joined:2013-12-05 14:41
Dear Katya,

Dear Katya,

我们正在验证DA14580的多角色方案,但这尚未使用。

Kind regards,

坦率

katya
Offline
Last seen:6 years 9 months ago
Joined:2014-08-14 09:13
嗨弗兰克,

嗨弗兰克,

谢谢a lot for your response.

If concurrent multi-role scenarios are not available yet, can I switch roles in runtime multiple times? I.e. set Broadcaster, then Observer, then again Broadcaster and so on multiple times? Or the same with Peripheral and Central (assuming there are no active connections when GAPM_SET_DEV_CONFIG_CMD is invoked)?

谢谢in advance,
Katya

MHv_Dialog
Offline
Last seen:2months 4 weeks ago
Staff
Joined:2013-12-06 15:10
Hi Katya,

Hi Katya,

Yes, you can change the roles during runtime. Switching from central to peripheral would require that you disconnect from all peripherals first. And likewise when you change from peripheral to central; disconnect from central first.

You can broadcast advertise even while connected. this works in both central and peripheral role.

karl.taubinger
Offline
Last seen:5 years 5 months ago
Joined:2015-11-18 22:59
Hi,

Hi,

Has concurrent GAP Roles been implemented and/or verified yet?

We have a need for these 2 gap role use cases:
GAP_CENTRAL_MST + GAP_BROADCASTER_ADV
GAP_PERIPHERAL_SLV + GAP_OBSERVER_SCA

谢谢
Karl

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
Hi karl,

Hi karl,

The 580 does not support this kind of feature only the switching role can be implemented at the moment.

谢谢MT_dialog

tamisoft
Offline
Last seen:3 years 9 months ago
Joined:2016-01-07 21:21
抱歉ping,有没有

抱歉ping,有没有progress on this-now a few years later? Is it supported in SDK5.0.4 already?

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Tamisoft,

嗨Tamisoft,

No, the stack remains the same, only the swicting of the roles is supported.

谢谢MT_dialog

tamisoft
Offline
Last seen:3 years 9 months ago
Joined:2016-01-07 21:21
谢谢,有一个例子

谢谢,有一个例子是如何在飞行切换方面做的吗?在设备是外设广播时,我们需要定期扫描。显然我们可以停止广告,但暂时改变角色的正确步骤是什么。

谢谢

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Tamisoft,

嗨Tamisoft,

毫无示例才能证明,但程序是非常直观的,您必须发出GapM_RESET,然后将设备重新配置为中心,并且将其配置为外设。你可以看看以下帖子https://support.dialog-semicondiondiondum/forums/post/dialog-smartbond-bl ...

谢谢MT_dialog

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
Hello, i want set da14580 as

Hello, i want set da14580 as observer. In sdk, which program can be used ?

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
Sorry, Would you help me? I

Sorry, Would you help me? I have tried for 3 days, but i don't know how have to do . Help me!Help!Help!

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
我想开发DA14580 BLE

我想开发DA14580的DA14580 BLE OBSEVER扫描广告数据包。
1.在SDK中,Prox_Monitor项目的功能是什么?
2. Can't i debug ble stack ? I want to debug(view) advertising packets from advertiser.Could you tell me?

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Hantig,

嗨Hantig,

There is no ready example in order to directly configure it as a central observer, you can have a look at the DSPS project in the host example where the device is configured as a central and take that as a reference, the GAP role configuration is controlled via the user_gapm_config struct in the user_config.h function. If you change the .role from GAP_CENTRAL_MST to GAP_OBSERVER_SCA then you will have your observer. After that all you need to do is scan, so you can take as a reference the user_scan_start() function from the DSPS host example.

In the SDK the proximity monitor function is an external host solution, meaning that the 580 takes commands from external MCU (a windows PC on the specific example), please check the UM-B-010 User Manual : Proximity Example in integrated and External Processor Solution.

The ble stack is located in the ROM and there is no source code available for the stack, you interact with the stack via messages through the functions exposed from the SDK, what exactly do you mean view advertising packets ?

谢谢MT_dialog

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
Thank you, very much!

Thank you, very much!
我将开发与两个DA14580S的配对接近标签使用。因此,外围和观察者。
通过SDK示例容易地进行外围设备。但观察者设备很困难,因为SDK中没有示例代码。
I changed as below.
In app_configuration_func() of DSPS, cmd->role = GAP_OBSERVER_SCA
In app_scanning, msg->mode = GAP_OBSERVER_MODE and msg->filter_duplic = SCAN_FILT_DUPLIC_DIS

By the way, by contrast as usb dongle, gapm_adv_report_ind_handler() is less called than dongle.
Example In usb dongle broadcast packets show every 0.5s, but in DSPS observer program broadcast packets(gapm_adv_report_ind_handler called times) show every 2~3s .
Inorder to act my program as usb dongle, how to have to do? How have to change scan interval of observer device ?
纠正我,你会给我源代码吗?如果你很难,我想详细帮助我。

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
Dear MT_dialog, Execuse me,

Dear MT_dialog, Execuse me, would you help me? I had ever used nrf51822, but da14580 superior more than nrf51822. I am more interest da14580 and i have already developed several bluetooth devices using da14580.
但是,DA14580源代码作为观察者当然需要对US.Help Me!提前致谢。

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Hantig,

嗨Hantig,

Regarding the "dongle" that you mention in your previous post, i am not able to understand what exactly is the problem, can you be more descriptive ? The gapm_adv_report_ind_handler() is the callback that is triggered as soon as your observer receives an advertising message from the air. The frequency that the handler is triggered depends on how many advertising devices are advertising at the moment and how many of them are reaching your device and offcourse the way that your observer is scanning. Regarding changing your advertising interval, that is controlled by the scanning function that issues a GAPM_START_SCAN_CMD. In the DSPS host the function is the user_scan_start() and the interval and scanning window are controlled by the members .interval and .window of your gapm_start_scan_cmd function.

Regarding the observer fw is quite simple to create a simple observer device, lets take as a starting base the template located in the SDK.

1) In the user_config.h function at the user_gapm_conf structure change the .role from GAP_PERIPHERAL_SLV to GAP_OBSERVER_SCA.

2) From the DSPS example take the user_scan_start and paste it in the template project, then you can either set your own user_scan_conf structure or you can place tha values that you would like in the gapm_start_scan_cmd structure.

3) Then you can start scanning whenever you are ready, therefore since you dont have any database to initialize you can assign the user_scan_start() in the app_on_set_dev_config_complete callback.

4) Implement a function in order to hook to the app_on_adv_report_ind in order to get the advertising messages, and you should be good to go.

谢谢MT_dialog

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
非常感谢你!Dear, MT

非常感谢你!亲爱的,mt_dialog。
First i send you images which indicate current situation.
I have done as method which you had told me, but it is same.
Thus, if i set breakpoint in app_on_adv_report_ind() and i compare with dongle packet sniffer, when dongle packet has shown 5~6 times, app_on_adv_report_ind() has called barely 1 times.
Execuse me, Would you please send me observer souce code? My address isskyclean906@gmail.com.

Attachment:
MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Hantig,

嗨Hantig,

Uploaded a quick and dirty demo source code that sets the device in observer mode and scans for any advertising messages, the Duplicate filter is disabled so the device prints all the available advertising strings that it can reach in all channels and prints it over UART2, be aware that if there are two many devices on air with the current configuration of the sw (printing any available advertising string), the device will hit the reset due to excessive printing. The above is tested and runs on a dialog pro kit.

谢谢MT_dialog

Attachment:
hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
亲爱的,mt_dialog!

亲爱的,mt_dialog!
你是开放的,非常善良。我对你的善意留下了深刻的印象!我想要一个深入的纽带。我想和你成为一个好朋友!在未来帮助我!非常感谢你!

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
亲爱的,我执行代码

Respected dialog!
我执行您在user_on_adv_report_ind()中设置的代码并设置断点,但user_op_adv_report_ind()几乎不调用(即使在1〜2分钟内甚至一个时间)。
In dongle sniff packet, advertising packets was correctly shown.
Ultimately, packet numbers which shown in dongle sniff packet must be equal to packet which arch_ print call numbers in user_on_adv_report_ind().
Sorry,would you review again and send source code?

Attachment:
MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Hantig,

嗨Hantig,

The code that i have uploaded is allready tested on a pro kit and the reports are printed for every available device as they should, if the device isn't able to track the advertising event of the other modules, then the code isn't the problem (unless if you hit any reset or a hardfault which i suppose that you would notice), i ve tested the fw before sending it over and i was perfectly able to track near devices, so are you using a development kit or a custom design ? Also be aware that the device will report advertising string as long as the device on the other side is advertising, if there are no advertising messages on air, the device won't report anything.

谢谢MT_dialog

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
亲爱的,对话!我用

亲爱的,对话!我使用开发套件板。这是一对广告商和观察者。什么都不在附近。
Execuse me, Would you give me the advertiser program which you have tested ?My address isskyclean906@gmail.com.

您的580_observer程序轨道在设备附近,但仅包含几个数据包。(广告商发送的一些数据包)。
我希望你能解决这个问题。帮帮我!

MT_dialog
Offline
Last seen:3 months 5 days ago
Staff
Joined:2015-06-08 11:34
嗨Hantig,

嗨Hantig,

让我直截了当地对广告和扫描操作的操作,因为我认为您希望获得外围设备发出的所有广告信息。扫描操作并不是为了通过外设发送的所有广告事件发送,外围设备以固定的连接间隔广告三个通道,以便为一些广告字符串获得主人(不是所有广告的原因事件无法达到扫描仪是因为没有协议保证,数据包到达另一方,因为使用空气作为传输媒体的数据包可以发生,噪声,其他设备传输,天线等。因此,您不会获取所有广告活动从外设发送到扫描仪,但是这些事件的一小部分。此外,BLE设备如何扫描以及外围通告如何使扫描仪无法在所有频道中获取所有广告字符串。当设备扫描时,它在所有BLE广告通道(38,38,39)中单方面打开特定通道上的接收器(37,38,39),因此如果外围设备发生在此时通知,并且介质是打开的并且设备的天线是能够听广告数据包,设备将要报告它。如果您想在观察者方面获取更多报告,您需要设置外设发送更多的广告数据包。关于将580与嗅探器加密狗进行比较,我不知道你使用的是什么,以嗅到空气,但你不能将嗅探器比较到580个通用设备,显然是您使用的嗅探器具有更好的天线(获取数据从长途距离)和优化的SW以便这样做,甚至可能是一种不同的扫描方式,以便尽可能多地嗅闻。

The program i used in order to test the observer demo was the ble_app_peripheral, if you leave the fw as is advertising evey 100ms you should continuesly get indications for advertising strings, i also tested it under 1s advertising interval and indications were comming in approximatelly every 2 seconds best every 1 seconds (getting an advertising event every time the peripheral went upon the air) tested with a 10 meter distance. The distance its something that has to do with the antenna used and the on-air traffic and not the sw.

额外的东西,我看到了新的帖子,为了改变扫描间隔和窗口,您必须进入user_scan_start()并更改CMD->间隔和CMD-> Window参数。此外,我有关于您的其他帖子的请求,please dont post irrelevant questions on other threads, you can always create a new thread in order to share your question in order to keep this forum straight forward and easy to use.

谢谢MT_dialog

hantig
Offline
Last seen:3 years 5 months ago
Joined:2017-07-03 17:01
Respected dialog! Help me!

Respected dialog! Help me!

Durlaksel
Offline
Last seen:1 month 1 week ago
Joined:2020-07-22 07:31
How to add one more

How to add one more characteristic in GAP, need to do changes in stack?

PM_Dialog
Offline
Last seen:2days 29 min ago
Staff
Joined:2018-02-08 11:03
Hi Durlaksel,

Hi Durlaksel,

谢谢for posting on our public Bluetooth forums. Could you please create a new thread with your query as this one is very old and close? Also, please indicate the device and the SDK that you are using.

谢谢, PM_Dialog