Apnea Board Forum - CPAP | Sleep Apnea
Reading SleepyHead Binary Files - 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: Reading SleepyHead Binary Files (/Thread-Reading-SleepyHead-Binary-Files)

Pages: 1 2


RE: Reading SleepyHead Binary Files - TBMx - 05-26-2017

Rolleyes looks like 7:00 in the morning was way too early for me^^

forgot the types on this 2 in the header:
Quote:
PHP Code:
header << datasize// int32 - the size of the actual data AFTER the header in bytes.
header << chk// uint16 - checksum - should 0 - if it is not it is the checksum for the compression 

hope I did not forget something else .. or worse: made some mistakes^^

one more thing to make the c++-part more clear:
PHP Code:
(quint16)filetype_data

something like that is a typecast ... meaning it gets converted to the type in the brackets.
all QT-types are prefixed with a 'q' (basically they are the same as without the q ... it's just for making the code portable across different operating systems and compilers)
so quint16 = unsigned integer 16 bits
qint32 = (signed) integer 32 bits