Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 106586

Add minutes to string

$
0
0

Hi,

I have a script that generates heating on/off times along with temperature set points. At the moment I have times for when kids are at school and times for when they are at home.

The time is printed as ‘07:30’ as a string and my question is, is there a way of adding a timedelta to this string? For example

delta = 30
timeam = " ‘07:30’"
timeam2 = timeam + timedelta(minutes=delta)

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 106586

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>