Phidgets Connection Issue in Swift iOS

Comments & issues
Post Reply
Sankar329
Fresh meat
Posts: 1
Joined: Thu Mar 25, 2021 12:54 pm
Contact:

Phidgets Connection Issue in Swift iOS

Post by Sankar329 »

I couldn't open the Phidget Connection in swift iOS.

When I try to open Digital output channel using Power Plug Phidget PSU1000_0 with VINT USB MINI HUB0000_0, I am getting the error as timeout always.

I have added my sample code for reference.

func initPhidgets(){
let ch = DigitalOutput()
do {
try ch.setIsHubPortDevice(true)
try ch.open(timeout: Phidget.defaultTimeout)
try ch.setState(true)
try ch.close()
} catch let error as PhidgetError {
// handle other errors
print("Phidget Error ", error.detail)
}
catch {
// Catch any other errors
}
}
LucasP
Phidgetly
Posts: 22
Joined: Fri Oct 07, 2016 4:47 pm
Contact:

Re: Phidgets Connection Issue in Swift iOS

Post by LucasP »

Are you enabling network server discovery?

Code: Select all

try Net.enableServerDiscovery(serverType: .deviceRemote)
Post Reply

Who is online

Users browsing this forum: No registered users and 18 guests