winIDEA SDK
require_version.py
1
# This script is licensed under BSD License, see file LICENSE.txt.
2
#
3
# (c) TASKING Germany GmbH, 2023
4
5
"""
6
This script demonstrates usage or asserting that version being used
7
is still compatible with newer versions of our products.
8
It compares version used against version passed in the parameters and
9
throws an error if the one used is not compatible anymore and should be updated
10
"""
11
import
isystem.connect
as
ic
12
13
14
'''
15
Note: you cannot call this function with parameter name specified
16
e.g. `requires_SDK(nMajor=9, ...)` as it was translated to get
17
*args as the only parameter, therefore just numbers need to be passed
18
'''
19
def
verify_SDK():
20
ic.requires_SDK(9, 21, 100)
21
# OR
22
ic.requires_SDK(9, 21, 100, 0)
23
# OR
24
ic.requires_SDK(
25
9,
# nMajor
26
21,
# nMinor
27
100,
# nBuild
28
10,
# nSubBuild
29
3
# nSccBuild
30
)
31
32
33
if
__name__ ==
'__main__'
:
34
verify_SDK()
© TASKING Germany GmbH (9.21.243)