Time critical operations with BLE stack running

⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.xmece.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
2 posts / 0 new
Last post
ky3orr
Offline
Last seen:11 months 1 week ago
加入:2019-06-03 12:17
Time critical operations with BLE stack running

Hello,

I am working on a firmware utilizing BLE stack based on a PXP_reporter (also SUOTA is needed) example from SDK 10.0.4.66.2.

I'd like to add a task that performs some time critical actions (DC motor steering using custom on/off profile so no easy use of HW PWM).

Is there a tutorial or guide regarding time and events management between tasks to learn proper way of handling time critical operations in a multi-task environment?

I assume BLE task consume some CPU power and it may have a higher priority than other tasks and I guess I will run into trouble trying just to use and rely on some software timers.

Thank you for any advices.

Device:
PM_Dialog
Offline
Last seen:2 days 18 hours ago
工作人员
加入:2018-02-08 11:03
Hi ky3orr,

Hi ky3orr,

没有任何教程或tutorial demonstrating time and events management between tasks. The software timer timers have the highest priority than that other tasks. After the software timers, the BLE adapter has the highest priority, then the BLE manager and then the user’s tasks. The IDLE has the lowest priority. If your firmware requires critical operations, you could disable the global interrupts, and as soon as the operation is completed, you should enable them.

Thanks, PM_Dialog