-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Use Case
mobile health applications that have a focus on sensor-based health data collection can benefit from accessing a user's connected apple watch, if available.
while some of the data collected by a watch's sensors can be accessed directly from within an iOS app (eg: data collected by the watch and automatically stored into HealthKit), some other sensor data needs to be collected directly on the watch (eg: gyroscope, accelerometer, etc data).
Problem
while many Spezi modules currently have support for watchOS, Spezi currently does not provide any abstractions or mechanisms for inter-device communication or data transfer between a Spezi-based app running on an iPhone and its counterpart running on a paired apple watch.
applications instead need to implement their own logic for communication, state handling and connection management.
Solution
we might want to offer some basic APIs for this in Spezi.
an initial version of this would probably consist of a pair of Modules that map the respective devices' communication responsibilities in such a scenario:
- a
WatchConnectionmodule, which runs in the iPhone version of a Spezi-based app and handles interactions with the watch - a
PhoneConnectionmodule, which runs in the watch version of a Spezi-based app and handles interactions with the iPhone
these modules would then offer simple facilities for interacting with the other device, e.g. by exchanging messages, sending commands, or sharing state.
(we might be able to model both of the modules outlined above as a single module; this is merely a first and rough draft.)
Alternatives considered
a potential issue here is that every application's specific needs w.r.t. inter-device communication will be completely different.
we therefore need to be careful not to implement something that covers our current needs but doesn't have much use beyond that.
instead, we should try to identify the common base set of features and capabilites required in such scenarios, and design and implement a nice and reusable API around that.
Additional context
No response
Code of Conduct
- I agree to follow this project's Code of Conduct and Contributing Guidelines
Metadata
Metadata
Assignees
Labels
Type
Projects
Status