I am planning to migrate from the nRF5 SDK to the nrf connect SDK.
My application is processing events from SoftDevice on a single thread.
In the same way, please tell me how to receive HCI events in a single thread with the nrf connect SDK.
I am planning to migrate from the nRF5 SDK to the nrf connect SDK.
My application is processing events from SoftDevice on a single thread.
In the same way, please tell me how to receive HCI events in a single thread with the nrf connect SDK.
yes. I understand It.
What I am concerned about is which thread (Context) is calling the callback when it is called back using the Bluetooth Host API.
I expect all callbacks to be called from SystemWorkq.
Was your question addressed by Amanda's reply in your other thread here: Why is ble_rx_thread priority cooperative?
No.
my question is
1. How all HCI events are called on SystemWrokq context (this thread)
2. How to set SystemWorkq priority to preemptive (other thread)
What thread/workqueue they are run in depends on your configuration settings here: https://github.com/nrfconnect/sdk-zephyr/blob/main/subsys/bluetooth/host/Kconfig#L97. You can open the thread viewer when debugging the application in VS code or Segger Ozone to confirm what thread a particular callback is run in.
E.g.