3

I need a way to have an iOS application that can accept a message on a device connected via USB, query a bunch of data about the device and return a response with this data.

I am brand new to iOS and swift development so I need something that is;

  • Simple
  • Uses CocoaPods (due to lack of ios support in Swift Package Manager)
  • NOT require distribution via the App Store (which I believe rules out using APN)

I have tried the following:

  1. BlueSocket: https://github.com/IBM-Swift/BlueSocket

This can probably do the job but is very low level and require lots of work around handling buffer sizes, etc. So a REST solution might be a better

  1. Kitura: https://www.kitura.io/

This seems ideal. However, it only appears to support Swift Package Manager which makes it a big PITA to implement currently (reminder; swift/ios newb here)

  1. CoacoaHttpServer: https://github.com/robbiehanson/CocoaHTTPServer

This looks ok, however I can only find Objective-C examples. Would prefer to have something that includes solid Swift examples (also, the repo doesn't look like it's been updated since 2015)

Are there any other approaches I should consider that I haven't listed here?

  • You want the iOS app to act as the REST server? Or you want the iOS app to interact with a web server? How is the iOS going to communicate with a device over USB? It the device MFi certified? Enterprise apps can use APNS – Paulw11 Nov 30 '18 at 10:28

1 Answers1

0

You may want to check https://github.com/IBM-Swift/Kitura-HelloWorld-iOS.

I wrote a couple of blog posts about it https://developer.ibm.com/swift/2017/03/13/kitura-ios/, https://developer.ibm.com/swift/2017/12/08/kitura-ios-part2/.

Note that it is a demo repository, I do not know if IBM will support Kitura on iOS (it is supported on Linux).

Vadim Eisenberg
  • 3,337
  • 1
  • 18
  • 14