Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

samples: Bluetooth: central_iso: Desynchronized submission of data #72452

Open
fgrandel opened this issue May 8, 2024 · 0 comments · May be fixed by #72622
Open

samples: Bluetooth: central_iso: Desynchronized submission of data #72452

fgrandel opened this issue May 8, 2024 · 0 comments · May be fixed by #72622
Assignees
Labels
area: Bluetooth ISO Bluetooth LE Isochronous Channels area: Bluetooth bug The issue is a bug, or the PR is fixing a bug priority: low Low impact/importance bug

Comments

@fgrandel
Copy link
Contributor

fgrandel commented May 8, 2024

Describe the bug

In addition to #70794 (BLE TX buffers should provide for ISO header), there are more bugs in the ISO central sample:

  • The sample is not correctly synchronized with the radio clock. Therefore a race condition emerges that ISO sequence numbers will no longer match L2 ISO payload number after a few iterations.
  • The sample does not consider rounding errors on nRF boards whose LF clock's period cannot be represented as an integer in microseconds.
  • The sample does not take into account that the L2 in the controller systematically skips the second ISO interval (aka payload count/event number) to provide for initial synchronization (i.e. the sequence of events is 1, 3, 4, 5... and not 1, 2, 3, 4)

This is relevant to all nRF platforms that use a 32k sleep clock.

To Reproduce
Steps to reproduce the behavior:

Expected behavior
With proper synchronization the sample should be able to run for hours without skipping payload numbers even if CONFIG_BT_CTLR_ISOAL_PSN_IGNORE=n.

Impact
The sample does not provide a proper template for perfectly synchronized transmission.

Logs and console output
see #70794

Environment (please complete the following information):
nRF platforms with 32k sleep clock

Additional context
I have a fixed sample that I can provide as a PR. Just need some time to make it upstream-ready.

@fgrandel fgrandel added the bug The issue is a bug, or the PR is fixing a bug label May 8, 2024
@cvinayak cvinayak changed the title ISO Central Sample: Desynchronized submission of data samples: Bluetooth: central_iso: Desynchronized submission of data May 8, 2024
@cvinayak cvinayak added area: Bluetooth area: Bluetooth ISO Bluetooth LE Isochronous Channels labels May 8, 2024
@aescolar aescolar added the priority: low Low impact/importance bug label May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Bluetooth ISO Bluetooth LE Isochronous Channels area: Bluetooth bug The issue is a bug, or the PR is fixing a bug priority: low Low impact/importance bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants