Logic Machine Forum
Start-up (init) Script Falult - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Scripting (https://forum.logicmachine.net/forumdisplay.php?fid=8)
+--- Thread: Start-up (init) Script Falult (/showthread.php?tid=1501)



Start-up (init) Script Falult - Muratcang - 25.07.2018

Hi

I have a LM5 device. I want to keep an object value after a restart or a power failure. It is a Heating Cooling Changeover value and my KNX device always starts with heating. I want to keep the HC Changeover value before a power failure then i will send it back with the Start-up (init) Script.


I have tried these codes:

value =storage.get('HC ExChageover')

os.sleep(3)

grp.update('LM5 Changeover', value)

NOTE: I set the value of 'HC ExChangeover' in another script by using below string;

storage.set('HC ExChangeover', value)

I have tired this string too,

value = grp.read('HC ExChangeover')
 os.sleep(3)
grp.write('LM5 Changeover', value)

All my object names are ('HC ExChangeover' and 'LM5 Changeover') not KNX Objects.


RE: Start-up (init) Script Falult - admin - 26.07.2018

Try logging the value via log(). Also, you need to use grp.getvalue() instead of grp.read(), because read only sends a telegram to the bus, object value is returned this way.