Closed colemancda closed 2 years ago
I know that there is asyncAfter on DispatchQueues: https://developer.apple.com/documentation/dispatch/dispatchqueue/2300020-asyncafter
Could be handy if you can make the 2nd half of the scan function asynchronous
The new Swift Concurrency integration fixes this.
Use a different strategy that doesn't involve
sleep()
while scanning to improve energy efficiency and decrease unnecessary CPU usage.DispatchSemaphore
might be a good solution.