Simple web alarm clock I decided to strengthen my "vanilla JavaScript" skills since I've lately been getting more into jQuery and just discovered the potential of node.js.

As a result, I decided to make a basic alarm clock in javascript and html. (Plus I needed an alarm clock).

Here's the Fiddle

// Load an alarm sound
    var sound = new Audio("http://www.freespecialeffects.co.uk/soundfx/sirens/alarm_01.wav");
    sound.loop = true;

// I just made this because It's easier to read.
getID = function(value){ return document.getElementById( value ); };

// List of all my objects im working with, and variables
var hour = getID("hour"),
    minute = getID("minute"),
    second = getID("second"),
    aHour = getID("aHour"),
    aMinute = getID("aMinute"),
    aSecond = getID("aSecond"),
    aSwitch = getID("aSwitch"),
    aOff = getID("turnOff"),
    refreshTime = 500,
    alarmTimer = null;

aSwitch.On = false;
aSwitch.value = "OFF";

// Turns the alarm off or on
function alarmSwitch(){
    switch( aSwitch.On )
    {
        case false:
            aSwitch.On = true;
            aSwitch.value = "ON";

            alarmSet();
        break;
        case true:
            aSwitch.On = false;
            aSwitch.value = "OFF";

            // CLEARS THE BEEPER 
            clearTimeout( alarmTimer );
        break;
    }
}

// Stops the alarm and closes the "stop button"
function disableAlarm(){
    sound.pause();
    aOff.style.display = "none";
}

//Fires the BEEPER noise, -- this is called from the alarmTimer timeout
function alarmFire(){
    if( aSwitch.On )
    {
        aOff.style.display = "block";
        sound.play();
    }
    else
        alert("error..");
}

/*This is how the beeper goes off:
 * It first checks the set time so the alarm can go to the 
 * next day without the user putting the date in.
 * The beeper goes off over the span of milliseconds difference.
 */
function alarmSet(){
    clearTimeout( alarmTimer );

    var tomo = false;// tomorrow.
    if( aHour.value &lt; hour.value )
        {tomo = true;}
    else if( aHour.value == hour.value &amp;&amp; aMinute.value &lt; minute.value )
        {tomo = true;}
    else if( aHour.value == hour.value &amp;&amp; aMinute.value == minute.value 
            &amp;&amp; aSecond.value &lt; second.value )
        {tomo = true;}

    var date = new Date(), year = date.getFullYear(), month = date.getMonth(), day = parseInt( date.getDate() );

    if( tomo ){day += 1;}

    time = new Date( year, month, day, aHour.value, aMinute.value, aSecond.value, date.getMilliseconds() );
    time = ( time - (new Date()) );

    // This turns the alarm back on if it's off when this function is called.
    if( aSwitch.On == false)
        alarmSwitch();

    alarmTimer = setTimeout( function(){alarmFire();} ,parseInt(time) );
}

// This is how the clock works
timeRefresh = function(){
    date = new Date();
    hour.innerHTML = date.getHours();
    hour.value = hour.innerHTML;
    minute.innerHTML = date.getMinutes();
    minute.value = minute.innerHTML;
    second.innerHTML = date.getSeconds();
    second.value = second.innerHTML;

    setTimeout("timeRefresh()", refreshTime);
};

// This is called whenever the inputs are changed to stop invalid forms.
numCap = function( obj, min, max){
    obj.value = Math.max(obj.min, Math.min(obj.max, obj.value) );

    alarmSet();// Starts up the alarm automatically when a value is changed.
};

window.onload=function(){
    timeRefresh();

    var a = getID("aHour");
    a.value = hour.innerHTML;
    a = getID("aMinute");
    a.value = minute.innerHTML;
    a = getID("aSecond");
    a.value = second.innerHTML;
};


I would love for some feedback on my code! What could I do to improve/simplify the code?

Also, if you would like to see the HTML page along with it, just ask!
This is not a complete review, just a few things that jumped out to me:

getID()

Looks more like "easier to write" than "easier to read". From current function name "getID", most people reading the code will assume that the function will return an ID.

If you would like to use jQuery as you can simply write $("#hour") instead of getID("hour"). The core idea of jQuery is to let you select (or query) DOM elements.

alarmSwitch()

If you use simple if/else instead of the switch/case, the code will be much simpler.

if(aSwitch.On){
...
} else {
...
}


Variable Naming

Simply naming the variable tomorrow instead of tomo would have been better for read

var tomo = false;// tomorrow.


If/else blocks for single line

Consistently using if/else blocks, even for single line statements helps avoid hard to find bugs

if( aSwitch.On )
{
    aOff.style.display = "block";
    sound.play();
}
else
    alert("error..");