EBpro macro

Hello, I'm new to a program EBpro and I have to find a way to make a numeric object's background change colors depending on read data from plc. For example, I'm gonna have a HHigh, High, LLow and Low limit. If the data hits
High or Low the background has to change to yellow color, if it hits HHigh or LLow - red. The panel is MT8150XE model and apparently I don't have the Object Condition menu. I'm trying to write a macro. So far I can activate a BitLamp which has 2 states, but can't find a way to make it stop blinking. Is there even a way to make an object or shape reset it's state? Is it even possible to do this via macro? There is a way to do this without it - I just put shapes or objects behind the numeric object and address them properly but still, was wondering if I can achieve this in other ways.
 
Hello,
Okay but, how do I set up the the whole thing? I'm very confused. Would appreciate your help :) To be honest, I came up with an idea. I will try putting 2 rectangles and will enable use register status/value for both. But once I call the address with a macro (for example LB 0, "SetData(On, "Local HMI", LB, 0, 1)"), how do I make it disappear ? Because once shown, it will hide the other one. One more thing - how does SETBITOFF work? I've read the manuals but can't really understand what is happening... Sorry for asking too many questions, but I think SETBITOFF is the salvation, since both rectangles use register and If I turn off the bit they will disappear till the next turn on of the bit.
 
Hello guys,
So far I came up with a solution. I use two variables - On and Off, bool type. Firstly, I use GetData, to read data from numeric object and convert it to BCD - "LW_BCD". Then, depending on the read data (Input), I set on and off ellipse objects, which have enabled "Use register status/value". Whenever I set on one of them using SetData(On) (since On is TRUE), in the end of "If" I use SetData(Off) (since Off is FALSE), so I can turn off (hide) them. Important note is that I had to set correct device data format in numeric's properties (in my testing case 32-bit Float). I'll put my test macro below, would appreciate any tips.
 

Attachments

  • macroChangeColors.png
    macroChangeColors.png
    38.2 KB · Views: 25

Similar Topics

Is it possible to use the cMT Viewer Android app on my tablet to connect to the EBPro simulation running on my PC? The simulation doesn't use an...
0
Replies
119
Views
Does anyone know of a way to 'multiplex' screens in Maple Systems HMIs? I am doing my first project with one and have been watching the tutorials...
2
Replies
377
Views
Hello, I am trying to configure my recipe database. I need to be able to save a recipe by which buttons on a screen are active up to 60...
2
Replies
2,137
Views
Hi all, I wanted a 3rd party HMI that could use faceplates and indirect addressing. And I found it! I use RSLogix 5000 and Omron Sysmac. I...
0
Replies
5,981
Views
I'm honestly just curious of where you would want to use one of these, I've seen the option in FT View designer but never used it nor come across...
3
Replies
956
Views
Top