Method StopBackgroundThreadsAsync
Namespace: Belay.Core.Examples
Assembly: Belay.Core.dll
StopBackgroundThreadsAsync()
Stop all background monitoring threads. This runs first during disconnection.
csharp
[Teardown(Order = 1)]
[PythonCode("\n print('Stopping background threads...')\n \n # Signal all threads to stop\n globals()['monitoring_active'] = False\n \n # Wait for threads to notice and shut down\n import time\n time.sleep_ms(500)\n \n print('Background threads stopped')\n ")]
Task StopBackgroundThreadsAsync()