Offset level analog in PLC 5

tjoneill

Member
Join Date
Jul 2007
Location
Michigan
Posts
66
Hi again all,
I have a question for anyone who can help.
Im working on offsetting an analog reading for tank level to get me closer to the actual gallons in a tank.
I started by just installing an ADD instruction after a oneshot and notify bit from numeric kepad but realized that I wouldnt be able to because I wouldnt be able to - the reading.
Would a MOVE work, or would the intire readout be masked by the move?
Thanks again..
Tim

I am using a Panelview 1000 to monitor gallons in a tank
 
Last edited:
Does the PLC already compute the gallons with some sort of scaling math
within the PLC? If so how is that done? ( post your program if you can) Usually the scaling math can incorporate an offset value that you could write to.

e.g.
Typical scaling equation of y=mx+b where "b" is the offset. Make "b" a register instead of a constant so you can write to it.
 
As you can see in LAD 4, I was just going to use the ADD instuctions but I know this wont work.
All the MULT. instructions are in LAD 4.
 
Raw data from your analog cards is from the BTR instructions in ladder three.
See picture for how I would apply the offset.

Edit: dest for compute instr should be F8:4 in example below.

ComputeInstruction.jpg
 
Last edited:
Im working on offsetting an analog reading for tank level to get me closer to the actual gallons in a tank.

Why do you need to apply an offset? If the scaling factor is not accurate then why not correct it? Just curious.
 
Why do you need to apply an offset? If the scaling factor is not accurate then why not correct it? Just curious.

Because we would have to empty the tanks to set the low and then fill again to set the high and we cant do this in the near future. This will be a temp fix on a secured screen that only I can get into until we can recal. the lvl sensors.
Good question though....I was expecting that,lol
Thanks alot Mickey
PS. Ill let you know if it works
 
WELL SOME BAD NEWS,
I am getting an error after verifying saying.."complex expressions are not allowed in this processor"
The processor is a PLC 5/25 ser. A
Tim
 
WELL SOME BAD NEWS,
I am getting an error after verifying saying.."complex expressions are not allowed in this processor"
The processor is a PLC 5/25 ser. A
Tim


Sorry about that, I didn't notice the Classic PLC5. Yes the compute instruction is only available in the enhanced PLC5's.

Then after the MUL instruction put an add instruction with a different dest register. See pic for an example

You will have to make other changes to your program to replace F8:4 with F8:50 or whatever register you use in your add instruction dest. Or change your MUL instructions dest to a unused register and then add your offset to it with a dest of F8:4. Then you don't have to make other changes to your program.

Addinstruction.jpg
 
Last edited:
If I put in an ADD instruction, wont it just ADD the data? What if I want to bring the gallons down?
Just curious.

Ill try your second option by changing the MUL destination then ADD the N: from the keypad and puting it back to F8
Hows that sound?
Tim
 
Last edited:
If I put in an ADD instruction, wont it just ADD the data? What if I want to bring the gallons down?
Just curious.

Write a negative number from your PV. ( tag will have to be a signed integer or floating point)



Ill try your second option by changing the MUL destination then ADD the N: from the keypad and puting it back to F8
Hows that sound?
Should work.
 
Last edited:
Yes the compute instruction is only available in the enhanced PLC5's.

For those following this tread.
Correction to the above statement I made, the PLC5/25 does support the "CPT" instruction but it will only support two operands.
 

Similar Topics

Omron AD081-V1 Analog Input Card Offset & Gain Adjustment Entering Adjustment Mode 1. Set the input card in adjustment mode (Turn ON Dip SW No-1)...
Replies
0
Views
44
Anyone have problems with the absolute offset of an axis controlled by a 1756-M02AS being erased and/or being a large number that doesn’t relate...
Replies
0
Views
1,325
I'm trying to offset Main CIP (Master) for other slaves (Drives). I have 360 Rotary Scaling. For the MAPC I'm using "(360.0 +...
Replies
0
Views
1,169
Hello, Bit of background on the job I am carrying out. Old Setup: Data from CPU ----> Historian ME module -----> Historian SE V3.0 Windows...
Replies
0
Views
1,229
I have a system that has 2 chains with 3 lugs on each chain on a common shaft. The lugs have to be within 1mm of each other as they push a panel...
Replies
10
Views
2,151
Back
Top Bottom