Parking Barrier

Well I guess I'm ok then. I can build up from there. I really wouldn't have a problem if my current instruction set wasn't so limited, but that's something that will change in the future

I'm a pre-grade student, my major is electrical engineering, and this softPLC is my thesis work, but for thesis purposes it's really limited. In the long run, the primary goal is to use it for educational purposes and maybe low budget industries, which in my country is a real issue, plus the lack of national automation technologies.

My sincere thanks for all the feedback. I'm just a noob on this field, but I think I found a good place to learn. Thanks
 
Re: Wow!

vishal-s said:
'We find comfort among those who agree with us; growth among those who don't.' --Frank A. Clark
Too many aphorisms here for a single day. :cool:
Nah, here's another:

What we obtain too cheap we esteem too lightly; it is dearness only that gives everything its value.
-Thomas Paine
 
LuisEn,

check out http://puffinplc.control.com/ as well. It doesn't look a lot of work is done but you may possibily get in touch with others who has already done work in that field.

... who knows, maybe a well written softplc will became the "killer app" for Linus one day..
 
Luis,

To answer your original question...

You were correct in your statement that using an up counter instruction and a separate down counter instruction referencing the same counter structure will not result in an effective up/down counter. The problems with sharing the presets and the done bits are just what you described. And in a real world A-B plc that is exactly how it works. You do NOT have the option of setting an up counter as C5:0 and a down counter as C5:1 but have the down counter use C5:0's accumulator. I *think* that was what you were asking about. (Other PLCs may have a way to do this, but I don't know of any.)

Cetainly you can design an up/down counter instruction using its own structure with independant presets and done bits, but that is a different instruction with a different data structure.

It is also possible to copy the up counter's accumulator to the down counter's accumulator on every increment, and vice versa, so that the two separate accumulators always have the same value, but that's messy and overly complicated.

Personally, I would use ADD and SUB for this function. Just because you're counting something doesn't mean a counter is the best instruction to use.

Good luck on your thesis,

Mike Ellis
 
MEllis,

Yeah, that's exactly what I was asking. It was hard for me to explain because I don't know the appropiate terms (much less due to the languauge barrier), but I tried to express the general idea. Thanks for the feedback.

Luis
 
LuisEn,

As Mike Ellis said, for the Rockwell Software (Allen-Bradley PLC's), there are two separate functions CTU (Count Up) and CTD (Count Down). To use those in the Parking Lot program, it would be necessary to add rungs to make each counter have the same Accumulated Value. I have done this in similar programs and it is no big deal.

But for the Automation DIrect PLC's there are CNT (Count) and UDC (Up/Down Counter). The CNT only counts UP 0 to 9999, but the UDC will count up and/or down from 0 to 99,999,999. It has three ladder rung inputs: Up, Down, and Reset, and also a Preset value that ranges from 0 to 99,999,999. When it reaches the Preset Value, the UDC Counter bit is set and stays set until the UDC Reset input goes on. There is no DONE or COUNT bit equivalent to the Rockwell DN and CNT bits.
 
Last edited:

Similar Topics

G
If anyone help me, I have to do a Ladder Program of a Parking Lot with a capacity of 20 cars. When a car drive in to the parking Lot a sensor...
Replies
2
Views
3,469
This is the reason why I signed up here and decided to get some help before I tackle the traffic light program on Wednesday. It looked good on...
Replies
17
Views
11,763
I have an assignment that I have to do with a PLC and a parking garage. The parking garage can fit 15 cars but the light has to be green up until...
Replies
5
Views
2,348
I am supposed to create a ladder diagram for a parking garage indicating a green light when there is parking space. Include counters so it can...
Replies
10
Views
5,047
I am in desperate need of help with this issue. So we are connecting a rack that was used, initially we connected all the devicenet devices and...
Replies
4
Views
2,825
Back
Top Bottom