Re: [foxboro] C code for reading BLKSTA

  • From: "Redmond, Sean S" <Sean.Redmond@xxxxxxxxxxxxxxxxxx>
  • To: "foxboro@xxxxxxxxxxxxx" <foxboro@xxxxxxxxxxxxx>
  • Date: Tue, 5 Jan 2016 01:37:22 +0000

Hi,
I think bit extension do not work with get/set val.
BLKSTA is a packed long so you will have to bit match it if you want the SE 
parameter.  If you are only interest in SE then you can use C:B.SE
The ACK parameter is not settable well the UNACK parameter is not settable.  
The only way I know how to acknowledge an alarm is via the display manager 
command almack C:B

Sean

-----Original Message-----
From: foxboro-bounce@xxxxxxxxxxxxx [mailto:foxboro-bounce@xxxxxxxxxxxxx] On ;
Behalf Of QUEIROLO, IGNACIO ESTEBAN
Sent: Tuesday, 29 December 2015 4:51 a.m.
To: foxboro@xxxxxxxxxxxxx
Subject: [foxboro] C code for reading BLKSTA

I need to make a C program to get a value of the BLKSTA parameter. I have this 
program from the Sun Compiler installation notes with the modifications 
required to get the value of the BLKSTA.SE parameter:
#include <stdio.h>
#include <stdlib.h>
#include <fox/om_user.h>
#include <fox/om_ecode.h>
main()
{
     unsigned int   value;              /* object value     */
     unsigned int   status;             /* object data type */
     int            data_len;           /* data length      */
     getval ("COMPOUND:BLOCK.BLKSTA.SE", VARIABLE, 0, &value, &status, 
&data_len);
     printf ("The value is = %f\n", value); }

Is this code right?

Also I have to use the setval call to set the SUP_IN.ACK parameter. Does 
anybody have some example to accomplish this?

Thanks!


________________________________



NOTICE - This message and any attached files may contain information that is 
confidential, legally privileged or proprietary. It is intended only for use by 
the intended recipient. If you are not the intended recipient or the person 
responsible for delivering the message to the intended recipient, be advised 
that you have received this message in error. Any dissemination, copying, use 
or re-transmission of this message or attachment, or the disclosure of any 
information therein, is strictly forbidden. BlueScope Steel Limited does not 
represent or guarantee that this message or attachment is free of errors, virus 
or interference.

If you have received this message in error please notify the sender immediately 
and delete the message. Any views expressed in this email are not necessarily 
the views of BlueScope Steel Limited.
 
 
_________________________________________________________________________
This mailing list is neither sponsored nor endorsed by Schneider Electric
(formerly The Foxboro Company).  Use the info you obtain here at your own
risks.  See the disclaimer at www.thecassandraproject.org/disclaimer.html
 
foxboro mailing list:               //www.freelists.org/list/foxboro
to subscribe:           mailto:foxboro-request@xxxxxxxxxxxxx?subject=join
to unsubscribe:        mailto:foxboro-request@xxxxxxxxxxxxx?subject=leave
 

Other related posts: