Tips & Tricks: Computer Alarm Clock


I don’t have an alarm clock. I’ve been relying on my handphone alarm for the longest time. Recently, my handphone speakers decided to call it quits. That left me without an alarm to wake me up in the morning. Should I buy a clock? After thinking about it for a bit, I realised that since I leave my computer on during the night, I could turn it into an alarm clock. Here’s how you do it without having to install anything extra.

For the purpose of this writeup, I’m assuming that Windows is installed in C:\Windows. We’ll be using Window’s built-in task scheduler and media player as our alarm clock.

  1. Find a song or sound that is effective at waking you in the morning. You can use some of Window’s default sounds located in
    “C:\Windows\Media”. An effective sound is “C:\Windows\Media\ringin.wav“.
  2. Bring up your Windows Scheduled Task tool (Start » All Programs » Accessories » System Tools » Scheduled Tasks).

    Scheduled Tasks
    - Scheduled Tasks (Enlarge) -

  3. Double click the Add Scheduled Task icon to bring up the wizard for scheduling a new task.

    Scheduled Task Wizard
    - Scheduled Task Wizard -

    Click “Next” to continue.

  4. Locate and select Windows Media Player from the list applications.

    Application Selection
    - Application Selection -

    Click “Next” to continue.

  5. Name the task (e.g. Daily Alarm). Set the task to run daily (or weekly if you want the alarm to only go off on specific days).

    Alarm Frequency
    - Alarm Frequency -

    Click “Next” to continue.

  6. Set the time when you want the alarm to go off.

    If you chose a daily schedule, you have the option of setting the alarm to ring everyday, only on weekdays, or once after every fixed day interval.

    Alarm: 8:00AM Weekdays
    - Alarm: 8:00AM Weekdays -

    If you selected weekly schedule, you can specify the days when you want the alarm to go off (e.g. every Monday and Friday).

    Alarm: 8:00AM Mondays and Fridays
    - Alarm: 8:00AM on Mondays and Fridays -

    Click “Next” to continue.

  7. Set a user name (we’ll be disabling this later).

    Windows User
    - Windows User -

    Click “Next” to continue.

  8. Make sure the “Open advanced properties for this task when I click Finish” is checked.

    Finish
    - Finish -

    Click “Finish” to continue customising the task.

  9. A properties window will be displayed for the scheduled task. Make the following changes:

    Alarm Properties
    - Alarm Properties -

    • Append the following to the end of the “Run” field:
      /play “

      e.g. /play “C:\Windows\Media\ringin.wav”

    • Check the “Run only if logged on” option

    Click “OK” to apply the changes and exit the properties setting.

  10. Run Windows Media Player and set it to repeat indefinitely. The way to do this varies depending on the version of Media Player you are using. For Media Player 9, you enable repeat from the Menu, by selecting Play » Repeat.

Before going to sleep, simply switch on your computer and login as the specified user (e.g. for my case ‘gbyeow’). You must be logged in for it to work (the computer can be locked). Alternatively, you can provide the password in which case you don’t have to be logged in. If you decide to do the latter, make sure you deselect the “Run only if logged on” option in the task properties.

If you did it right, you’ll have an alarm ringing at the specified schedule without needing to install anything extra.

Related posts:
Script Tips: X11 Forwarding With SSH After Switching Users
Insomnia!
Haven’t they heard of User Friendly Interface!!!! HCI 101
April Is Malaysia Tax Month
The Madness Continues (Computer Woes)


6 Comments »

  1. Electromoss Said,

    April 25, 2007 @ 9:26 pm

    Dude! This trick works on a PC with the user logged in with Administrator privileges. It doesn’t work on a limited privilege account on a laptop.

    G: I’m using a laptop but with administrative privileges. Hmm… Let me rethink it. brb :)

  2. EngLee Said,

    April 26, 2007 @ 11:12 am

    You can further configure your BIOS to startup at a few minutes to start up itself, in case you want to turn off your PC.

    Anyhow, I can’t sleep with my PC turn on, although I have removed additional casing fans, it’s still making noise..

    G: I’m OK with the PC turned on. Your PC too powerful = too noisy :p

  3. empress Said,

    May 12, 2007 @ 2:17 am

    If you are online 24/7, then you could use this site http://onlineclock.net/. No installation. You just have to set it daily. Good for me cause when I’m on shift, I do not need to wake up at 6.30am every single day and to have to reprogram each time for the above would be a hassle.

    G: That’s pretty cool too :)

  4. Frederic B. Said,

    May 19, 2007 @ 11:21 pm

    I wrote a little script that I use with pretty much the same process as above, but interfaces with the itunes COM interface, to
    1 launch itunes
    2 select a playlist called “Alarm Clock”
    3 shuffle said playlist
    4 start playing

    For some reason I can’t seem to get it to tweak the volume level correctly, something’s wrong with my COM interface for it, or I am not translating the documentation to the commands, but with a little bit of tweaking I could figure out the problem.

    In any case this setup guarantees variety for me every morning, and I can select apropriately loud songs. I sleep like a rock, so having a both varied, and immensely loud alarm is neccessary. For awhile i had a single loud song just like above, but I got used to it quickly, just like I got used to my loud alarm clock, and just setting it to radio proved to be equally useless. Scheduled Tasks, Windows Scripting Host, VBS and Itunes are now my friends.

    G: Yeah. Getting used to the sound is a problem. After a while, you just don’t wake up to it anymore…

  5. Electromoss Said,

    July 5, 2007 @ 4:53 pm

    I think low tech does the trick quite nicely! Just get an array of 10 or 20 pasar malam* clocks and make sure you keep your rechargeable batteries** fresh. This innovative and environmentally friendly solution would make TNB*** a bit upset though, when they learn that your desktop PC usage is down.

    Oh yeah. Put your alarm clocks all over the house, and find a way to videocam yourself when they all ring in the morning. Hahaha! :D

    * Malaysian Night Market. Awesome experience!

    **Hmm. Would cost quite a bit wouldn’t it. 1 pack of 4 rechargeable batts = RM25+. 10 clocks @2 batteries each = RM63. Plus the discipline to actually charge the batts & have enough chargers/power points (not the M$ one)…

    Still, it’s cheaper than spending time writing & debugging a COM server!!! Plus deploying WSH automation (which is only possible in Administrator mode) is dangerous stuff, Frederic B! It’s better to compile a Java CNI .exe using gcj (Cygwin) and using cygrunsrv (Cygwin’s NT service manager) to set the .exe to run as a service in a Guest account.

    *** Malaysia’s Semi-Privatised Electricity Monopolist

  6. Joey Said,

    May 23, 2009 @ 1:03 pm

    I have been using http://batchalarmclock.blogspot.com/ for my alarm clock. I like it because it’s simple and it uses the computers built in speaker to beep. This is useful because I don’t have external speakers that work. That would have made it hard to use this program.. LOL

RSS feed for comments on this post · TrackBack URI

Leave a Comment