defcon.klaxon
Lifetime Supporting Member
Hey guys,
I've already searched the forums and think I've figured this out, just wanted to make sure since the threads I found were all slightly different than what I was after.
Project in question is converting existing 90/30 code to RX3i, and making modifications. Former programmer is doing things that just baffle me but I'm trying to work through it. His scaling methods were odd at first, but after reading about how the ALG221 can be set to 0 at 4mA it's making more sense.
Because the 90/30 code didn't have Scale blocks, his scaling was done manually which is fine, but I was thinking of modifying the code to Scale blocks so it's easier to read and keep track of. But I noticed that all the Scale blocks have integer value outputs, so anything with a decimal would apparently need to be scaled to 10x the engineered high value, converted to REAL, then divided by 10 (or insert 100x and divide by 100 for more decimal places, 1000x and divide by 1000, etc).
I simply cannot understand why what appears to be a modern, higher grade PLC wouldn't have a Scale block built in that could do decimals natively. These things certainly aren't cheap, but even a damn Scadapack can deal with decimals in their SCAL block. I would expect this sort of nonsense from Automation Direct, so what am I missing? Is there a reason in the foundation of the GE processor/Proficy program that can't handle this? Am I more frustrated than I should be?
I've already searched the forums and think I've figured this out, just wanted to make sure since the threads I found were all slightly different than what I was after.
Project in question is converting existing 90/30 code to RX3i, and making modifications. Former programmer is doing things that just baffle me but I'm trying to work through it. His scaling methods were odd at first, but after reading about how the ALG221 can be set to 0 at 4mA it's making more sense.
Because the 90/30 code didn't have Scale blocks, his scaling was done manually which is fine, but I was thinking of modifying the code to Scale blocks so it's easier to read and keep track of. But I noticed that all the Scale blocks have integer value outputs, so anything with a decimal would apparently need to be scaled to 10x the engineered high value, converted to REAL, then divided by 10 (or insert 100x and divide by 100 for more decimal places, 1000x and divide by 1000, etc).
I simply cannot understand why what appears to be a modern, higher grade PLC wouldn't have a Scale block built in that could do decimals natively. These things certainly aren't cheap, but even a damn Scadapack can deal with decimals in their SCAL block. I would expect this sort of nonsense from Automation Direct, so what am I missing? Is there a reason in the foundation of the GE processor/Proficy program that can't handle this? Am I more frustrated than I should be?