IOS Being the FTP Server ?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
IOS Being the FTP Server ?
Evening all,
I have another project coming up that is going to require me to set up an IOS device as an FTP Server.
The questions I have are:
1: Can LC and IOS do this? cant find any information on this?
2: If 1 = true then I need to be able to control the IP Address of the IOS device when its a WiFi Hotspot as the FTP Clients can only communicate to a fixed IP Address.
For example:
the device is running as a WiFi Hotspot.
App starts, starts FTP Server (with a fixed definable IP Address)
clients connect once communicable and pass data.
will this be achievable?
I have another project coming up that is going to require me to set up an IOS device as an FTP Server.
The questions I have are:
1: Can LC and IOS do this? cant find any information on this?
2: If 1 = true then I need to be able to control the IP Address of the IOS device when its a WiFi Hotspot as the FTP Clients can only communicate to a fixed IP Address.
For example:
the device is running as a WiFi Hotspot.
App starts, starts FTP Server (with a fixed definable IP Address)
clients connect once communicable and pass data.
will this be achievable?
Re: IOS Being the FTP Server ?
Socket support is not yet available for livecode on IOS. I think its planned for a future update.
As for controlling your IP, I don't believe you have direct control. However its possible that once the IP is assigned (and you don't move locations/cell towers) it won't change often. Assuming a 'real' ip (rather than a private) is assigned to the device, then you might be able to use a dynamic dns service to handle pointing to your device. If the IP changes, update the dns entry. This way all clients can point to a name and get pointed to the current IP.
If all of the requirements are met, and dynamic dns is set up the you can probably use this: http://itunes.apple.com/us/app/ftp-driv ... 71784?mt=8 as your ftp server. I haven't tried it but for 99 cents its a cheap test to see if it can be done.
If the IOS device is assigned a private address, and is assigning private addresses to its clients as it acts as a hotspot, i'd check the app you use to see if it does internal name services. If it does, same type of deal. Don't use the IP address use the assigned device name and hit that. (or if you are writing the clients in LC it should be possible to determine the IP of the gateway (which should be the IOS device acting as hotspot) and use that IP.)
Unfortunately I don't have a cell based IOS device so I can't actually try any of this.
As for controlling your IP, I don't believe you have direct control. However its possible that once the IP is assigned (and you don't move locations/cell towers) it won't change often. Assuming a 'real' ip (rather than a private) is assigned to the device, then you might be able to use a dynamic dns service to handle pointing to your device. If the IP changes, update the dns entry. This way all clients can point to a name and get pointed to the current IP.
If all of the requirements are met, and dynamic dns is set up the you can probably use this: http://itunes.apple.com/us/app/ftp-driv ... 71784?mt=8 as your ftp server. I haven't tried it but for 99 cents its a cheap test to see if it can be done.
If the IOS device is assigned a private address, and is assigning private addresses to its clients as it acts as a hotspot, i'd check the app you use to see if it does internal name services. If it does, same type of deal. Don't use the IP address use the assigned device name and hit that. (or if you are writing the clients in LC it should be possible to determine the IP of the gateway (which should be the IOS device acting as hotspot) and use that IP.)
Unfortunately I don't have a cell based IOS device so I can't actually try any of this.
Re: IOS Being the FTP Server ?
Hi Nakia,Nakia wrote:Evening all,
I have another project coming up that is going to require me to set up an IOS device as an FTP Server.
The questions I have are:
..........
I had the same need and ... I had to change my mind ...

FTP server, at moment, is NOT available also on the desktop versions of LC ... I can't imagine when will be available on iOS

I solved my problem using DropBox (DorpBox released sdk both for iOS and OSX, but, in LiveCode, it's very easy to connect also using the "put URL ...." and the REST API), so ...
... if DropBox can be an alternative for you ... think to this solution

Guglielmo
Re: IOS Being the FTP Server ?
The desktop version of livecode does have socket support so it should be possible to create an ftp server with it (I think). Still not for IOS though.
I think the dropbox method would be a great way to go, theres also google drive (Is there an IOS client for google drive yet?).. There are quite a few options out there.
I think the dropbox method would be a great way to go, theres also google drive (Is there an IOS client for google drive yet?).. There are quite a few options out there.
Re: IOS Being the FTP Server ?
Hi sturgis,sturgis wrote:The desktop version of livecode does have socket support so it should be possible to create an ftp server with it (I think). Still not for IOS though.
writing an FTP for the desktop version was also my first idea but ...
... have you already tried to write a complete FTP ? Uff ... good luck ...

No, unfortunately Google has not yet released and iOS client ...sturgis wrote:I think the dropbox method would be a great way to go, theres also google drive (Is there an IOS client for google drive yet?).. There are quite a few options out there.
... but, do you know if they have, like DropBox, some kind of REST API ???
Guglielmo
Re: IOS Being the FTP Server ?
Yeah, think i'll pass on writing an ftp server. In any language!
Not sure what the google drive api details are but you can read up on it here. https://developers.google.com/drive/v1/reference/
Not sure what the google drive api details are but you can read up on it here. https://developers.google.com/drive/v1/reference/
Re: IOS Being the FTP Server ?
Mmm ... interesting ...sturgis wrote: ...
Not sure what the google drive api details are but you can read up on it here. https://developers.google.com/drive/v1/reference/

Yes, it seems that the logic is the same as DropBox, both use OAuth for authorization and, probably, with sample "put URL ..." is possible to use also Google Drive ...
... I will try with my account ...

Guglielmo
Updated : Google Drive use Oauth 2, DropBox use OAuth 1. More ... "Authorization alone is not sufficient to give your app access to users' files — app installation is also required. Apps will not have any API access to files unless users have first installed the app in Chrome Web Store" ... but they still don't have App for iOS

Much easier to use continue to use DropBox
