Hello Guest, Welcome to Apnea Board !
As a guest, you are limited to certain areas of the board and there are some features you can't use.
To post a message, you must create a free account using a valid email address.

or Create an Account


New Posts   Today's Posts

OSCAR: Questions regarding a potential import for Garmin data
#1
OSCAR: Questions regarding a potential import for Garmin data
Hi

I am currently considering writing an importer for data from Garmin devices into OSCAR.

In the first development step, I would get the data from Garmin Connect as a JSON file via a Python script and an importer integrated into OSCAR would import the JSON file.
Later, the data could then be downloaded from Garmin Connect directly from within OSCAR.

After looking through the source code a bit, I have a few questions.

1) When checking the ChannelID, I found the following existing channels that are relevant for Garmin devices:
OXI_Pulse, OXI_SPO2
Journal_Weight
ZEO_SleepStage, ZEO_ZQ, ZEO_TotalZ, ZEO_TimeInWake, ZEO_TimeInREM,
ZEO_TimeInLight, ZEO_TimeInDeep, ZEO_Awakenings,
POS_Movement

The loader_plugin only implements one MachineType at a time. But I had ChannelID from different MachineType.

What is the best way to deal with an import that imports a wide range of channels?
If I see it right, no import supports this scope so far.

2) The data is provided in different frequencies.
While measurement values for pulse are available every 2 minutes, time frames are always given for the sleep level, which can sometimes be 1 1/2 hours long.
Can the data structures in OSCAR handle this if the measured values are available in different time intervals and types (measured values at time X vs. time ranges).?

3) Some Garmin data is only available for the sleep time (sleep level) while others are available for the whole day (pulse).
A few tests with CVS files showed that it can lead to strange effects when measurements are suddenly available for the whole day. My guess is that OSCAR is actually designed so that only measurements for the sleep time should be imported.
What would you recommend? Is there a way to determine the sleep time based on the CPAP so that I don't import the pulse outside of these times, for example?


I think that's enough questions for the first round.
 

lg
Post Reply Post Reply
#2
RE: OSCAR: Questions regarding a potential import for Garmin data
#1. I believe you would need to create the additional channel declarations to address this.
#2. & #3. If each observation is timestamped, then it would be easy to parse the data to compare against a sleep session. Otherwise, that could be a biddy.

Have you looked at the Somnopose loader? It parses a CSV file.
- Red
Crimson Nape
Apnea Board Moderator
Project Manager for OSCAR - Open Source CPAP Analysis Reporter
www.ApneaBoard.com
___________________________________
Useful Links -or- When All Else Fails:
The Guide to Understanding OSCAR
OSCAR Chart Organization
Attaching Images and Files on Apnea Board
Apnea Helpful Tips

INFORMATION ON APNEA BOARD FORUMS OR ON APNEABOARD.COM SHOULD NOT BE CONSIDERED AS MEDICAL ADVICE. ALWAYS SEEK THE ADVICE OF A PHYSICIAN BEFORE SEEKING TREATMENT FOR MEDICAL CONDITIONS, INCLUDING SLEEP APNEA. INFORMATION POSTED ON THE APNEA BOARD WEB SITE AND FORUMS ARE PERSONAL OPINION ONLY AND NOT NECESSARILY A STATEMENT OF FACT.
Post Reply Post Reply
#3
RE: OSCAR: Questions regarding a potential import for Garmin data
(10-19-2024, 10:03 AM)Crimson Nape Wrote: Have you looked at the Somnopose loader?  It parses a CSV file.
- Red

yes, I have look on different loaders. I had already written a Python program that transforms the garmin data into Zeo and md300w1/somnopose files. But handling so many files is no fun.
And in the end, every file format had its limitations and problems.

My main "concerns" are that each loader only supports one machine type and I am not sure what role the machine types play in OSCAR or how I can implement a loader that would fill so many channels over different machine types.

I hope that one of the developers can say something about this.
Post Reply Post Reply
#4
RE: OSCAR: Questions regarding a potential import for Garmin data
any progress on the Garmin import?

I've been experimenting with getting the data from the garmin api too ... didn't get far on the formatting in e.g. .csv yet...
Post Reply Post Reply
#5
RE: OSCAR: Questions regarding a potential import for Garmin data
[I'm not allowed to post links]
Hi

I have a working fork of Oscar where you can import Garmin data.
Currently you have to run a Python programme which generates data and which you can later import into OSCAR.

github.com/littleyoda/oscar/tree/garmin

And the issue in the gitlab repository:
gitlab.com/CrimsonNape/OSCAR-code/-/issues/5

As the approach works for me and no one has shown any further interest so far, I have not developed it any further.
I'm not sure if I really want to port relevant parts of the Python garmin connect library[/url] to C++.


Attached an example with movement and stress level from a garmin watch.


Attached Files Thumbnail(s)
   
Post Reply Post Reply
#6
RE: OSCAR: Questions regarding a potential import for Garmin data
I'm impressed!
Post Reply Post Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  ALL OSCAR data to Sleep doc... McBrugh 5 158 12-14-2024, 05:27 PM
Last Post: Sleeprider
Sad No more data import from prisma smart since1984 8 203 12-13-2024, 07:47 AM
Last Post: since1984
  OSCAR import from other oscar computer Olivier France 10330 0 82 12-10-2024, 01:19 PM
Last Post: Olivier France 10330
  Machines with max oscar data wking 3 291 12-09-2024, 04:10 PM
Last Post: SarcasticDave94
  Oscar crashes when importing Wellue O2 ring data Armorwolf 24 938 12-08-2024, 01:11 PM
Last Post: Crimson Nape
  Difference in data between Oscar and EncorePro xanatos 1 160 12-03-2024, 10:06 AM
Last Post: OpalRose
  OSCAR not recognising SD card data from BMC alid 8 1,067 11-25-2024, 03:45 AM
Last Post: Venkat2977


New Posts   Today's Posts


About Apnea Board

Apnea Board is an educational web site designed to empower Sleep Apnea patients.