Delay function in css

22 views
Skip to first unread message

Swati Soni

unread,
Dec 5, 2014, 8:11:53 AM12/5/14
to css...@googlegroups.com

Hello folks.

I am trying to use animation by overlapping images using java script..

Time interval is needed for displaying images...we have not got any delay function in css..so we have implemented java script delay function using get Date() and get Time() but it doesn't work..

Any help will be appreciated.. Thanks in advance

On Mar 4, 2014 2:00 PM, <ssswat...@gmail.com> wrote:
Hello All.


I am getting trouble to get value of attached PV from CSS widget. Here is my script:

importPackage(Packages.org.csstudio.opibuilder.scriptUtil);
var i = "Swati_Soni";
var value1 = display.getWidget("text1").getValue();
var value2 = display.getWidget("text2").getValue();
display.getWidget("t_display").setPropertyValue("text", i+"_"+value1+"_"+value2);
From this script I am able to concatenate the two value in textupdate "t_display" (widget shows the output), but the PV attached into it can not get updated with this concatenated value.
Is there any method so that the attached PV of "t-display"can be updated with "Swati_Soni_value1_value2".
text1 and text2 has=ai EPICS record ,whereas t_display has stringin record.


Thanks in advance,
Swati

--
You received this message because you are subscribed to a topic in the Google Groups "CSS BOY" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/css-boy/uwDgP4X6KCM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to css-boy+u...@googlegroups.com.
To post to this group, send email to css...@googlegroups.com.
Visit this group at http://groups.google.com/group/css-boy.
For more options, visit https://groups.google.com/groups/opt_out.

dmic...@googlemail.com

unread,
Jan 19, 2015, 8:05:27 AM1/19/15
to css...@googlegroups.com
Hi,

JavaScript does not have a wait function as it is single threaded and would therefore block eveeything...

I'm not sure what your animation meant to be but can't you use simulated local PVs like sim:ramp() to act as the timer ? I have done this before to make LEDs blink. Have a look in the examples for how this can be used

David

Reply all
Reply to author
Forward
0 new messages