I need help with PLC problem

FireGirl

Member
Join Date
Aug 2023
Location
New York
Posts
1
This is the problem, I need to solve it using a ladder diagram:
Write a table of inputs and outputs and propose a control solution for
a screw sorting and packing process. The process starts
by pressing the START key and can be stopped at any time by pressing
the STOP key. While the system is working, the green lamp must be on, otherwise
the red lamp must be on.
Screws of three different lengths һ1, һ2 and 3 move on a conveyor belt driven by
motor M1, according to which they are to be sorted. Three sensors B1, B2 and B3 are
placed at the end of the tape, which determine the length of each of the screws passing by
them. The tape can only move if the three boxes in which the screws are packed are in
the correct positions, which is detected by sensors B4, B5 and B6.
From the tape, the screws fall into a channel that directs them into the
corresponding box. The position of this channel depends on which box the screw next to sort
should go into, and is determined by the piston D. Its positioning for the boxes K1, K2 and
KZ is done using the detection sensors on the piston itself do, d1 and d2.
The smallest screws go into the K3 box (which should be filled with 500 pieces),
the medium ones go into the K2 box (which should be filled with 300 pieces), and the largest
into the K1 box (which should be filled with 200 pieces). As soon as one of the boxes is full,
one of the pistons A, B or s extends to transfer the full box to the corresponding auxiliary belt
(these belts are in motion all the time). After this transfer, the corresponding piston is withdrawn
and a new empty box is placed in the following way: one of the pistons E, F or G lowers
the stack of empty boxes, after which one of the pistons H, I or J is withdrawn and places the
last empty box from the warehouse at position B4, B5 or B6. After the completion of this
positioning, all previously mentioned pistons are retracted to their initial positions. The main belt
should continue to operate during transfer and repositioning, until it is the turn of a screw for
which there is no free box to be sorted and packed.
On the auxiliary tapes there are scales T1, T2 and T3 which measure the weight of each
of the boxes and give the result in milligrams in analog form at the inputs IW10, IW20 and IW30
respectively. The weight of the screws is 0.75g, 1.25g and 2g respectively, and the weight of the
empty boxes is 15%. An alarm should be raised and the process stopped if for any of the three
types of boxes three times in a row it is detected that there is a shortage or an excess of more than
two screws.
All pistons consist of two actuators (X_F, X_B) and two sensors (SX_F, SX_B)
for detection of full retraction and extension, except for piston D which is a
three-position piston - it has three actuators D1, D2 and D3 as in the image.
The reaction time of D when changing an order from the PLU is half a
second, and the norm that the entire plant must meet is 25,000 screws per day. If at
any time it becomes clear that the plant cannot operate within these limits, the red
light should flash (but not stop the process).

If someone can help me, thanks a lot!
 
Last edited:
First things first

Welcome to the forum!

You should know that it is the policy of this site not to do homework for you. We will gladly help you reach a solution, but will do so by asking you questions and requiring that you show your work, which we will then ruthlessly tear apart, showing you what you propose won't do what you think it will.

If you stick with it, and can take a bit of (good natured) heat, you'll get a great education.

To start, that's a long homework assignment. Take a stab at the very first phrase in the first sentence:

Write a table of inputs and outputs
.

Post what you have, and we'll help you find what's missing, and then start on how to create a control solution.

Cheers,
©¿©¬
 
Yes as posted, also what is your experience, what PLC are you using (it helps to know as any suggestions can be targeted to that platform).
First of all, create your I/O lists i.e. give your inputs/outputs meaningful symbols. think about internal memories i.e. bits/words also create a list on paper for example
M0 "Start Latch"
M1
M2
D0
D1
D2
Use that to tick off each one as used it reduces the risk of duplicating an address (note: some PLC software does not require fixed physical addresses so not so important i.e. it is symbol based not direct address).
It is a good idea to draw or write out the flow of each function. it sounds like this although quite a task for a beginner it is reasonably simple logic just quite a bit, by the way you mention "as in image" but there is no image attached.
Most of it is simple boolean logic for example:
Screw at box 1 (small screw) the sensor sees Small screw send out piston then retract, add count to the box based on box type. & so on.
It is not completely clear but can the different sized boxes fit in any location or are they fixed, if fixed i.e. smallest box first, middles sized next, followed by largest. this makes it a lot more simple. Think about fault handling, what if a cylinder fails to reach position, do you need to check (by increase of weight) that the screw has entered the box etc. what do you need to do stop the line ?
 
Yes as posted, also what is your experience, what PLC are you using (it helps to know as any suggestions can be targeted to that platform).
First of all, create your I/O lists i.e. give your inputs/outputs meaningful symbols. think about internal memories i.e. bits/words also create a list on paper for example
M0 "Start Latch"
M1
M2
D0
D1
D2
Use that to tick off each one as used it reduces the risk of duplicating an address (note: some PLC software does not require fixed physical addresses so not so important i.e. it is symbol based not direct address).
It is a good idea to draw or write out the flow of each function. it sounds like this although quite a task for a beginner it is reasonably simple logic just quite a bit, by the way you mention "as in image" but there is no image attached.
Most of it is simple boolean logic for example:
Screw at box 1 (small screw) the sensor sees Small screw send out piston then retract, add count to the box based on box type. & so on.
It is not completely clear but can the different sized boxes fit in any location or are they fixed, if fixed i.e. smallest box first, middles sized next, followed by largest. this makes it a lot more simple. Think about fault handling, what if a cylinder fails to reach position, do you need to check (by increase of weight) that the screw has entered the box etc. what do you need to do stop the line ?
Thanks for this detailed guide.
This is also useful for other new users too.
 
To start, that's a long homework assignment. Take a stab at the very first phrase in the first sentence:

Write a table of inputs and outputs


+1.

I read that problem as having 32 inputs (3 analog, the rest discrete) and 25 outputs, but maybe I missed some.

Do not be overwhelmed by the scope: attack it one piece at a time; eventually you will finish a piece and look for the next and not find any, and that is when you know you are done.

Also, there are a lot of bits (discete inputs, discrete outputs, discrete internal bits) involved with each cylinder: extended and retracted sensor inputs; extend and retract command outputs. Solve that logic for one cylinder first, then you can copy that pattern to each of the other cylinders, replacing the specific inputs and outputs but using the same logic.

What platform are you using (Omron, Horner, DoMore, Click, Mitsi, etc.)? What language are you using (ladder, structured text, function block, etc.)?

Do you have long blocks of time when you can program, or is the programming software only available in a lab with limited access? If the latter, find a similar platform of programming software, with a simulator, so you can experiment. I think all of the instructions needed for this assignment work the same across several manufacturers. At a bare minimum you should be able to doodle with pen and paper.

What has been covered in the class so far? The most important concepts are the PLC scan cycle and the order of evaluation of rungs, branches and instructions, because PLC programming is primarily about time and the scan cycle is the clock. If you do not know or have not covered what I am talking about, then I suggest you watch this video series (it's ladder only, but applies to all PLC languages).
 
Last edited:
Why do you help lazybones and cheaters?

We help people because we want to, and because their challenges are also our challenges.. Many of us get enjoyment out of solving problems, which is why a lot of us are programmers. When we help, we do so in a way that guides the student to a position they can use to arrive at their own conclusions. Not understanding a problem nor knowing how to solve it doesn't make you lazy nor a cheater for asking for help. We certainly do not fault first time posters for posting homework problems. Instead we educate them on what we do here and how we will be able to help.

Why post such an unhelpful and condescending comment anyways? You are not in charge of anyone here, nor are you in a position to question anyone's actions or motives.
 
We help people because we want to, and because their challenges are also our challenges.. Many of us get enjoyment out of solving problems, which is why a lot of us are programmers. When we help, we do so in a way that guides the student to a position they can use to arrive at their own conclusions. Not understanding a problem nor knowing how to solve it doesn't make you lazy nor a cheater for asking for help. We certainly do not fault first time posters for posting homework problems. Instead we educate them on what we do here and how we will be able to help.

Why post such an unhelpful and condescending comment anyways? You are not in charge of anyone here, nor are you in a position to question anyone's actions or motives.
++++ Fully agree with you JTCat.(y)
 
Why do you help lazybones and cheaters?
this.

On every large-ish project and program I have ever attempted, I was lost, felt completely inadequate, and didn't have a clue where to start.

  1. That gives me empathy for the people who post here: they are me.
  2. But I would start poking around, ask some questions, then the light bulb would come on (several light bulbs, usually, and oh so slowly). Eventually I knew something.
If lazybones and cheaters is what they are, then they will not post in this thread again. Perhaps they will find another forum to trick someone into solving their assignment, and maybe pass the class, get a job, and hurt or kill someone because they do not understand. Such is life.

But the purpose of school and classes is not to learn the content, becuase the content is irrelevant; the purpose is to eventually learn (i.e. get through our thick skulls) that we teach ourselves. To pass that along is such a signal honor that I never give up trying even though it is so rare, and it humbles me every time it happens.

So the answer to @MaxK's query is "Because I am selfish."
 
Why post such an unhelpful and condescending comment anyways? You are not in charge of anyone here, nor are you in a position to question anyone's actions or motives.


I honestly do not understand what caused such an aggressive reaction.

Strictly speaking, I will repeat the previous post by drbitboy, but I would really like you to understand me.

So if post 1 looked like this:
“I have a task/case…
I read/tried...
I didn’t understand / I didn’t succeed ... "

Then my question would not exist, even if the attempts and questions would be naive / wrongway / wild, it doesn’t matter - this would mean that the person IS TRYING TO UNDERSTAND / LEARN. You can't teach, it is only possible to learn.

I.e. in this topic you do not teach, but help to cheat.

Now imagine that you “helped” and the person “solved” this task, then received a “diploma”, then got a job and ... passed it so that the control system killed the somebody.

From the point of view of the law, you will not be held responsible, but do you really think that all of us here are not responsible for what “weapons we put into the hands of people”?

Please excuse me for stupid pathos
 
Why do you help lazybones and cheaters?

As the long-lost forum member Terry Woods used to say, "Starving egos".

And did you read my post #2? We don't help lazybones and cheaters. But we will help people who are stuck and who show their work to show us where they are stuck. Then we'll offer insights / suggestions / improvements to get them partially unstuck. If they get stuck again and continue asking questions we'll continue to mentor them. Because it feels really good to do that. To see the light bulb come on over their head.

Have you noticed that no one has posted a single line of code? The closest that anyone has done to spoonfeed the OP is The Doctor giving a rough (possibly wrong, by his own admission) count of I/O. And unless @Firegirl comes back, that's all she's going to get.

Which is too bad for her, but is also the self-weeding that "lazybones and cheaters" get. To get to the final answer to turn in to the class, she's probably going to have to post 20-100 times. But which also means that she's not a Compleat Lazybones.
 
Last edited:
And did you read my post #2?



That's a point, I have read your #2.

Now I please you to simulate what was going on in my head:
I see a topic that I consider (not to offend anyone) "doubtful"
I see your #2 (with which I completely agree)
And after a while I see what I see.

This is what caused my "eruption".

Your answer #13 and drbitboy's answer #10 are clear to me

My question was not addressed to you.



Steve Bailey



Quote:
Why do you help lazybones and cheaters?
Apparently you don't consider that an 'aggressive' reaction.


I gave the argument why I consider this topic (so as not to offend anyone) “doubtful” in post 11. If I am was wrong, I apologize to everyone who was hurt by my statements.

I please Moderators to clarify:
1. Does a forum member have the right to consider another forum member as asking questions/creating "questionable" threads?
2. By what criteria should a forum member evaluate the “doubtfulness” of questions / topics in their answers and possible discussions with forum moderators?
3. Point out the attitude of the forum moderators to questions / topics in which there is a possibility of “doubtful” use of the information received
 
I gave the argument why I consider this topic (so as not to offend anyone) “doubtful” in post 11. If I am was wrong, I apologize to everyone who was hurt by my statements.

You are correct that the OP merely posted her assignment without showing any effort, or even a polite request for help. That actually happens a lot around here.

I gave her the first prompt ("Make an I/O list"), and Parky and Brian gave her a start as to what this might look like and how to organize her thinking. Then the ball was in her court.

But then you come along and suggest that we're being too helpful. Believe me, we understand where you're coming from, which is why it's general policy not to "just give the answer."


I please [ask the] Moderators to clarify:
1. Does a forum member have the right to consider another forum member as asking questions/creating "questionable" threads?
2. By what criteria should a forum member evaluate the “doubtfulness” of questions / topics in their answers and possible discussions with forum moderators?
3. Point out the attitude of the forum moderators to questions / topics in which there is a possibility of “doubtful” use of the information received

The moderators don't do what you think they do. I could, for example, take a half hour, do the entire assignment, post it, and while I would likely get chided for doing so, for truly robbing her of an education, the post would stand.

I have gone so far as to post an inaccurate solution (almost comically so) to the Traffic Light problem, which used to show up here with depressing regularity, because of the obvious laziness of the posters. Caveat emptor.

This is an open forum, and you are free to post what you like, including complaints and criticisms (as long as you're not abusive). We're all (mostly) professionals here, and usually welcome different ways of looking at things, including how we present ourselves to others. Most of us have developed a pretty thick skin (or gotten good at simply ignoring what someone says about us) and can take it. We can also dish it out in the same manner that it was given to us.

Sometimes we get posts that some start to be overly helpful on, and others jump in to question whether the problem is real or homework (particularly around lead/lag pump control). There was nothing wrong with your pointing out that Firegirl hadn't shown the slightest bit of effort beyond copy & paste, and a request for "help". It's just that everyone who posted here already knew that, and only gave enough clues to hopefully entice her to get the benefit of what this forum can offer.

You thought those clues were too much; that's your opinion and you're welcome to share it. Others will have an opinion that it was just the right about of bait, and will share that opinion. Bouncing ideas off each other is what makes this forum so great. :site:

The 3 days of radio silence from her indicates that she has no interest in actually learning this stuff. So we spend more time talking to each other than doing the helpful stuff that we often come here to do.
 
Last edited:

Similar Topics

Hi guys, I have no experience when working with AllenBradley PLC, but I hope someone could clarify the result of multiplication shown in the...
Replies
14
Views
2,204
I will be designing an automated hydrostatic system. The system on paper works like this, a plc like the click will get information from an hmi...
Replies
227
Views
43,129
I am working on setting up my own 1756 B series PLC rack, power supply 1756-PB75 /B, 1606-XLS480E -redundant 24 DC power supply, controller...
Replies
6
Views
4,311
Hello. I am working on a PLC program that needs to check input 1 after timer two is complete to see if a valve can close or not. Below is the flow...
Replies
9
Views
2,835
Hello all, I am in my first year of programming and stuck up on a few things for a project that needs to be completed this week. My boss and...
Replies
0
Views
741
Back
Top Bottom