Sign in to follow this  
Followers 0
scotnet

RSLogix 5000 footage counter

12 posts in this topic

I desperatley need help to program a footage counter on a paper machine. I am using a ControlLogix processor talking to AB flex I/O via Ethernet. I bought a 1794 HSC to use a powered magnetic pickup with a multi-tooth gear but I quickly found out that I was over my programming head. If anyone has a program for this that would be great! Since I could not do that I have an idea to do it another way. I currently have logic that calculates line speed in FPM (Feet Per Minute). I have a magnetic pickup going into a frequency module. I can divide that by 60 and get feet per second. If I trigger that calculation at the start of a roll and use a time base of 1 second, that should give me what I'm looking for. the problem is that I can't figure out how to accomplish that. Anyone that could give a ladder sample to accomplish that would be my Hero! Here is how I determine FPM using a CPT function: Dest: line speed FPM expression: Laminator hz * 3.1416 * 1.017 (1.017 is for the gear ratio) From this point I would like to calculate total feet in a roll by triggering the function to begin counting total feet, then trigger it again to stop it, transfer that value to a file while beginning a new roll count. This seemed simple to me when I got the idea but proved beyond my capabilities when I started trying to do it.

Share this post


Link to post
Share on other sites
Post your code or explain yor code a little more. Mainly you ft/s calculation. Shouldn't be too hard to straighten it out

Share this post


Link to post
Share on other sites
I would simply add another CPT function and divide the FPM calc. by 60 to get FPS. My thinking is that if I do that, I could somehow take that value and apply it to a timer or counter with a one second time base. 1st CPT function: Ex. Lam. HZ * 3.1416 * 1.017 ( this gives FPM) 2nd CPT function ( Lam HZ * 3.1416 * 1.017)/60 ( this gives FPS) Now I have FPS. If line speed were 1200 FPM, that would be 20 FPS. Now if I could apply that to a one second time base and the roll ran for 720 seconds, I would have a length or Footage value of 14,400 ft. At the end of the expiring roll (14,400 ft.) I would need to move that value to a tag and route to my panelview as "last roll footage". At the same time reset the timer/counter and begin again. Hope this makes sense. Thanks for your interest! Edited by scotnet

Share this post


Link to post
Share on other sites
Looks like you got your math down. The only things is you talk about a timer with a 1 second time base. Controllogix time base is only .001 so you need to divide your result by 1000. The maximum timer value is 2,147,483,647 so you would need to make sure that value would be sufficent. One thing I was wondering is since you have a HSC, why not put an encoder on the roll. It would make your code much simpler. Also is your measuring device mounted on a dancer or mounted to the shaft that drives the roll. Its a lot more complicated if it is shaft driven What determines the end of the roll. Is it when the paper runs out or a specific length.

Share this post


Link to post
Share on other sites
The end of count is determined by the end of a roll. The roll will typically run at 1100 FPM. As that roll expires ( close to the end) a new roll starts turning up to line speed. At a predetermined time, a roll will fire in and stick the expiring sheet and new roll sheet together. Witina 2 seconds a knife will fire to cut the expiring sheet. This is where I want the footage counter to clear and reset to the new roll. I will post the code for this so it may make more sense to you. I am not using the HSC simply because I have not learned how to yet. I have very little training on RsLogix. Most of what I've done is from long hours of trying to figure it out. When I read the file on the HSC I realized I need to look for another way to accomplish my goal. I will in time figure it out. If you know of a sample ladder logic example of this it would most definitley help. I've learned more from seeing other peoples programs and figuring them out than from reading the AB literature. Again thanks you for your continued interest. unwind.ZIP

Share this post


Link to post
Share on other sites
If your calculation for FPM then the rest is easy. This is assuming two things that you need to check on. 1. Is the FPM constant. I have a feeling that it isn't. If it was then you wouldn't need something to monitor the FPM. If the FPM is not constant, then none of this will work. Even if it only varies a little bit then the feet ran will not be accurate. An encoder would work much better in this situation assuming the second issue is not a problem. 2. Is the frequency sensor mounted to the shaft that drives the roll or to some type on external wheel that rides on the paper. If it is mounted to the shaft then this will not work. Your sensor so that it senses the paper going by and not the revolutions of the roll. Please answer 1 and 2 for me If 1 and 2 are ok the total feet will be U_LAMINATOR_FPM_TEST*U_Footage_TMR.acc/1000/60

Share this post


Link to post
Share on other sites
While the line speed is usually constant, it may change due to various issues. I think I understand why this is a problem with the calculation, but I'm still quetioning it. OK, it looks like an encoder would be a simpler solution. Dumb question time: If I already have a square wave pulse coming into my frequency module (Airpax 53Z powered pickup running on a 60 tooth gear), could I not feed that same signal into a counter module and get the same reults? The pulse frequency is determined by the speed at which the gear rotates. Could a counter moudule be configured to count the total pulses and use a CPT function to calculate the actual footage? If there is a differnet and better way, by all means pleas advise. I f you could recommend and 1794 module and an encoder to work with it I would be willing to try it. Also as I mentioned before, If you have or can direct me to a good example of how to set up and configure a counter module it would help a lot. I am using RSL5000 ver. 10. I have not found any programming function for an HSC. My experience with all of is somewhat limited, but I KNOW there is bound to be code already written out there for what I am trying to do. A footage counter (Totalizer) is a very common thing. Thanks again.

Share this post


Link to post
Share on other sites
Ok, I didn't realize till now that you have version 10. I think that is part of your problem. I don't have a copy of version 10 anymore, but I think the minimun version for the 1794-vhsc on ethernet is version 11. Once you have the newer version right click the module and go to properties tab. Go to the counter configuration tab. Under type, you can select the type of counter you want. As long as the roll never reverses, the frequency modulator will work. But you never answered question 2. If it is hooked to the shaft that drive the roll it will not work anyway.

Share this post


Link to post
Share on other sites
I'm sure I have the latest revision somewhere. I have just not updated to it. I am confused by your statement regarding the sensor being mounted to the drive shaft. The existing pickup is in fact mounted to the drive shaft. The divisor factor in the CPT calculation takes he number of teeth of the gear and the drive ratio into consideration. This is how we compute FPM which is very accurate. Could you explain?

Share this post


Link to post
Share on other sites
If it is a roll on a shaft, as the roll size changes the diameter changes so the feet per shaft revolution changes.

Share this post


Link to post
Share on other sites
OK, I see the problem. We have a failure to communicate on my part. The pulse generator IS mounted to a shaft, but it is on a machine roll that does not change rpm as the roll changes. It is the lead drive in the machine and is where I get the signal for Line speed. There is however another pickup as you may have seen in the program that IS on the expiring roll and does change (faster pulse train) as the roll gets smaller. Hope that makes sense. The counter module that I bought is a 1794-IP4. Do you think this will work for my application or should I make another choice? I have never used one of these before and have NO idea how to set it up.

Share this post


Link to post
Share on other sites
You should be able to make this work as long as the roll does not back up. In the future you may think about using a 1794-vhsc and an encoder. Programming this is much easier

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0