Lullabye

lullabye128pxob4.png

Introducing Lullabye. A simple to use application for putting your monitor to sleep. No fancy frills, just straight to the point.

Set up a hotkey, press it, and watch as your screen fades to black before your monitor shuts off. To get your screen to turn back on, simply move the mouse, click a button on the mouse, or press the hotkey and watch as the screen fades back in. It's that simple.

.Net 2 Framework needs to be installed in order for Lullabye to work. Download from Microsoft.com if you do not already have it.

Download from here.

#451849

You did it again Cal! Long time no talk. :)

#451850

Nice and simple.

Tested under Vista : works well except no fade for the secondary screen (well vista does a fade anyway)

#451858

uhm, let's specify - requires .NET :slant: pity

#451860

Nice and simple.

Tested under Vista : works well except no fade for the secondary screen (well vista does a fade anyway)

Ahh, wasn't sure how it would go for multiple monitors. Don't have a second one to test. Will try and see what is going on and go from there.

uhm, let's specify - requires .NET :slant: pity

Right, sorry...should have mentioned that. .NET 2 framework needed.

#451863

this is awesome. i was just about to post a new post for something similar to this.

#451868

this is awesome. i was just about to post a new post for something similar to this.

Glad you like it mate.

#451870

If anyone wants to test out the multi-monitor support (which should work now, recoded it and everything...) let me know through PM.

Suggestions and bugs are welcome. :)

#451873

Ahhh :D I love those small gimmick apps! Thank you so much for this!

#451875

OMFG thank you! You're amazing, man.

#451880

Hey thanks Sranshaft, I can't express my delight at having such a proactive response to my request. You and Ave (thanks Ave!) rock for such ^^

I have a multimonitor setup so having your app multimonitor friendly will be exactly perfect. Could you also, if not already, have a countdown timer (independent of mouse inactivity) to put the computer monitor to sleep? For instance, I could configure a hotkey to do one of two scenarios:

1) pop up a dialog window asking in how many minutes and which monitor(s). I enter 60 (min) and check monitor (left) and enter 1 (min) and check monitor (right)

2) another hotkey assignment would activate a precreated 'profile' (immediately turn off (left) Monitor, and turn off (right) monitor after 120 (min).

Reason: I sometimes (often actually) fall asleep to a movie and when I do, I like to be able to watch the film on one monitor while having the other one 'off.' then after the film ends, have the last monitor turn off as well. This functionality would be perfect to this end and I think would make your .net app unique amongst other utilities of this nature.

The question is, can this degree of specificity be achieved with .net?

The only trick I'd envision is design decisions like: if one monitor's put to sleep instantly, while the other is on a countdown timer, then mouse movement should not interrupt either monitor states (or pending states.) So perhaps, the 'esc,' or 'F6' button should bring the monitors out of sleep state.

Or even cooler yet.. with mouse movement, (currently turned off) monitors fade in only partially, so you'd have a dimmed monitor which you can see the desktop for 10 secs after mouse movement stops then the monitor would fade 'off' again. This of it as a preview where Lullabye is still activated (unless 'esc' is hit,) and will continue the countdown or maintain the monitor's induced state.

Also, if the computer is restarted while monitors are in the sleep state (by Lullabye,) upon reboot, they should be restored to normal state. (I'm sure this is already the case :) )

This app could then be pitched to the multimedia/home theatre fanatics ;)

hope some of these suggestions are found to be useful, also, would love to hear if any of these requests could be achieved *crosses fingers*

I look forward to the multimonitor friendly version.

regards

#452026

firecracker : due to the way windows handles it, and the way the app can tell windows to shut down the screens, I don't think delayed shut down is possible, Windows doesn't take any argument wich can specify the screen to shut down :/

Windows enable the screens automatically when you move your mouse, but I really think your (great) idea of shutting it off again after 10 secs by detecing any input. I find it quite annoying when I sleep that some apps just wake up the screen with max brightness (that destroyed my eyes 10 times).

Maybe something that puts to the logon screen after x mins of inactivity (yeah you could put a screensaver that will just not appear I know but this would be better and faster to set ;) )

#452030

hehe, thanks for all of those suggestions. I'll see what I can do to implement them all. I think I've gotten the multi-monitor support working. Can't try it myself as I don't have that sort of set up but it should, theoretically work. At least it should code-wise. In actual practice, is an entirely different ballgame.

I've added in hotspot support - move a cursor to the corner and it'll set off the sleep state. I should be able to upload this new version tomorrow.

I'm pretty sure I can do most of your requests. I know I can definitely add in the preview feature and the countdown - though it'll take a little more work to get the monitors shutting down independently of each other. As it is, it simply loops through each screen. I'd have to separate this code...will have to map it out. The idea of a timer should be easily done - first as a global event and once I get that working it shouldn't be too hard to separate it for multi-monitors.

The monitors should come back on if rebooted so that shouldn't be a problem.

I'll keep you informed with the progress. :)

Edit: In response to Dream_Team's comment. While Windows doesn't allow a specified time, I could use a timer as a dirty workaround basically telling it to fire the monitor shutdown code after a certain amount of time. It's the only way I can think of at the moment.

#452031

Whata contradictory answers xD (starts his researches on the windows functions again)

I think an intresting feature would be do to the reverse of what it actually does : prevent the screen to power off

It should be possible with an hook dll

#452032

.Net 2 Framework needs to be installed in order for Lullabye to work. Download from Microsoft.com if you do not already have it.

Is it too difficult to do without it or is that .Net helps to fashion apps like these that .Net is required for some programs to perform.

Thnx.

#456766

In case no one got that, I believe he's asking if this could have been developed in another program language? I'm wondering the same thing... even on high-end computers .NET is rather slow to start up. Why is that?

#456809

.NET is just simplier to code.

It's like me, I use a proprietary Dev environnement (with it's own language, Windev is it's name) with an heavy framework ( ~8 mb of dll if i include them all) but then you have simplified things :

- Easier Outlook interfacing, etc ...

- Very powerful database system integrated, etc ...

.NET is a Framework for easier developping so you don't spend too much time on basic functions and get a running program faster.

BTW , .NET runs fast here.

--------------------------

Maybe you can command line parameters too.

For the 10 seconds no input for automatic screen shutdown , I suggest checking "GetLastInput" of user32.dll after a certain amount of time.

BTW , by "delayed" shutdown, I meant that you just could fade one screen to black after a timer, since Windows doesn't allow to shutodwn only one of the two. And when the 2nd screen finished fading to black, call the Shutdown code.

#456917

@Dream: Damn, that sounds like a pretty easy way to go about that Dream. I've been pretty slack in updating Lullabye. I'll need to get back to it. I've got the groundwork done for the timed shutdown, added menus in the system tray to control each monitor (provided there are multiple monitors to control...) but your idea would work as well. Did you have a go with the dual-monitor support version I sent you?

Not exactly sure on what you mean by "10 seconds no input for automatic screen shutdown". If it's what I think it is and it's a feature to auto-shutdown the screen, kind of like what the screen saver does (after 10 minutes, etc...it kicks in) that should be pretty easy to do and I'll add it to the list of features to add.

What sort of features would you want to see command line parameters used for?

As for why I chose .Net...Dream's correct. It's easier to get to the meat of the program instead of having to fiddle with every little thing. The framework seems to run fast for me as well. Never had any 'real' issue with it though it can be a little high on the memory-side - the joys of having the ease of .net. I wish they'd condense it to a single service that each program would then run on top of.

#456925

Well, as for my speed complaints, Lullabye does open slower than Firefox, which is pretty rare. And my computer is NOT crappy :P.

Also, Sranshaft, can you add the same functions for turning off the screen to activating the screensaver? (i.e. a keyboard shortcut). When I'm plugged in, saving battery isn't an issue and i like showing off Flurry :D.

Maybe you could even go as far as giving the user the ability to customize actions when it is plugged in, on a battery, etc.

Further suggestion, though I'm not asking for it, you could replace the Power Options control panel completely. ;)

#456967

Well for .Net, Microsoft is doing things so it it's nativer and nativer so one day it will be good :)

Since internet will be back when I go back home (in 2 days), I will test the version (I have dled it but I had no way to transfer from my Mac partition to the Vista one :P) you sent.

About the 10 seconds story :

- Sometimes an app or I (by taking something on the desk, or just a cat walking on it, ...) wake up my screen by moving the mouse / pressing keyboard.

It would be good taht if Lullabye detects an input (again, check GetLastInput , if it's value is < to the old one, then the mouse moved / keyboard pressed), and then no more input for 10 or 30 seconds (make it a setting) it will assume it was accidental and shut down the screen again.

Just like when OS X is sleeping, if it's woken up and then not having any input for X time, it will Hibernate again.

#456968

Ahh, yeah, cool feature idea. I'll see what I can do and get that working in the next build.

No problem on the testing ;) And it's good to hear that Microsoft is working towards something at least. They always seem to be trying to reinvent the wheel by adding in more square parts... :P

#457067