Bottle line

I was able to run only one so far, for some reason I could not run some. I need to look over on them.
Jose,
For LogixPro Bottle Line Exercises 5 and 6, there was a suggestion to do this:
Once you have the completed the foregoing, all that should be left is to handle the details. Allowing the operator to set the count of bottles to be processed might be a feature worth implementing. Reviewing your program and making certain that it is clearly documented is a must.
I did that, so as a result, to start the program, you need to switch to RUN mode, then set the Number of Bottles to Be Processed in the BCD Input I:3 next to the Start Pushbutton. Then press the Enter button to put that number into memory. Then press "Start". Now the program should run until it produces the number of bottles you requested, then it will stop.
 
Boxing

Hey Lancie 1, thanks for the help I did it the way and it really works much better. My logic looks a little different than yours, but still does the job.
here is a picture of it

see u
 
Jose,
You are making progress. Now work on filling, capping, and a Start-up after broken glass is already in a unfilled box. The box will overfill because it already had glass when your program restarted. The best solution I have found is to always eject 1 box at every start-up. It is safer to waste one empty box than to have broken glass flying all over the floor!

Also look into making a shutdown at the exact moment when a large capped bottle is in the diverter chute. The filled bottle will naturally fall and break, unless the diverter conveyor is kept running for a certain number of seconds AFTER the STOP pushubtton is pressed. A TOF Off-delay timer is useful here.
 
Last edited:
Hey Lancie 1 I was able to finish my bottle line project and now works fine, including the 7 segment display.

Thank you for your coaching time
 
Here it is Lancie 1. this is completed but some small thing like running the box before start are missing everything else is done.
 
I look at some of your work on the 7 segment, to understand the functioning, until I got it clear Thanks
 
Thanks for your program. It shows a good effort, not perfect, but as in the real world, I haven't seen one that runs without breaking any glass. I added it to my collection.
 
Hi Lancie 1. I'm working on the multiple floor elevator project last from thelearningpit, labs.
This exercise is done with several subroutines, and after first task is complete getting the elevator to floor #4 I want to toggle the S:1/15 without stopping the program. How can I do this.

Thanks
 
I want to toggle the S:1/15 without stopping the program. How can I do this.
The S:1/15 is a special Status file bit that automatically goes on ONLY during the first scan of the PLC after a switch from PROGRAM to RUN mode, or when power is removed then reapplied. You cannot manually "toggle" that bit, nor should you need to toggle it.

If you want a bit that YOU can make go on without stopping the program, use one of the unneeded and normally unused Inputs, such as I:1/5 (the Elevator "Call" button).

What are you trying to do with this bit anyway? If this is just to reset variables to the begin state, use S:1/15 and forget about it. You don't need to toggle it, it will go on during the first scan (which happens so fast that you will never see it).

PS: You cannot reset the car position to encoder value "295" (1st floor) using the S:1/15 First Pass bit, because the encoder input I:5 is reading the actual car position. The only way to manually move the car back to the 1st floor is to switch to Program Mode, then click "Simulations, Reset Simulation".
 
Last edited:
Hi sorry for the delay of mi answer. But been busy at work.

Anyways, what I'm trying to do with the lab exec is move to the second exec. I did the first and works fine, but to reset the values in each subroutine though I need a bit for rescan and bring the elevator to first floor, by writing a second choice once the first is done. I will forward my file. thanks
 
I did the first and works fine, but to reset the values in each subroutine though I need a bit for rescan and bring the elevator to first floor, by writing a second choice once the first is done. I will forward my file. thanks
ZIP your LogixPro RSL file (compress it to a ZIP-type file) so you can post it here.

You are wasting your time trying to move the elevator to the 1st floor after it finishes Exercise 2. When you complete Exercise 4, you can move your elevator to ANY floor simply by pressing that floor button. So any effort you make now to FORCE the elevator to Floor 1 will simply be replaced later with the proper logic. Why waste time on some useless logic?

For Exercise 3, your elevator is supposed to travel from floor 1 to floor 4 and back to floor 1, when those Input BUTTONS are pressed (either in the car or on the floors). This exercise is where most students first meet head-to-head with the concept of "planning" the program structure and design. Unless you have done a good job of planning in Exercise 1, by looking ahead to Exercise 4 to see what each subroutine really has to do, then when you get to Exercise 3, you find that your base program structure is inadequate and will not perform all the required functions of the elevator.

If you try to set up some type of "rescan" bit, you are screwing up big time. The PLC rescans constantly. If you set up you subroutines correctly in Exercise 1, then that is all the "rescan" you need to worry about. Doing Exercises 1 and 2 correctly sets up the PLC to go to the proper subroutine at the proper time. Each subroutine should handle ALL conditions that occur that affect its action. Bits that need resetting should be done at the time they need resetting, not with some magic "rescan" bit.

As I told you before in Post #25, to move the elevator car to the START position, simply switch to PROGRAM mode, then press "Simulations, Reset Simulation". That requires NO additional programming on your part.
 
Last edited:
What I was trying to do, was to use exerc 2 for completing exec 3 by adding logic. I in fact added some and it does the job of returning the elevator to floor 1 after restarting program once elevator is done and on floor #4. that's what I thought I just need a rescan bit, but I guess I have to start over using different logic to accomplish the task here are my files as of what I intent to do

File #2 is my original
File #3 is what I intent to use for exec 3

Thanks for your time
 
First you should correct your Exercise 2, so you can use it as the base for the remaining Elevator exercises. If you don't get the basic design correct at first, it will not work later. Here are the problems with your Exercise 2:

File 2 Main
Rung 0: Sub U:3 is mislabeled "Stop and Open Door". It should be labled "Initialization". When in doubt, look at your rung comment, which plainly says "Subroutine U3 contains all initializatin logic that needs to execute on the first scan". How could you ignore that comment, and then label the JSR as "Stop and Open Door"? (Stop & Open Door is U:8).

Rung 1: Label the JSR U:4 as "CATCH FLOOR REQUESTS".
Rung 3: Label the JSR U:6 as "CLOSE DOOR && MOVE".
Rung 5: Label the JSR U:8 as "STOP && OPEN DOOR".

File 3 INITILIZATION subroutine
Rung 0: You don't need to clear the subroutine bits. The subroutine calls are handled correctly by the Main File 2, so you don't have to clear them here.

Rung 1: The CLR (clear) instruction sets the bits in a 16-bit word to 0. You must not try to clear each bit separately. In the real RSLogix software, this will ALWAYS result in an error message and your program will not go into RUN mode. See the attached picture. Instead, you only need to CLR B3:0. That will set all bits from B3:01 to B3:0/15 to 0. Use another CLR B3:1 to clear bit B3:1/0.

Rung 3: Move rung 001 from Sub 4 and put it here as Rung 3. Bit B3:0/1 "Do Next or Wait" should always be first unconditionally latched ON in the Initialization subroutine, not in Sub 4. Sub 4 is looking for elevator request buttons, not at the Do Next bit, so you should not confuse and combine the two functions. In other words, you have subroutines for each function, and you should try to keep the appropriate function in its proper subroutine. It is called program organization, and it is a requirement for large complex programs. Mixing and hiding functions in the wrong places results in much frustration and hair-pulling while trying to find where something is done.

File 4 CATCH FLOOR REQUESTS subroutine
Rung 0: Okay
Rung 1: Move to Sub 3
Rung 2: You need to add a rung (similar to Rung 0) that checks for the press of button I:1/4 INSIDE the car. Remember, for every floor, the elevator has TWO places from which it can be called (floors and in the car). You have handled the 4th floor call button. Now you need to do the same for the 4th car button I:1/4 and 4th Car Light O:2/4. When you do exercise 4, you will need these 2 rungs for EVERY floor.

File 5 NEXT REQUEST OR WAIT subroutine
Rung 0: The first rung should unlatch bit B3:0/6. that will be very important later.
Rungs 1 and 2: Your existing Rung 1 logic should be moved to Sub 4 (where it belongs). (Also for the O:2/4 output, use similar logic to what you used in Sub 4, Rung 0.) For the new Rungs 1 and 2, you need to develop "Going Up" and "Going Down" bits. Yes, you can squeak by without them -- for now.

File 6 CLOSE DOOR & MOVE subroutine
Rung 0: Add XIO I:3/2 Closed Limit and I:3/4 Door Switch to your Close Door logic. Otherwise, the door motor can burn out when the motor is kept running long after the door is closed.

Rung 1: Add the following to your Car Up Motor: (1) XIC O:2/0 Stop Car Output. This is similar to an Emergency Stop function. It is there so must be programmed. (2) XIC I:3/1 Elevator Up Limit Switch. Without this switch, if something goes wrong, the elevator winch can try to pull the elevator into the winch house at the top of the shaft.

Rung 2: Add a rung for the Car Down Motor O:4/1. (You need this motor to return to the 1st floor, and this is the place for any MOVE function). Use the following conditions for your Car Down Motor: (1) XIC O:2/0 Stop Car Output. This is similar to an Emergency Stop function. It is there so must be programmed. (2)XIO I:3/2 Door Closed Limit Switch; (3) XIC I:3/0 Elevator Down Limit Switch. Without this switch, if something goes wrong, the elevator winch can allow the elevator car to drop into the basement, or crash into the floor!

File 7 TRACK CAR MOVEMENT subroutine
You sort of forgot what is the main function of this subroutine, to track car movement. In other words, the purpose here is to detect WHERE the car is at all times. If it arrives at a selected floor, then the next Sub 8 Stop & Open should be called. That's all Sub 7 should do.

Rung 0: You are way off the target here. The I:3/1 is the emergency Car Up Limit Switch. It should normally NEVER be contacted, but only when something goes wrong and the car goes too high. There is one sure thing that tells you when the car is at the proper stopping place on the 4th floor. It is the encoder value at Input word I:5. When I:5 = "45", the car is on the 4th floor at the position for the door to be opened. If you wait until I:3/1 is ON, you will notice that the elevator car is above the floor about 12" too high. Some old lady will break a leg trying to jump down from there! This is a huge error in your program.

Rung 1: Correct it so that O:2/15 (controlled by I:5) determines if and when the car reaches the 4th floor, and O:2/12 determines if the car reaches the 1st floor (I:5 = 295). Also the Door Close output O:4/2 should not be unlatched here in the Track Car Movement subroutine. (The Close Door motor should already be turned off in Sub 6 as controlled by I:3/2 and I:3/4. Othewise the motor will burn out when it continually pushes against the closed door).

Rung 2: Move the Car Up Output Unlatch to Sub 8 (where it properly belongs in the STOP & OPEN routine).

File 8 STOP & OPEN subroutine
This subroutine needs to stop the Car Up motor, the Car down Motor, and if the Emergency Stop pushbutton is pressed, Output O:2/0 should be turned ON. After the motors are off, then the B3:0/4 Car is Moving and B3:0/5 Close & Go bits should be unlatched, and settling timer T4:0 reset to 0.

Rung 0: This is where you should turn on O:2/0 if required, and unlatch O:4/0, and O:4/1 (all part of the STOP function in this Stop & Open subroutine).

Rung 5: No, you have used I:3/1 Upper Travel Limit to turn on O:2/15. That is wrong! If the car hits I:3/1, it has gone too far up! When I:5 = 45, turn on O:2/15.

Error when Attempting to Clear Bit.jpg
 
Last edited:
Maybe this copy of Exercise 3 Subroutine 7 TRACK CAR MOVEMENT will help get you on the right path.

ELEVATOR Exercise 3 Subroutine 7.jpg
 
Last edited:

Similar Topics

In the zip attached is the ladder program I made to control the bottle line simulator. Please I need help and to know, how can I keep 1.the run...
Replies
12
Views
2,396
Can someone explain to me why thelearningpit use 3 bsl in parallel, and why the input are like this. And how if a bottle is defected in the start...
Replies
4
Views
2,048
Hello, I am trying to solve the bottle line simulation, but I can't understand the basics, and why we are using BSL and BSR, so can anyone provide...
Replies
3
Views
2,968
Hi everyone! i got a problem in creating the flowchart for my Bottle Line simulation system. http://youtu.be/om5DGgxdmaU i used "Bit shift left"...
Replies
2
Views
3,867
Alright, Heres my problem. I am on exercise 3 boxing the broken bottles. I am able to get the broken bottles to drop and grind, now my problem...
Replies
1
Views
9,804
Back
Top Bottom