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 -> InfluxDB -> Grafana
#1
OSCAR -> InfluxDB -> Grafana
Hello,

I'm fairly new to the wonderful world of APNEA, got my machine just a few months ago.. Smile

The clues led me here, and I've now bought a FlashAIR SD-card for my Airsense 10. I've also installed OSCAR on a virtualized Lubuntu and mounted the FlashAIR card in fstab as webdav. Everything works flawlessly. The thing is however, that I would like to automatically export the data to my own db (influxdb would prolly be best) and then use Grafana to graph the most important statistics.

I know you can manually export cvs-files but that defeats the purpose as I want the data to populate the database automatically. 

I have, however, no idea how to go about this. The options in OSCAR seems to be limited. Are there other software more suited for my needs? Have anyone else tried to do something similar (and succeeded Smile?

/Omygolly
Post Reply Post Reply



Donate to Apnea Board  
#2
RE: OSCAR -> InfluxDB -> Grafana
ResMed writes the cards using an EDF format. You can write a program to interpret that data directly. That is what OSCAR does.

If you manage to do this for devices that OSCAR does not currently support, please let us know.
Fred Bonjour - Project Manager and Lead Tester for OSCAR - Open Source CPAP Analysis Reporter 
OSCAR

Download OSCAR
New to Apnea? Helpful tips to ensure success
Soft Cervical Collar
Mask Primer
Dealing with a DME
Organize Charts
Attaching Charts

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 -> InfluxDB -> Grafana
I see. I'm unfortunately not a coder, so I won't be able to write a parser like that. 

I found a manual way to go about it:

1) Export everything to CSV
2) Use Bugazelle/export-csv-to-influx to export CSV to InfluxDB (using crontab and the --drop_database option would automate it) 

To make it totally automated the following additions would have to be made:

1) Auto-import SD-card data either on change or scheduled
2) Auto-export CSV scheduled times (overwrite enabled so the cronjob for export-csv-to-influx reads the same file)
Post Reply Post Reply
#4
RE: OSCAR -> InfluxDB -> Grafana
Is there anywhere one can request future enhancements (such as the ones above) to the OSCAR software developement team?
Post Reply Post Reply



Donate to Apnea Board  
#5
RE: OSCAR -> InfluxDB -> Grafana
(10-07-2019, 06:03 AM)omygolly Wrote: Is there anywhere one can request future enhancements (such as the ones above) to the OSCAR software developement team?

Yes, just mention it in this forum - the project manager and other members of the team read the forum on a regular basis. No guarantee that any particular request will be actioned soon as there is already quite a long list of things to be done.
DeepBreathing
Apnea Board Moderator
www.ApneaBoard.com


Bed

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
#6
RE: OSCAR -> InfluxDB -> Grafana
(10-06-2019, 03:46 PM)bonjour Wrote: ResMed writes the cards using an EDF format.

By the way, is EDF same as European Data Format?

https://www.edfplus.info/

https://en.wikipedia.org/wiki/European_Data_Format
Post Reply Post Reply
#7
RE: OSCAR -> InfluxDB -> Grafana
(10-07-2019, 10:26 AM)unidee Wrote:
(10-06-2019, 03:46 PM)bonjour Wrote: ResMed writes the cards using an EDF format.

By the way, is EDF same as European Data Format?

https://www.edfplus.info/

https://en.wikipedia.org/wiki/European_Data_Format


Long answer: Yes! Big Grin
Crimson Nape
Apnea Board Moderator
www.ApneaBoard.com
___________________________________
Useful Links -or- When All Else Fails:
OSCAR Chart Organization
Attaching Images and Files on Apnea Board
Beginner's Guide to Sleepyhead and OSCAR
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



Donate to Apnea Board  
#8
RE: OSCAR -> InfluxDB -> Grafana
We, the OSCAR team, are in the process of rewriting the Data read part of OSCAR.  We are mostly done with the PR portion and are actively working on the ResMed portion.

This is what we are trying to complete prior to the next release of OSCAR.  Eventually, this will lead to a redesign of the data that OSCAR uses.  Prior to this redesign, we need to have a full understanding of the data available from various machines. 

We have never considered an export of the "raw" data to an outside entity.
Fred Bonjour - Project Manager and Lead Tester for OSCAR - Open Source CPAP Analysis Reporter 
OSCAR

Download OSCAR
New to Apnea? Helpful tips to ensure success
Soft Cervical Collar
Mask Primer
Dealing with a DME
Organize Charts
Attaching Charts

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
#9
RE: OSCAR -> InfluxDB -> Grafana
Quote:We have never considered an export of the "raw" data to an outside entity.

Hi! Raw-data is not necessary, CSV would do fine as long as there was some way to schedule the exports (and preferably also enabling over-writing the same file). But that would pointless if there also wasn't a way to schedule imports of the SD-card. 

For example, import the sd-card at 12:00 daily, export the cvs 12:05 daily.
Post Reply Post Reply
#10
RE: OSCAR -> InfluxDB -> Grafana
Making the data accessible daily would mean that I could display the number of event on my Home Assistant dashboard for example, or have Alexa/Google read the report in the morning, or simply have a little RBG-light that shone red for a lot of events and green on a uneventful night.
Post Reply Post Reply



Donate to Apnea Board  


Possibly Related Threads...
Thread Author Replies Views Last Post
  OSCAR Download Question SideSleeper 10 166 7 hours ago
Last Post: DeepBreathing
  Restoring data Oscar to CPAP Greg Schultz 3 62 10-13-2019, 10:28 PM
Last Post: DeepBreathing
  OSCAR data size kongjie 0 46 10-12-2019, 12:23 PM
Last Post: kongjie
  OSCAR import of Dreem 2 CSV data slowriter 15 592 10-12-2019, 08:50 AM
Last Post: slowriter
  Building OSCAR happydreams 10 315 10-11-2019, 03:31 PM
Last Post: fredex
  Oscar on Ubuntu 18.04 fredex 5 98 10-11-2019, 11:07 AM
Last Post: happydreams
  Oscar Import larrygreg 2 90 10-08-2019, 07:36 AM
Last Post: DeepBreathing


New Posts   Today's Posts






About Apnea Board

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