Support Apnea Board & OSCAR  

Difference between revisions of "S9 Data Format"

From Apnea Board Wiki
Jump to: navigation, search

m (Identification.tgt)
m (Identification.tgt)
Line 45: Line 45:
 
! Code !! Remark !! Explanation
 
! Code !! Remark !! Explanation
 
|-
 
|-
| #IMF|| Example || Example
+
| #IMF|| All later models || Example
 
|-
 
|-
| #VIR|| Example || Example
+
| #VIR|| All later models|| Example
 
|-
 
|-
| #RIR|| Example || Example
+
| #RIR|| All later models|| Example
 
|-
 
|-
| #PVR|| Example || Example
+
| #PVR|| All later models|| Example
 
|-
 
|-
| #PVD|| Example || Example
+
| #PVD|| All later models|| Example
 
|-
 
|-
| #CID|| Example || Example
+
| #CID|| All later models|| Example
 
|-
 
|-
| #RID|| Example || Example
+
| #RID|| All later models|| Example
 
|-
 
|-
| #VRN|| Example || Example
+
| #VRN|| Only S9 Models || Example
 
|-
 
|-
| #VPC|| Example || Example
+
| #VPC|| Only S9 Models|| Example
 
|-
 
|-
| #NID|| Example || Example
+
| #NID|| Only S9 Models|| Example
 
|-
 
|-
| #VID || Example || Example
+
| #VID || All Models || Example
 
|-
 
|-
| #SRN|| Example || Serial number
+
| #SRN|| All Models|| Serial number
 
|-
 
|-
| #SID|| Example || Example
+
| #SID|| All Models || Example
 
|-
 
|-
| #RID|| Example || Example
+
| #RID|| Only S9 Models || Example
 
|-
 
|-
| #PNA || Example || Example
+
| #PNA || All Models || Example
 
|-
 
|-
| #PCD|| Example || Example
+
| #PCD|| All Models || Example
 
|-
 
|-
| #PCB|| Example || Printed Circuit Board number?
+
| #PCB|| All Models || Printed Circuit Board number?
 
|-
 
|-
| #MID|| Example || Example
+
| #MID|| All Models || Example
 
|-
 
|-
| #FGT|| Example || Example
+
| #FGT|| All Models || Example
 
|-
 
|-
| #BID|| Example || Example
+
| #BID|| All Models || Example
 
|}
 
|}
  

Revision as of 12:36, 8 July 2020

Full-48.png

Afrikaans / في الصفحة / български / 中国 / 臺灣 / čeština/ Dansk / Deutsch / Ελληνικά / Español / Filipino / Français / עברית / Magyar / Italiano / 日本語 / 한국어 / Nederlands / Norsk / Polskie / Português / Română / Pусский / Suomalainen / Svenska / ภาษาไทย / Türkçe
--> Do not use these buttons when you are on a translated page. Just close this tab to go back. <--

ResMed Data Format (Excluding S8 models)

This page was originally written by Mark Watkins, during the initial build of the SleepyHead program. It needs change in approach, or should be taken as "history".

Data format analysis

Grade: C (extra points awarded for being open)

Negatives

  • Only keeps basic summary data when the card is left out. NO graphs.
  • Unnecessarily deletes high-res flow waveform data after 7 days, all other graphs after 30 days.
  • Summary does not contain settings info for each session, only once per day, according to ResMed split, which is not suitable for night-owls.
  • Evil SDcard "drift" problem, which causes Events to NOT sync well over flow waveform. Needs a regular card format to work around this.
  • Bloaty data format.

Positives

  • Manufacturer chose to use an industry-standard data format.
  • Reasonable assortment of data available, and at a decent resolution.

ResMed Data Format for S9 and later models

ResMed chose an intelligent and sensible approach when designing their machines..

They used an industry standard. (Thankyou ResMed for showing common sense!)

EDF+ Format

ResMed uses the European Data Format Plus format.

This format is documented here

It is rather verbose, but sensibly designed..

The Event Annotations are a little tricky.

S9 SDCard Folder Structure

[DATALOG]            Folder containing all the session data
Identification.crc   Checksum info
Identification.tgt   Machine identification data
Journal.dat          tbd
STR.crc              Checksum info
STR.edf              All overall summary information

Identification.tgt

This file holds an extensive number of data and parameters of the machine.

Code Remark Explanation
#IMF All later models Example
#VIR All later models Example
#RIR All later models Example
#PVR All later models Example
#PVD All later models Example
#CID All later models Example
#RID All later models Example
#VRN Only S9 Models Example
#VPC Only S9 Models Example
#NID Only S9 Models Example
#VID All Models Example
#SRN All Models Serial number
#SID All Models Example
#RID Only S9 Models Example
#PNA All Models Example
#PCD All Models Example
#PCB All Models Printed Circuit Board number?
#MID All Models Example
#FGT All Models Example
#BID All Models Example

DATALOG Folder

The main data is stored in 4 EDF files per session, with each file name consisting of a date, time, and type, followed by .edf

There is also a .crc (checksum) file for each of the above, but they are not needed to parse the data.

Example

20110601_021922_EVE.edf
(date)_(time)_(type).edf

The 4 File Types

Type  Details
EVE    Event annotation data
BRP    High resolution graph data 
SAD    Pulse oximetry data
PLD    Low resolution graph data

File Type Notes

Note: Some foreign language machines use a different set of signal codes in the EDF data.

EVE Event Annotation Data

The S9 series flags the following events:

  • Hypopnea
  • Apnea
  • Obstructive Apnea
  • Central Apnea

BRP High resolution graph data

Code            Details                        Units                            Notes
"Flow"          Flow Rate                      ?
"Mask Pres"     High-res Mask Pressure         cmH2O
"Resp Event"    Respiratory Event              ?                                VPAP

SAD Pulse Oximetry data

Code            Details                        Units                            Notes
"Pulse"         Pulse Rate                     Beats per minute
"SpO2"          SpO2 (Oxygen Saturation)       % Saturation

The oximetry device that records this information is hideously expensive, notoriously unreliable, and ResMed should be ashamed for releasing it.

PLD Low resolution graph data

Signal List

Code            Details                        Units                            Notes
"Snore Index"   Snore Index                    ??
"Therapy Pres"  Therapy Pressure               cmH2O
"Insp Pres"     IPAP / Inspiratory Pressure    cmH2O
"MV"            Minute Ventilation             ?
"RR"            Respiratory Rate               Breaths per Minute
"Vt"            Tidal Volume                   ?
"Leak"          Leak Rate                      L/Second (I convert to L/Min)
"FFL Index"     Flow Limitation Index          ?
"Mask Pres"     Low-res Mask Pressure          cmH2O
"Exp Pres"      EPAP / Expiratory Pressure     cmH2O
"I:E"           Inspiratory : Expiratory Ratio ?                                VPAP
"Ti"            Ti??                           ?                                VPAP
"Te"            Te??                           ?                                VPAP
"TgMV"          Target Minute Ventialation     ?                                ASV Machines
""              Unknown Empty                  ?
""              Unknown Empty                  ?

most ? fields are known, I just have to look them up again..?? fields really are unknown (to me).

The two empty signals always appear at the end. not entirely sure of their purpose.

STR.edf

This file contains a summary database in EDF format. It contains things like AHI indexes, 95% values, etc...

There is only one copy, in the root directory of the SD-card, and it is updated at the end of a session.


Most records contain one entry per day.

SleepyHead doesn't need much of it, as it provides it's own indexing..

It does contain some data not available elsewhere, most notably EPR data.

ResMed S9 Storage Gotchas

The S9 continuously erases older data to keep the card from overflowing:

  • BRP data older than 7 days.
  • PLD data older than 30 days.
  • Everything older than 365 days.

Regularly backup copies of your SD card to work around this!

SleepyHeads Implementation

SleepyHeads EDF parser and S9 importer has been written from scratch

It consists of two parts

  • A generic EDF parser class named EDFParser
  • and the custom S9 importer class named ResMedLoader

It is implemented in SleepLib/loader_plugins/resmed_loader.cpp / .h




Donate to Apnea Board