Is it possible to find which date-time element in an array/list is the closest match to a now? I’ve got a list sensor which consists of
label1, time1, value1, label2, time2, value2 etc
and I want the value closest to the current time.
I’ve tried various things and can’t seem to process the list sensor as a list. It looks like this
Sensor.list
['label1', '01:20', '4.56m', 'label2', '07:34', '1.92m', 'label3', '14:03', '4.38m', 'Label4', '19:57', '1.90m']
I’m sure this is basic stuff, I just don’t get it