You are not registered yet. Please click here to register!


 
 
plc storereviewsdownloads
This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
 
Try our online PLC Simulator- FREE.  Click here now to try it.

---------->>>>>Get FREE PLC Programming Tips

New Here? Please read this important info!!!


Go Back   PLCS.net - Interactive Q & A > PLCS.net - Interactive Q & A > LIVE PLC Questions And Answers

PLC training tools sale

Reply
 
Thread Tools Display Modes
Old March 9th, 2018, 09:41 AM   #1
EricBig
Member
United States

EricBig is offline
 
Join Date: Mar 2018
Location: usa
Posts: 21
switch on scale ideas

I have a switch and a scale reading the weight

how can i use a switch to zero the value of the scale if pressed.
and if i add more weight and released will read the total value (original +added weight)
or if you can guide me to a tare function formula for a scale

card used 1769-IQ16
Compactlogix - using RSlogix 5000


Thanks

Last edited by EricBig; March 9th, 2018 at 09:57 AM.
  Reply With Quote
Old March 9th, 2018, 11:03 AM   #2
Aabeck
Member
United States

Aabeck is offline
 
Aabeck's Avatar
 
Join Date: Feb 2013
Location: Detroit
Posts: 915
What I would do is when the switch is turned on do a OneShot and write the value to an integer, and as long as the switch is on subtract the recorded integer from the process value. When the switch is turned off don't process the SUB and display the real process value.
__________________
Never underestimate the quality of idiots that will be running your machines
http://aabeck.com
  Reply With Quote
Old March 9th, 2018, 11:07 AM   #3
EricBig
Member
United States

EricBig is offline
 
Join Date: Mar 2018
Location: usa
Posts: 21
Quote:
Originally Posted by Aabeck View Post
What I would do is when the switch is turned on do a OneShot and write the value to an integer, and as long as the switch is on subtract the recorded integer from the process value. When the switch is turned off don't process the SUB and display the real process value.
I have done that but how to add more weight and start scaling from zero while an actual weight is on it?
  Reply With Quote
Old March 9th, 2018, 11:07 AM   #4
carretto
Member
Brazil

carretto is offline
 
carretto's Avatar
 
Join Date: Feb 2013
Location: Chapecó
Posts: 13
you can use a tag for each measure, and move or add the value between them

use MOV and ADD
  Reply With Quote
Old March 9th, 2018, 11:09 AM   #5
carretto
Member
Brazil

carretto is offline
 
carretto's Avatar
 
Join Date: Feb 2013
Location: Chapecó
Posts: 13
Quote:
Originally Posted by EricBig View Post
I have done that but how to add more weight and start scaling from zero while an actual weight is on it?
Use OSR
  Reply With Quote
Old March 9th, 2018, 11:09 AM   #6
Aabeck
Member
United States

Aabeck is offline
 
Aabeck's Avatar
 
Join Date: Feb 2013
Location: Detroit
Posts: 915
Do you mean when the switch is on you want to add more weight and have it scaled over the entire range, or just the reading above when the switch was turned on?
__________________
Never underestimate the quality of idiots that will be running your machines
http://aabeck.com
  Reply With Quote
Old March 9th, 2018, 11:38 AM   #7
EricBig
Member
United States

EricBig is offline
 
Join Date: Mar 2018
Location: usa
Posts: 21
Quote:
Originally Posted by Aabeck View Post
Do you mean when the switch is on you want to add more weight and have it scaled over the entire range, or just the reading above when the switch was turned on?

Tare = Growth - Net
0 = 35lb - 35lb

i only have growth = 35 lb
so i subed 0 - 35 = -35
then i added my output (-35) to the actual growth.

now i got the value zero when i pressed the switch.

i need another line on the ladder to read starting from zero that is while the original weight is on
so when i add another 35 lb

originally would be 70lb
but it actually read 35 lb
  Reply With Quote
Old March 9th, 2018, 01:39 PM   #8
thingstodo
Member
Canada

thingstodo is offline
 
Join Date: Feb 2012
Location: Saskatoon
Posts: 148
Quote:
Originally Posted by EricBig View Post
Tare = Growth - Net
0 = 35lb - 35lb

i only have growth = 35 lb
so i subed 0 - 35 = -35
then i added my output (-35) to the actual growth.

now i got the value zero when i pressed the switch.

i need another line on the ladder to read starting from zero that is while the original weight is on
so when i add another 35 lb

originally would be 70lb
but it actually read 35 lb
If you have SCALE as the live reading of weight and DISPLAY as the value that is shown. switch is the input, switch_bit is the storage bit for the ONS

Comment - when the switch is turned on, but just the first time the program sees it, copy SCALE value to the TARE value
XIC switch ONS Switch_bit MOV SCALE TARE. You need to PUSH and HOLD the switch to keep the TARE and display the NET. When you let go it shows GROSS again.


Comment - now that you have a TARE value, if the switch is ON, subtract TARE from the SCALE reading and show the weight added to the scale (NET)
XIC switch sub SCALE TARE DISPLAY

Comment - if the switch is OFF, copy the SCALE value to the DISPLAY (GROSS)
XIO switch mov SCALE DISPLAY
Attached Images
File Type: jpg scale.jpg (14.8 KB, 29 views)

Last edited by thingstodo; March 9th, 2018 at 01:40 PM. Reason: Added documentation
  Reply With Quote
Reply
Jump to Live PLC Question and Answer Forum

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Topics
Thread Thread Starter Forum Replies Last Post
Momentary Switch reset PLCfromNZ LIVE PLC Questions And Answers 5 May 30th, 2016 10:45 PM
Stratix 8300 to Core Switch d21x LIVE PLC Questions And Answers 10 October 29th, 2015 03:58 PM
need help jlchandler81 LIVE PLC Questions And Answers 25 July 30th, 2015 03:16 AM
Load cell scale using leverage grnick50 LIVE PLC Questions And Answers 9 January 23rd, 2015 06:38 AM
ML1000 serial to rinstrum 400 scale pdcsah5 LIVE PLC Questions And Answers 6 July 11th, 2010 07:17 AM


All times are GMT -5. The time now is 10:51 PM.


.