There are numerous DIY projects available that allow you to monitor your brain waves and store them on your mobile device or PC. Combine one of these with a little (famous last words) software and it should not be hard to recognize sleep patterns. Combine all that with Sleepyhead and you would have what you want. I expect a Raspberry PI or an Aurdino would be sufficient to do the processing and you then wouldn't need to have a PC involved.
The biggest concern in this would be for safety, since it would be tempting to avoid batteries and plug in a power pack into a wall socket which is an almost absolute NO-NO because of the possibility of a short in the power supply running 120AC (in the US) through your brain, which would be unpleasant to put it mildly.
I will do some googling and get back if I find anyone that has already done all the heavy lifting to build it. Price should be around $100 for all the parts.
I made a post earlier in this tread about having low confidence in the data. I was frustrated over what I know now is Sleep wake junk. I have used a sleep AP on my smart phone and a heart rate monitor on my wrist. Then compared the data form these devices to the flow rate data in sleepy head and I have identified the sleep pattern in the flow rate data that tells me when I am a sleep. The hard part is my smartphone AP only work s well if a wear a shirt with a pocket over my hard and sleep on my bake without rolling over. I still cant identify rem sleep, although I have period when my hear rate drop significantly in my sleep.
Once you learn how to factor out the sleep wake time from the actual sleep time. You will know your actual sleep time
it'll take more than a doctor to prescribe a remedy
Observations and recommendations communicated here are the perceptions of the writer and should not be misconstrued as medical advice.
I find the breaths per minute graph helpful. I can see (on the graph) my breathing slowing down and when it levels off I was likely asleep. And when it later jumps around for awhile I was dreaming (if I wake up while it is jumping around I remember the dream). So looking at that graph seems to give me a pretty good indication of how my night went. I find it easier to interpret than the flow graph so far as when I am sleeping, dreaming, or awake.
The above is my opinion. It is just possible that I may, occasionally, be mistaken.
I am neither a Doctor, nor any other kind of medical professional.
Everything put together sooner or later falls apart.
Your brain is not the boss.
Our forefathers took drugs.
He's no fun he fell right over.