Generation working and Compilation of MARTe components
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
from org.csstudio.opibuilder.scriptUtil import PVUtil
|
||||
from org.csstudio.opibuilder.scriptUtil import ColorFontUtil
|
||||
|
||||
import datetime
|
||||
|
||||
pv = pvs[0]
|
||||
|
||||
s = PVUtil.getTimeInMilliseconds(pv)
|
||||
t = datetime.datetime.fromtimestamp(float(s)/1000.)
|
||||
|
||||
format = "%H:%M:%S"
|
||||
|
||||
widget.setPropertyValue("on_label", t.strftime(format))
|
||||
widget.setPropertyValue("off_label", t.strftime(format))
|
||||
Reference in New Issue
Block a user