I would like to know how to call one global variable with two different values in a class and call them in the other class (within which behave such as flags).
in SerialP.py
Class SerialP(object):
def ReceiveFrame (self, data, length):
global myvariable
if x:
myvariable = 1:
elif y:
myvariable = 2
in fmMain.py
Class fmMain:
def OnReadConfig(self, event):
if SerialP.myvariable = 1:
#do this task
if SerialP.myvariable = 2:
#do another task