123
submitted 3 months ago by Lofenyy@sh.itjust.works to c/linux@lemmy.ml

Hey guys, I just wanted to let you know about a crowdfunding campaign I'm doing for a mobile Linux sleep tracking app. Please tell me what you think!

you are viewing a single comment's thread
view the rest of the comments
[-] solrize@lemmy.world 7 points 3 months ago

Wait, this is a pure software app? I don't have much expectations for it in that case. But, you can get pulse oximeters with bluetooth and reverse engineer the protocol. I think to do sleep tracking for real, you want EEG sensors. Look up OpenEEG for a hardware effort.

[-] Lofenyy@sh.itjust.works 3 points 3 months ago

I think I understand, I'm not aiming for perfect here. I will never expect to get the results as dead accurate as an actual clinical type 1 polysomnographic session. That being said, so much can be inferred with so little data to go off of.

Some sleep trials use portable machines nowadays that the user wears to bed at home. While they're equipped with objectively better sensors, it's hard to lose hope in my app. I know this has been done before, there are paid apps for polysomnography for Android. Typically they'll have oximeters at the worst and the same equipment as a type 1 at best. With our phones, the goal isn't so much to diagnose as it is to evaluate changes over time, and alert us if something seems likely.

I'll definitely think about bluetooth pulse oximeter support, but please keep in mind that I'm hacking away at it for less than minimum wage.

[-] solrize@lemmy.world 2 points 3 months ago

There are also wristbands with accelerometers used for sleep tracking. That might be better than strapping phone to yourself, plus they can measure heartbeat. For polysomnography do you also want to measure respiration? That is yet more hardware, but EEG seems like the big step past stuff like Fitbit, which is supposedly not very good. I am a bit interested in this stuff though haven't tried it. I don't think I'd bother with a phone app.

[-] Lofenyy@sh.itjust.works 1 points 3 months ago

It's good to have options. This app isn't about perfect, it's about good enough. I will admit that I do wish that I had spent a few more days researching this project prior to launching it, but I nevertheless feel reluctant to file this one as a mistake. Soon, I will have obligations to hold up, and I plan on doing my best. I feel that I can serve a community of users who may be suffering from a range of sleep disorders or perhaps mental or physical illnesses, who may benefit from multi-night polysomnography, but cannot afford to acquire such hardware, or even more unobtainable, the expertise of a technician. I'm someone who already does fall into this category. As such, I want to do as much as possible, with as little as possible.

Breath tracking (respiration) via amplification, noise filtering and then multi-band-pass filtering incoming audio data from the microphone is a huge trove of data already. The hard part of that will be listening for changes in the volume of breathing, which is very significant data.

Maybe one day, I will create a DIY free software type whatever polysomnograph, but that's likely going to cost people a lot of money to make themselves.

The primary benefit of a real sleep study is that a technician interprets your data. In both this case and the fictional DIY kit, the data is interpreted for you automatically via software. The primary drawback is accessibility, cost, and the requirement of a technician.

EEG is reserved for type 1 tests, which are the absolute best, but don't really make practical sense to me as a mobile phone app. Those who need a type 1 test may benefit from an actual DIY kit, but then this only makes sense if the user doesn't have public healthcare coverage, and the kit isn't likely to benefit the user past night one unless they're using it for therapy, and if they are, they're definitely going overkill.

Again, my focus is on utilizing existing hardware, and replacing the need for a tech. Give everyone a sub-par but universally accessible option, completely free.

[-] solrize@lemmy.world 2 points 3 months ago

I thought part of the breath monitoring was measuring CO2 which doesn't seem doable without special hardware. Otherwise using the microphone is clever. Anyway you know more about sleep monitoring than I do. But I'm still having trouble understanding what this app is supposed to do or how it can beat a wristband style monitor.

[-] Lofenyy@sh.itjust.works 2 points 3 months ago

Oh, no haha. That would be pretty neat though.

I think you'll come to understand and appreciate it once I implement it. The crux of the app is that it mostly is responsible for tracking data over multiple sleeps, both subjective and objective. As a mere data tracker and interpreter, it doesn't "beat" a wristband monitor, it actually complements them, because they can be paired together, but this is a feature that wont be added until later on.

Depending on the wristband, in my experience, the data isn't always reliable. The Pinetime is much better than it used to be. Some wristbands track more than just pulse even, also tracking oxygen saturation, which is very handy.

Step one is just tracking useful user-provided data points. Step two is respiration tracking via the mic, by far the most useful feature in my opinion. While it's only one metric, and it can be messed with, and the quality isn't always perfect, the amount of inferred data is huge. Step three will be getting the accelerometer going, which I don't think is too useful for me, but it's a highly requested feature. The trick isn't to strap it to yourself, but to let it rest on your bed with you. The phone moves when you do. You may also put it in your pocket, but I don't think I'd recommend that because you'll definitely want to keep it connected to a charger. The (sum of the absolute value of the) little jiggles it'll detect can always be scaled up and down, or weighted differently on a per-user basis. Step four, getting paired hardware online. Step five, (with extra funding), might involve actually researching the hardware and techniques used in sleep analysis, building a type whatever-I-can-afford DIY kit, and optimizing how well the app works overall when working with clinical data/hardware.

One last thing, if you don't already own a smartwatch and cannot afford one but want to track sleep data, but you do own a mobile Linux phone, then it makes far more sense to either track your metrics yourself via pencil and paper, or plug some data into a tracking app.

load more comments (3 replies)
this post was submitted on 04 Aug 2024
123 points (97.7% liked)

Linux

48056 readers
711 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS