Download

communicate with an external app ?

Hi is it possible to communicate with an external app on a phone or ipad from within Unreal ?t
I have some fitness hardware that is controlled by bluetooth via an app. This app is created by a 3rd party.
I would like to change the hardware settings from within the game by communicating with the App.
There is an API available for the hardware communication.
The unreal game would be run on my pc.
Can anyone let me know some key words or forum threads to check out as this is new territory for me.

Try OSC. It’s a midi type connection. I use it to control unreal from an iPad all the time. If you can import an OSC library into your iPad app you can do this. Look for the OSC plugin on the forum.

Thanks for getting back Dannington. Just a couple questions if you have a minute…

  1. I presume communication can work both ways ie as well as you controlling game Play with an ipad you could use Unreal to control an APP on your ipad ?
  2. Is it possible to communicate from Unreal with an App that communicates with another App:
    For example I have a pre-packaged xcode APP. I have access to the API for this APP but I don’t have access to the source code of the original APP.
    Can I make a ‘dummy’ APP to act as a go-between the packaged APP and the Game Engine ?

Yes, the osc plugin goes both ways. And for your second question, I did exactly this before the osc plugin was available. I used a python script as a go-between. Python was handling osc input/output and driving the engine using a tcp socket plugin.

OK thanks - very final question!
Now that there is an OSC plugin available for Unreal is there still a need to create a separate go-between program ?
ie. Is it possible to control a packaged app directly from Unreal using OSC or would the APP need to have OSC libraries pre-packaged in it ?
(Communication wouldn’t need to be two-way… only from Unreal to the APP)

I’ve stopped using my python scripts for the most part (I’m prototyping about 4 different apps). One of them requires data from an excel file so I use the python script for this, but for the most part i’m using an SQL plugin for that now. Using UE directly is generally much snappier and there are a lot less stages involved in terms of IP addresses and alt-tabbing between scripts and UE. If you can i’d say keep it in the engine. Happy to chat about any of this stuff.

This is a screenshot of my prototype:
https://vimeo.com/160068522 (password: Bike)
Its viewed on an Oculus Rift and the bike speed is determined by the users heart rate sensor.
The last step is to link the virtual gear change up with the physical gear change on a bike trainer (the wahoo kickr).
Wahoo provide API (http://api.wahoofitness.com/).
This API was combined with OSC and the Unity engine to create this game:
http://www.globacore.com/paperdude-vr/

I know that I can use the Unreal OSC plugin to communicate with the API (somehow!).
I’m just unsure whether its possible to communicate directly with a pre-packaged app via OSC in Unreal or if I need to make a completely new app in xcode.
Any ideas?