Vijeo Scripting

junior

Member
Join Date
Jan 2006
Location
Seattle
Posts
271
I'm trying to figure out how to write a script to change the PLC address a variable points to when a button is pressed. For example, integer variable "int1" is setup as external and points to integer address %MW10 in a twido PLC. When a button is pressed on the Magelis screen, I'd like to change the plc address so that "int1" will now point to %MW20. Not sure if this can be done. Any advice?
 
I don't know much about the twido, but you could create an array, then use a 'pointer' to index into the array, based on where you want it to be...

We do this all the time, and it works really well. I don't have time just now to post an example, but may get a chance over wknd.
 
When you create a variable in Vijeo in the bottom right hand corner is a field called index (or offset or something like that) this allows indexed addressing to be used. Have a look, if you can't find ask again and I'll supply some more info when I get a chance
 
I don't see the field called index. There is an offset field and into it you enter the word address in the plc. eg. %MW[Offset]

Attached is a screen cap of the create variable screen
 
Ok so my memory was a bit out
Use the Indirect Address field (tick the box) then enter the variable name and the value in this variable will act as an offset
eg if this variable has a value of 1 then you would be pointing to %MW51 (from your example)
 

Similar Topics

I work for an OEM. I am trying to develop a generic HMI program that will display an overview screen displaying between 2 and 6 "widgets"...
Replies
1
Views
1,304
I am running Vijeo 6.1 and I am trying to write a script so that when pushed. I can go to a user login or Logout the user. I know you can do it...
Replies
1
Views
2,510
Good Day all. I am currently busy with a schneider HMI design in vijeo designer and i want to know how you can animate an image to move on the x...
Replies
2
Views
173
Hello, I have been tasked with adding some analog signals for display and alarm setup in some old Schneider Electric HMIGTO HMI-panels. I have...
Replies
4
Views
179
My system are taking data from RHT sensors, around 45 points. Now I want to make a function in which, if the data is #BAD or 0 in values for all...
Replies
0
Views
477
Back
Top Bottom