Showing results 1 to 5 of 5

Thread: changing object colour from multiply variables

  1. #1
    mattsd Gast

    Default changing object colour from multiply variables


    I have an analogue level the then 4 alarms for each analogue that are generated in my Beckhoff Twincat PLC. The alarms are High high, High, low and low low.

    I would like the analogue to be displayed to change to red (alarm state) when either of these 4 variables are in alarm.

    I can change colour on 1 alarm by putting it in the line colour dynamic of the analogue variable but how do I do this on alarm 1 OR alarm 2 OR alarm 3 OR alarm 4?

    I could do this OR logic in the PLC but I have many analogues therefore would have to create 100 extra tags in the PLC and import then to ZenOn - this will not be good as they will only be required for Zenon display..

    Thanks for your continuing support for me developing this product.


  2. #2

    Default Re: changing object colour from multiply variables

    Hi Matt,

    Please take a look at the Reaction Matrix (Rema) in the project tree at the variables node.

    Here you can define a Reaction Matrix (Analog or Multi-Analog) centrally, and create conditions where you can either select single bits of the analogue value or e.g. If greater than 100 then... Here you can also specify for each condition a color. The conditions are evaluated for each variable where this reaction matrix is used from the top to the bottom, and is stopped if one condition applies.

    Instead of defining a limit at the variable, you can select the option "reaction matrix" at the variable and choose the reaction matrix you created at more than one variable (also using multi-select in the editor). In this case the limit text (Alarmtext) of course will be the same for all variables. However you could consider using dynamic alarm texts coming from a string variable.

    What you could also do is, use the same color at Limit1, Limit2 Limit3 Limit4 etc. In order not having to define the limits at each variable, you could create a user-defined datatype, of the appropiate IEC Datatype, and create the limits centrally at the Datatype. After importing from the Beckhoff PLC / Project, you could use Multi-Select to change the datatype to the user-defined datatype, and all variables will inherit the properties including the limits from the datatype.

    (Of course you could also add limits directly at the IEC datatype, however this will then affect all variables based on this type)

    best regards

  3. #3
    mattsd Gast

    Default Re: changing object colour from multiply variables

    Thanks Mark for your prompt reply.

    Still am having a problem getting this working, just to confirm, the 4 digital alarms are generated in the PLC and in zenOn for alarm display (therefore the Analog or Multi-Analog Reaction Matrix will not be used as only want the alarm setpoints to be in one place (PLC)

    I have tried the multi-binary. I assume that this is the one I need but cant add these alarm variables to it. I have select the 4 alarm variables and associate each one to this multi-binary from the properties of each variable.
    Also it seems there is nothing I can select within the multi-binary Reaction Matrix editor to make the colour change when either of the alarms is set. (see attached).

    The analogue I have displayed on a page (and want the colour to change), I thought that I would need to select the multi-binary Reaction Matrix name under the colour properties but this is not possible - I still can only select one variable.

    Thanks Mark

    Attached Thumbnails Attached Thumbnails multibinary.JPG  

  4. #4

    Default Re: changing object colour from multiply variables

    Hi Matt,

    I'm afraid I didn't understand you correctly. I thought you had one anlogue value with four limits.

    In order to set a color depending on four different digital variables (OR compare) you can create a variable from the mathematics driver and add these four variables at the formula (value calculation)

    The Value of the mathematics variable will be "1" if the condition (X01 OR X02 OR X03 OR X04) is true.

    Click image for larger version

Name:	ScreenShot071.jpg
Views:	42
Size:	33.6 KB
ID:	52

    At the dynamic elemnent "combi-element" it is also possible to use multiple variables in a formula in the way of the mathematics driver.

  5. #5
    mattsd Gast

    Default Re: changing object colour from multiply variables

    Sorry, I didn't explain that well. Mathematics variable - Perfect! Thanks Mark


Similar Threads

  1. Replies: 0
    Last Post: 19th September 2007, 11:06
  2. Help! I can not import my variables .dbf file
    By markclemens in forum Engineering Studio & Service Engine (former zenon Editor & Runtime)
    Replies: 0
    Last Post: 20th August 2007, 15:36
  3. VBA Object Overview
    By robertf in forum VBA
    Replies: 0
    Last Post: 16th August 2007, 10:18

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts