Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Return devices connected via wifi. #85

Open
jonasfunk opened this issue Sep 29, 2023 · 3 comments
Open

Feature request: Return devices connected via wifi. #85

jonasfunk opened this issue Sep 29, 2023 · 3 comments

Comments

@jonasfunk
Copy link

Return devices connected via wifi.

From documentation: "Note that only devices connected via a USB cable will be returned. Devices connected via Wi-Fi will not be returned. The main reason we do this is because you can only relay the syslog from USB connected devices. This restriction be lifted in the future."

@cb1kenobi
Copy link
Contributor

cb1kenobi commented Sep 29, 2023

node-ios-device@3 supports this! :)

There are limitations though. We can't port forward over WiFi which means we can't see logs. Installing apps works though.

@jonasfunk
Copy link
Author

Sounds nice 👏. Personally I would be ok with this, as long as you are informed that there is a limitation with logs. Is it an easy fix to make it work?

@cb1kenobi
Copy link
Contributor

The readme makes mention of the limitation with the forward() API. I should point out this port forwarding is for general use, but was designed for debug logging exclusively used by Titanium apps.

If I recall correctly, back in the day, iOS would let apps write to syslog and that's how logging worked in Titanium apps. iOS had a syslog relay service that node-ios-device would use. Then iOS switched how app logging worked and app logging was no longer written to syslog. I wrote a debug log server that ran in the background of a Titanium app for the Titanium CLI can connect to and get log messages. It created a real socket listening on a real port. That's where the port forwarding came in.

I would still categorize this as a limitation of the forward() API. Apps and libraries that use node-ios-device would likely detect if the device is USB or WiFi, then if USB, use forward(). If WiFi, get somehow get the device's IP address and directly connect to it over WiFi.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants