Visualisation of bitmasks or alarm codes

More
1 month 2 weeks ago #48 by jds
Hello,
2 questions concerning alarms and visulaisation of error codes:

is there a possibility to visualise a whole bitmask at once in a xttgraph or can it only be done with seperate indicators using the bit seperatly in the attribute? Maybe there's a way to pop up the navigator at the mask itself to display the status?
I've got a pump control unit with 11 different (error) alarms, those alarms can come active at the same time (ex. low water and input error).

Another question concerning another type of pump control: in this controller, unlike the above, there work with alarm numbers (+- 60 different numbers) which could be read out in the alarm registers. From those alarms is always only 1 alarm at the same time active. Can an alarm object contain dynamic text so that when an alarm becomes active the right text in the operator window will be displayed?

Please Log in or Create an account to join the conversation.

More
1 month 2 weeks ago #52 by claes
Hi jds,

Each bit has to be displayed individually with the attribute specified with the ##Bit suffix.

You can set DetectText in a sup object for example in a DataArithm by fetching the sup object with a GetData and connected to a DataInput. The new DetectText has to be set before the alarm is triggered.

/Claes

Please Log in or Create an account to join the conversation.

More
1 month 1 week ago #57 by jds
Since I've never used the dataarithm blocks I've tried t oplay wih it first. I thought I 'd try out to fetch the actualvalue of a class and put at the output of the block.
Of course after serveral tries I saw that "actualvalue" is in fact a pointer.
How can I fetch this value, I'm not that good in C coding ...
This is what I've done:
 

I even don't know if I'm on the right track ...

Please Log in or Create an account to join the conversation.

More
1 month 1 week ago #58 by claes
Hi jds,

Actual value in signal objects are special, as they for thread safety and optimization reasons are gathered in specific area objects, and ActualValue contains a pointer into such an area object. Furthermore it's an offset pointer that has to be converted to an absolute pointer before it can be used. That can be done with a call to gdh_TranslateRtdbPointer() but it's easier to fetch the signal value with a GetAi and connect it to the A1 input of the DataArithm object instead.

/Claes

Please Log in or Create an account to join the conversation.

More
1 month 1 week ago #60 by jds
Haha,
bad example to start with :-)
In the meantime I've used a "simpler" integer to try the function out and it works like a charm.

Probably the best sequence to alter the text alarm:
- hold the alarm signal towards the dsup
- read in the current text
- concat the right alarmtext depending of the array containing the text codes
- write the text
- release the alarm signal

I suppose using an array is te same way all other "normal" vars are used? Will try it out eitherway.

Please Log in or Create an account to join the conversation.

More
1 month 1 week ago #62 by jds
I think I'm getting somewhere, but not as far as it should be, therefore some extra questions:
- I've created an extra attribute in my component with a string array containing the alarm text to be displayed at the certain alarm code. The only problem is how to access this array (this is probably more a C question and me not being too familiar with it).
This is what I've tested so far:
 

Second question:
With creating the array I'd hoped that I could fill in all the alarm text once (in the template) and that this text would be copied when I created the component in my load. Unfortunatly the array is there, but empty. Is there something to be done to make this work? I've thought about making a $type, but as far as my knowledge reaches I can only create enum types?
 

 

Please Log in or Create an account to join the conversation.

Time to create page: 0.529 seconds
Powered by Kunena Forum