Ap15e, looking at wiki and this older post, if my time range is 16:00 to 05:30 is there something different that I need because my end time is beyoud 00:00 time (2nd example)? thanxs Mike
current_hour = os.date('*t',os.time())["hour"]
current_min = os.date('*t',os.time())["min"]
if (current_hour > 15) and ( (current_hour < 21) or ( (current_hour == 21) and (current_min <= 15) ) )
then
else
return false
end
or:
current_second = os.date('*t',os.time())["hour"] * 3600 + os.date('*t',os.time())["min"] * 60
min_time_in_seconds = 16 * 3600 + 0 * 60
max_time_in_seconds = 21 * 3600 + 15 * 60
if (current_second > min_time_in_seconds) and (current_second < max_time_in_seconds)
then
else
return false
end