This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Radio Notifications running one advertising and one scan.

Hello,

I'm running one advertiser and one scanner at the same time, and I want to change the data inside the advertise packet, every advertise. Looking at the forum and reading the specification of the SDK12, I've found that I can use the radio notification to interrupt after every radio event. But the problem is that the scanning event is triggering the interrupt, too. Is there a way to see the direction (TX or RX) of the radio event that trigger the interruption?

Thanks.

  • More information about the radio event is a common request that has been reported internally in Nordic.

    For this use case, where you want to change the advertising data regularly, you may want to look at some other ways of doing it as long as the radio notification is so limited. Probably the best solution is to use a repeated application timer with the same timeout as the advertising interval. Then you can modify the advertising data in the timeout handler roughly every advertising interval.

    (In practice it should not matter if the interval for changing the advertising data is the same as the advertising interval, as you should anyway expect advertising packets to get lost.)

Related