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

Frequency decrease in notification example #232

Open
FrancoisTeyssere opened this issue Oct 15, 2021 · 0 comments
Open

Frequency decrease in notification example #232

FrancoisTeyssere opened this issue Oct 15, 2021 · 0 comments

Comments

@FrancoisTeyssere
Copy link

I'm using the notification example on a BLE sensor streaming a value at 25Hz (I verified this value was correct by other means).

The connection and printing works alright, but when I measure time between two notifications, I'm only reaching 22Hz.

Any idea on where that would come from?

I'm measuring time between the end of the notification function, and the start of the next one, with that function :
`uint64_t get_posix_clock_time ()
{
struct timespec ts;

if (clock_gettime (CLOCK_MONOTONIC, &ts) == 0)
    return (uint64_t) (ts.tv_sec * 1000000 + ts.tv_nsec / 1000);
else
    return 0;

}`

And I also experienced the issue when encapsulating it in a C++ program and measuring with , so I'm quite sure about my frequency measurement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant