Apnea Board Forum - CPAP | Sleep Apnea
AirMini Travel Data Extraction & Teardown - Printable Version

+- Apnea Board Forum - CPAP | Sleep Apnea (https://www.apneaboard.com/forums)
+-- Forum: Public Area (https://www.apneaboard.com/forums/Forum-Public-Area)
+--- Forum: Software Support Forum (https://www.apneaboard.com/forums/Forum-Software-Support-Forum)
+--- Thread: AirMini Travel Data Extraction & Teardown (/Thread-AirMini-Travel-Data-Extraction-Teardown)

Pages: 1 2


RE: AirMini Travel Data Extraction & Teardown - JohnHedge - 05-15-2019

(02-27-2019, 12:03 AM)JimIve Wrote: The 256KB FRAM contains a FAT12 filesystem, but doesn't contain the sleep data (having some communication errors which need to be knocked down so I haven't seen every "page" on there yet, but it appears to be just settings and a journal file) and some DATALOG files (which don't contain sleep data), and the FRAM would be too small:

Code:
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 DATALOG
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 ERRORLOG
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 SETTINGS
-rwxrwxrwx  1 unknown  staff  16384  1 Jan  2012 journal.jnl

./DATALOG:
total 296
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 .
drwxrwxrwx@ 1 unknown  staff  16384 26 Feb 21:55 ..
-rwxrwxrwx  1 unknown  staff   5120  1 Jan  2012 AEE.EVN
-rwxrwxrwx  1 unknown  staff  26880  1 Jan  2012 BAE.EVN
-rwxrwxrwx  1 unknown  staff   3840  1 Jan  2012 BEE.EVN
-rwxrwxrwx  1 unknown  staff   6400  1 Jan  2012 DAE.EVN
-rwxrwxrwx  1 unknown  staff  33280  1 Jan  2012 DAF.EVN
-rwxrwxrwx  1 unknown  staff   5120  1 Jan  2012 ELV.EVN
-rwxrwxrwx  1 unknown  staff   3840  1 Jan  2012 FAE.EVN
-rwxrwxrwx  1 unknown  staff  26880  1 Jan  2012 RAE.EVN
-rwxrwxrwx  1 unknown  staff   6400  1 Jan  2012 REE.EVN
-rwxrwxrwx  1 unknown  staff   5120  1 Jan  2012 SRE.EVN
-rwxrwxrwx  1 unknown  staff   6400  1 Jan  2012 XSE.EVN

./ERRORLOG:
total 34
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 .
drwxrwxrwx@ 1 unknown  staff  16384 26 Feb 21:55 ..

./SETTINGS:
total 60
drwxrwxrwx  1 unknown  staff   1024  1 Jan  2012 .
drwxrwxrwx@ 1 unknown  staff  16384 26 Feb 21:55 ..
-rwxrwxrwx  1 unknown  staff     27  6 Aug  2017 AGL.set
-rwxrwxrwx  1 unknown  staff     23  6 Aug  2017 AHL.set
-rwxrwxrwx  1 unknown  staff     80  1 Jan  2012 BGL.set
-rwxrwxrwx  1 unknown  staff    345  1 Jan  2012 BTP.set
-rwxrwxrwx  1 unknown  staff     20  6 Aug  2017 CGL.set
-rwxrwxrwx  1 unknown  staff    325  1 Jan  2012 DID.set
-rwxrwxrwx  1 unknown  staff     28  6 Aug  2017 EGL.set
-rwxrwxrwx  1 unknown  staff   1038  1 Jan  2012 MCF.set
-rwxrwxrwx  1 unknown  staff     28  6 Aug  2017 MGL.set
-rwxrwxrwx  1 unknown  staff     54  1 Jan  2012 MML.set
-rwxrwxrwx  1 unknown  staff     48  6 Aug  2017 PGL.set


The SPI Flash seems to contain the sleep data, but I'm stumped as to the format.  Anyone have a clue how they're storing the sleep data?  They use "FS NOR" repeatedly at the beginning of every page, but I couldn't find a match on the flash file format.  Anyone familiar with SleepyHead have any ideas about this?

I just took a quick look at the SPI NOR data you posted and am trying to make sense of the data. There is a small header and then a bunch of records but no index or table of contents present that I can see. I'm thinking that maybe they're using the FRAM to keep track of this bookkeeping information such as where to write next, etc...

Can you upload the FRAM contents as well? I think the journal might contain some helpful clues.


RE: AirMini Travel Data Extraction & Teardown - JohnHedge - 05-15-2019

What I've been able to suss out so far is that the first 32 bytes of the file appears to be some sort of header which is then followed by N records of 368 bytes (0x170) each which appear to consist entirely of signed 16-bit values. I tried to interpret a bunch of the values as some standard time formats but none of them appear to make sense. This pattern does break down partway through the file, so hopefully other sources of information can shed some light on it.

I think the journal file from the FRAM might be helpful in finding timestamps or other metadata for the records stored in the SPI NOR.


RE: AirMini Travel Data Extraction & Teardown - snorult - 06-14-2019

This is excellent work @JimIve and others


RE: AirMini Travel Data Extraction & Teardown - Gideon - 06-14-2019

ResMed has used EDF Plus for it's File formats on the SD cards. The file doesn't look like that format though.

https://www.edfplus.info/


RE: AirMini Travel Data Extraction & Teardown - lemonbomb - 06-15-2019

wow this is amazing, good luck and wish that ResMed made at least a microsd for mini. This is one of the main reasons why I decided against the mini and so many proprietary items.


RE: AirMini Travel Data Extraction & Teardown - yrnkrn - 06-17-2019

Impressive work!


RE: AirMini Travel Data Extraction & Teardown - sedelstein - 08-28-2021

Hi! Haven't posted in a while. I just bought an AirMini to replace my Respironics FoamStation. I like the little machine, but, like so many others, am incredulous that there is no way to get the data out of it. Looking for a way to do it, I landed here and read the fantastic work described in this thread. One of the two, the work or the thread, seems to have ended abruptly several years ago. Is anyone aware whether this work continued, and whether the code to the file format was ever cracked?? Thanks!


RE: AirMini Travel Data Extraction & Teardown - MasterW - 12-03-2022

@JimIve - thanks for all the work you’ve put into this. I can’t help but notice you seem to be quite good at electronics and coding.  I’ve been searching for awhile now to try to find a solution that eliminates the need for proprietary chargers. This isn’t such a big deal if I’m at home since my machine is always plugged in and doesn’t move but for traveling, it would be great if I didn’t need to bring my CPAP power supply. 

I haven’t seen this done anywhere but have you ever considered getting rid of the proprietary power connector and replacing it with a USB C female tip so users can leverage the convenience and power delivery of USB C?


RE: AirMini Travel Data Extraction & Teardown - Crimson Nape - 12-03-2022

Hi MasterW!  -  Welcome

The OP's profile shows he hasn't been back on the board since September 2021.  Since your question deals with a different subject, you may have better luck creating your own thread for your inquiry.  

- Red