Alarm Clock Device - New Plugin By SB Domotique

Hi - I just found this and thought I would share it with those who may not have already seen it, plus i want to also pass on the credit to Sbdomo for what looks like a nice plugin.

Original = Virtual Clock : Un plug-in « Réveil  pour la Vera sous UI5 | «SB domotique

Looks like a nice addition and would be useful to folks who usually need a virtual switch and luup to bypass a scene.

Anyone else tried this? I used to have a TV that turned on in the morning that this would be handy for, and easy for the wife to edit!

I’ve been testing it for a bit, just running a simple scene every day and so far, so good.

I’m now considering using it to turn the heating on in one room every morning at 6am to tie into my DIY Virtual Heating post that I have running in another section of this forum…

Hello,
Just to say that my plugin is now on Mios marketplace. I have rename it. It’s Virtual Clock…

Hi,

this is great thank you!

any good way to easily update alarm time from a mobile or similar device? an android app to do this or similar would be ace :slight_smile:

I have four scenes that I use to adjust the alarm time of a VClock in response to triggers from remote UIs. The scenes either increase or decrease the alarm time by 15 minutes or one hour. I’ve included the Lua for the four scenes below:

-- Add 15 minutes to Alarm Time local sEarly = luup.variable_get("urn:upnp-org:serviceId:VClock1", "AlarmTime", 92) local hour = tonumber(string.sub(sEarly,1,2)) local minute = tonumber(string.sub(sEarly,4,5)) local second = 0 minute = (math.floor((minute + 7)/15) + 1) * 15 if minute >= 60 then minute = 0 hour = hour + 1 end if hour > 23 then hour = 0 end sEarly = string.format("%02d:%02d:%02d",hour,minute,second) local lul_arguments = {} lul_arguments["newAlarmTimeValue"] = sEarly luup.call_action("urn:upnp-org:serviceId:VClock1","SetAlarmTime",lul_arguments,92)

-- Add 1 hour to Alarm Time local sEarly = luup.variable_get("urn:upnp-org:serviceId:VClock1", "AlarmTime", 92) local hour = tonumber(string.sub(sEarly,1,2)) local minute = tonumber(string.sub(sEarly,4,5)) local second = 0 hour = hour + 1 if hour > 23 then hour = 0 end sEarly = string.format("%02d:%02d:%02d",hour,minute,second) local lul_arguments = {} lul_arguments["newAlarmTimeValue"] = sEarly luup.call_action("urn:upnp-org:serviceId:VClock1","SetAlarmTime",lul_arguments,92)

-- Subtract 15 minutes from Alarm Time local sEarly = luup.variable_get("urn:upnp-org:serviceId:VClock1", "AlarmTime", 92) local hour = tonumber(string.sub(sEarly,1,2)) local minute = tonumber(string.sub(sEarly,4,5)) local second = 0 minute = (math.floor((minute + 7)/15) - 1) * 15 if minute < 0 then minute = 45 hour = hour - 1 end if hour < 0 then hour = 23 end sEarly = string.format("%02d:%02d:%02d",hour,minute,second) local lul_arguments = {} lul_arguments["newAlarmTimeValue"] = sEarly luup.call_action("urn:upnp-org:serviceId:VClock1","SetAlarmTime",lul_arguments,92)

-- Subtract 1 hour from Alarm Time local sEarly = luup.variable_get("urn:upnp-org:serviceId:VClock1", "AlarmTime", 92) local hour = tonumber(string.sub(sEarly,1,2)) local minute = tonumber(string.sub(sEarly,4,5)) local second = 0 hour = hour - 1 if hour < 0 then hour = 23 end sEarly = string.format("%02d:%02d:%02d",hour,minute,second) local lul_arguments = {} lul_arguments["newAlarmTimeValue"] = sEarly luup.call_action("urn:upnp-org:serviceId:VClock1","SetAlarmTime",lul_arguments,92)

That’s very kind thank you :slight_smile:

Sent from my HTC HD2 using Tapatalk 2