winIDEA SDK
Loading...
Searching...
No Matches
test_get_set_int_uint.py
# This script is licensed under BSD License, see file LICENSE.txt, or search for `License` in the SDK online help.
#
# (c) TASKING Germany GmbH, 2023
import isystem.connect as ic
winidea_id = ''
def test_getSetIntUint():
connMgr = ic.ConnectionMgr()
connMgr.connect(ic.CConnectionConfig().instanceId(winidea_id))
optCtrl = ic.COptionController(connMgr, "/IDE/System.Debug.Applications[0].SymbolFiles.File[0].Options")
value = optCtrl.get_int("CodeOffset")
print(f"Original value of 'SymbolFiles.File[0].Options.CodeOffset' attribute: {value}")
print(f"Setting new value (42)...")
optCtrl.set_uint("CodeOffset", 42)
print(f"Restoring original value ({value})...")
optCtrl.set_int("CodeOffset", value)
value = optCtrl.get_uint("CodeOffset")
print(f"Original value of 'SymbolFiles.File[0].Options.CodeOffset' attribute: {value}")
if __name__ == "__main__":
test_getSetIntUint()