[riot-notifications] [RIOT-OS/RIOT] sys/shell/sc_nimble_netif: add ping subcommand (#16539)

Hauke Petersen notifications at github.com
Tue Jun 8 12:29:02 CEST 2021

### Contribution description
The BLE L2CAP layer provides a echo request-response procedure similar to ICMP echo. This can be used e.g. for link quality assessment and debugging. I just added a PR to NimBLE (https://github.com/apache/mynewt-nimble/pull/987) exposing this feature. This PR adds a subcommand to the `nimble_netif` shell command to trigger this procedure -> `ble ping CONN_HANDLE`

### Testing procedure
Build `gnrc_networking` for `nrf52x` against the NimBLE feature branch (https://github.com/apache/mynewt-nimble/pull/987):
  - checkout NimBLE and switch to the referenced feature branch
  - build gnrc_networking using the local NimBLE repo (`PKG_SOURCE_LOCAL_NIMBLE=PATH/TO/LOCAL/NIMBLE make ...`
- flash application to 2 nodes in radio range
- establish a BLE connection: e.g. node A: `ble adv foo`, node B: `ble connect foo`
- start pinging: `ble ping 0`, where 0 is the connection slot (see `ble info` for allocation)

You should see a `ECHO_RSP message each time the procedure is triggered, e.g.:
2021-06-08 12:14:35,823 # ble ping 0
> 2021-06-08 12:14:35,920 # ECHO_RSP, rtt:95 size:0
2021-06-08 12:14:35,936 # ble ping 0
> 2021-06-08 12:14:36,070 # ECHO_RSP, rtt:132 size:0
ble ping 0 moinsen
2021-06-08 12:14:44,246 # ble ping 0 moinsen
> 2021-06-08 12:14:44,321 # ECHO_RSP, rtt:73 size:7

### Issues/PRs references
waiting for https://github.com/apache/mynewt-nimble/pull/987
You can view, comment on, or merge this pull request online at:


-- Commit Summary --

  * sys/shell/sc_nimble_netif: add ping subcommand

-- File Changes --

    M sys/shell/commands/sc_nimble_netif.c (31)

-- Patch Links --


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210608/b9cd93e8/attachment.htm>

More information about the notifications mailing list