Hi my app us using NEHotspotConfigurationManager
to connect some local network.
I have a logic in the app to check what is SSID of the current connected WiFi network. For this i was using CNCopyCurrentNetworkInfo function. But according to documentation it is deprecated and I should use NEHotspotNetwork.fetchCurrent(completionHandler:).
The thing is that sometimes when i call this method the completion handler is not called so my app wait long time and nothing happens.
Any advice what can be wrong or how to solved this?
using Xcode 12.3, iOS 14.2 and iPhone 11.
Post
Replies
Boosts
Views
Activity
Hi
According to this thread
https://developer.apple.com/forums/thread/663852 , when I want to check if permission was denied I should create NWConection and check status and its unsatisfiedReason property.
It is working when device is connected to the WiFi network where given host with ip address is existing like 192.168.100.1.
But I have two cases when proposed solution is not working for me.
1) Device is connected to Wifi network where there is no host with given ip. Then when i try to create connection with NWConnection then for .waiting status I get
waiting(POSIXErrorCode: Connection refused)
Network.NWPath.UnsatisfiedReason.notAvailable
2) when wifi is disabled and and user is using only gsm when i want to create NWConnection to given address I'm receiving after long time
.waiting(POSIXErrorCode: Operation timed out)
Network.NWPath.UnsatisfiedReason.notAvailable
So it seems like .localNetworkDenied for NWPath.UnsatisfiedReason property is only returned for NWConnection to host that exist in current connected Wifi network.
Can you confirm it?
Basically I want to implement functionality that view is showing for the user that denied access to Local Area Privacy Network and he is connected to any Wifi network or even not connected at all.
Is it possible, please advise?
thanks
Hi,
I'm experiencing problems with playing high-quality videos on older devices like iPhone SE 1st gen, iPhone X.
I guess there is a performance/resources issue when I use mp4 video with size 5760x2880.
The player just doesn't start and I cannot get status information that something was wrong, AVPlayerItem.status property is readyToPlay and AVPlayerItem.error is null.
Could you confirm that this video quality is too high for the device? How I can programmatically check if a given video can be played on a given device or get the playing status?
I have no issues with playing such videos on iPhone 11 or iPhone 12 mini.
Originally I was using SKVideoNode and AVPlayerItem to play a video in SceneKit but the same problem exists when I was using simple AVPlayerViewController.
Please advice,
Hi,
I've created small tool as a build tool plugin. I want to attach example project to the repo.
But when I try to add local dependency to the Example project, build tool is not visible. But it is visible when I link to remote repo directly from github.
Github repo with Example app with remote dependency to the build tool plugin.
https://github.com/PGSSoft/GitCommitInfoPlugin
Adding a local dependency to Package.Swift in parent directory
Trying select build in Build Phase pane.
Build tool is not visible in the list but it is visible when I add remote repo.
Is it bug or intended behaviour?