[foxboro] Retrieving String Values with AIM*API Followup

  • From: "Klebba, Daniel" <Daniel.Klebba@xxxxxxx>
  • To: <foxboro@xxxxxxxxxxxxx>
  • Date: Thu, 23 Mar 2006 12:24:07 -0700

Thank you Bob and John for your help reading string data from the
AIM*Historian.  We finally figured it out.  It turns out you can use
either function an_hist_values() or Fh_FdbGetValues().  The value array
that is declared in the function prototype as either a float or a double
is in reality simply a buffer to hold whatever is stored in the value
field of the historian.  Therefore you call either function with a float
or double array and then reinterpret the returned value as a string.
Just be sure that the size of the buffer is big enough to hold the
longest string.  You can also check the last four bits of the status
value that is returned along with the value.  They should be 4 in
decimal indicating that the value type is a string.
 
Daniel Klebba
ATK Thiokol
 
 
_______________________________________________________________________
This mailing list is neither sponsored nor endorsed by Invensys Process
Systems (formerly The Foxboro Company). Use the info you obtain here at
your own risks. Read http://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:

  • » [foxboro] Retrieving String Values with AIM*API Followup