iOS somehow reduce my network speed in Wifi connection to my Camera device in AP

Viewed 19

I'm developing iOS Application for communication with manufactured Camera via WiFi using custom API.

I have camera device in Wifi mode AP. I'm connecting to that device via Wifi using NEConnection to specific port. TCP protocol.

We have 2 ports, one for messages other for data transferring.

Then using API. I'm building specific message, converting them to Data and sending to Camera device. I can receive data or message data from Camera as well.

I need to download video file with for example 100MB. And it take a lot of time.

Issue is: While receiving data from device we have speed ± 160 KB/s, but android with the same configurations has 2MB/s.

Why it happens, does Apple makes some speed limitation? Could it be related to Wifi as it doesn't has internet connection?

NWConnection constructor:

static func createConnection(host hostAddress: String, port portInt: UInt16) -> NWConnection {
        let ipv4: IPv4Address = .init(hostAddress) ?? .any
        let host: NWEndpoint.Host = .ipv4(ipv4)
        let port: NWEndpoint.Port = .init(rawValue: portInt) ?? .any
        
        let tcpOptions: NWProtocolTCP.Options = NWProtocolTCP.Options.init()
        
        return .init(host: host, port: port, using: .init(tls: nil, tcp: tcpOptions))
    }
0 Answers
Related