Idea/Prototype: DreamLamp.

Well, I was planing to make a DIY LD mask this weekend, but I changed my mind once I got the lights I was going to use. Ideally the lights would have been dim (so as not to wake me up), but the ones I chose were f***ing bright (7000 mcd, to be exact [see note]). This gave ma an idea: The DreamLamp. You place it on your bedside, and it waits for about 5 hours after you go to sleep, then flashes 5 times every 5 minutes. the light is bright enough for you to see it in bed. I tested my prototype in a dark room, from an arms length away, and I could see the light through closed eyes. The lamp approach also has the advantage of not being uncomfortable to wear, as it sits by your bedside, unlike a mask. It doesn’t need to detect the stage of sleep, due to the timer.
What do you think about this idea?

NOTE: 7000 mcd = 7 × luminous intensity of a typical common candle (Credit: Wolfram|Alpha)

Some notes about the cost:
If you were to make it at home, it would cost about $25 - 30 USD.
If I were to sell them (I don’t plan to), they would cost about $7 - 10 USD.
The price difference is due to the fact that you need a ~$21 arduino to program it, but to run the code, all you really need is a ~$3 ATtiny chip.

TECHNICAL NOTES:
The DreamLamp consists of the following parts:
An Arduino Duemilanove (but any Arduino will work :smile: )
A 7000 mcd white LED
I am not yet using, but will include the following parts:
2 Switches
A project housing
A battery of some sort
An ATtiny?

And here’s the code (Spoiler’d for length):

[spoiler][code]
//If you need a license, use the WTFPL. It’d be nice if you showed me your changes though!
//Place a LED on pin 12. Enjoy your LD’s!
boolean remwaitover = false;
int blinktime = 300000; //in milliseconds, the time between blinks. 300000 == 5 mins.
int naptime = 2700; //the number of seconds it will wait for if you press the ‘nap’ button. 2700 == 45 mins.
int remwaittime = 18000; //in seconds, to stop an int overflow during the REM wait. 18000 == 5 hours.
int blinks = 5; //Number of times it will blink each blinktime.
int indblinktimes = 500; //how long each blink lasts in milliseconds.
int outpin = 12; //The led pin. @TODO: Add multi pin support.

void setup() {
pinMode(outpin, OUTPUT);
}

void loop() {
if (remwaitover)
{
delay(blinktime);
for (int i = 0; i < blinks; i ++)
{
digitalWrite(outpin, HIGH);
delay(indblinktimes);
digitalWrite(outpin, LOW);
delay(indblinktimes);
}
}
else
{
for (int i = 0; i < remwaittime; i ++)
{
delayonesec();
}
remwaitover = true;
}
}

void delayonesec() //Used to stop a int overflow during the REM wait. Pauses the script for 1 second.
{
delay(1000);
}[/code][/spoiler]

This actually might work

Sounds like a good idea, but what if you’re facing the wrong way when the lamp starts flashing?

Building on Eterna’s remark (I also think it’s a good idea) what would happen as well if you like to sleep with a pillow over your eyes because nearly ANY light is enough to keep you awake? (Speaking from experience here, the slight light coming in under the door and the natural luminescence of a room due to moonlight is almost always enough to keep me up longer than I want to. :razz: )

Facing the wrong way might be an issue, but I almost always wake up on my left side or my back, so I would place the lamp to the left of my bed. If you can predict the way you willl be facing, it shoulden’t be to much of a issue.

If you sleep with a pillow over your head, then a mask is probably a better idea.

Hopefully I’ll be able to test it this weekend. I just need to get the right batteries for my arduino, then I’ll be able to use it :smile:

Well, I got a 9V battery hooked up (It turns out that the arduino duemilanove has a onboard voltage regulator), here’s a gif of the prototype (Spoiler’d for size) :

SPOILER - Click to view


Animated version here

All that it is so far is a arduino, a LED, a switch, and a 9V battery.

Here’s a breakdown of what I’ve programmed it to do:

1.) Wait for 5 hours.
2a.) Wait 15 minutes.
2b.) Blink 3 times.
3.) If you press the switch at any point during the 15 minute wait, then wait for 45 minutes before blinking again.
4.) Go to 2.

Wish me luck in testing it tonight! :smile:

Sorry for not getting back to this sooner :sad:

Here’s what happened so far:

The light woke me up most of the time. Apparently people are very sensitive to light when they are asleep. I’m trying various LED/resistor combos, but only testing it on the weekends, otherwise I’m to tired when I wake up. :sad: Hopefully soon I’ll have a good brightness level for me, and maybe even a variable light control knob! :smile:

White LED is bad, AT LEAST 1W red LED pointed ANYWHERE will be much better, because red light can penetrate eyelids easily, and 1W would shine in whole room. And light should blink while you’re in REM. Stephen LaBerge did something similar, he had a mask with red diodes and senors that was checking eye movement (REM phase). He wrote in his book that it was kinda succesful MILD hybrid.

Yeah, I’m trying with various white and red LED’s, but the red ones tend to work best, despite not being as bright. I’m not sure if led’s are measured in watts though, I’ve always seen them measured in mcd. I tried converting “1 Watt to mcd” in WolframAlpha, but it said that mcd and watts are not compatible. The other problem with leds is the viewing range. If you turn it more then 15-30 degrees away from you, it takes the brightness WAY down. The leds CAN wake my up though, if I’m staring straight at them, so they probably need to be less bright if anything.

The “Flashing during REM” is not necessary, as proved in Nate True’s lucid dreaming mask. I can’t link to it because it’s selling stuff, but here’s how he explained it:

Thanks for your feedback!