>>Message imported from previous forum - Category:ClearSCADA Software<< User: hardin4019, originally posted: 2018-10-22 16:08:51 Id:166 I have a float from a 3rd party that when read in is the Real representation of 32 bits that contain 32 digital input status points coming into ClearSCADA. What is the best way to take that Real and get represented as a Binary number 32 bits long so that I can extract the bits I need and use FBD or ST to get those bits to individual internal digital points?
Reply From User: geoffpatton, posted: 2018-10-23 15:58:57 They are trying to make it difficult on you with a REAL. The only thing I can think of, that will actually work (I had a few hair brained ideas), is to do the math and pick it apart in structured text and write all the bits out to internal points.
Reply From User: hardin4019, posted: 2018-10-23 17:05:43 That is really what I was afraid of. I had originally thought there was a simple way to resolve an integer into binary bits, but have come to the same conclusion that doing the math to resolve the number is the only way. Unfortunately, I only need 4 bits out of the whole thing, and it isn't as easy as I thought!