Urgent!!! Ultimate Traffic Light Program Needed!!!

TimWilborne

Lifetime Supporting Member
Join Date
Oct 2005
Location
Roanoke, VA
Posts
2,210
I need help PLEASE!!! Until recently I was a student learning to program PLCs. We had an assignment to program a simple traffic light. It just so happened while it was demonstrating mine to the professor, the head of the technology department came in with our districts delegate from the House of Representatives.

He was so impressed with my traffic light program that he has asked me to come up with the ultimate traffic light program to reduce traffic and at the same time save the highway budget.

This new traffic program will be at the heart of his campaigning for reelection. I have to get a working program by Monday!!!


There are so many organizations that he is trying to sway to his side that I don’t know where to begin. Here are the requirements

The stoplight must anticipate drivers that slow down when approaching green lights and turn them yellow so they will feel that they may have averted an accident and didn’t just look like an idiot slowing down for a green.

When someone is running a yellow light, it must sense the presence of police officers. If any are present, it must immediate turn red to increase revenue.

Studies have determined that people need variety in their life so he does not want the stoplight to be predictable. Sometimes we need to let them turn left first, sometimes right, sometimes straight.

He is also trying to keep his rival political party members from getting to their fund raisers. If there is a fund raiser scheduled and it senses one of them, we must hold them up for 5 minutes.

He is also into some shady deals so if the police are headed to any of his businesses, he wants the light to be green for the police car, then at the last minute turn all lights green the wreck the police car so he will have time to stash the goods.

Can someone email me a program?


Thankes dudes
 
I'm not exactly sure that writing such a program would be entirely ethical. As a college student myself, ethics are important, and maintaining a strong moral footing would be essential in any application of your skills. That being said...


If you were to want to implement such a program, some elements seem next to impossible to me. OThers seem very expensive. If you wanted ot have the lights to change when a police car is around so that you can "catch" people, then the best way would be to install a transponder in the officers' cars that the plc could detect and respond to accordingly.

The idea of slower moving drivers recieving a yesllow light when they slow down would require some type of equipment that owuld detect speeds (radar?) and let the plc know to begin a sequence to change the light color.

As for randomization, you could use a random number from the plc and use a move instruction to move that random number into the timer.PRE value. And this could also be used to randomize the turn signals. generating a random integer, whenever the value was negative, one thing happens, whenever it is zero, another thing happens, and whenever it is positive, something else happens.

All ethics aside, implementing this system would probably cost more than it owuld be worth, or could even possibly gain from any "increased revenue". Also, the feature to make the lights to cause wrecks for police is severely impractical, and could not be done inconspicuously, bc anyone who knows anything about programming them would immediately tell what was going on.
 
And as I read Antjon1's response further, he/she is going to be a great programmer one day. Look at the thought in the solutions.

I might have caught me one, but no suckerfish.
 
Don't forget that near the end of the month, around 8-9pm when roads are relatively deserted, it will sometimes wait 15 minutes between green lights. Cops will know this. They will wait for the person to get sick of waiting for the green light and go through the deserted intersection - there is some more added revenue.

I like your congressman TW. Too bad he is typical of all politicians :)

Did he say it should be paid for by earmarks to the budget?
 
1. Yea, OK, ya got me...

2. If we can't at least have some ethics about what we do, what does that show the rest of the world? If we were to develop plc applications for drug dealers, how would that look to the rest of the world when the media made it known.
That, and most of those applications would be illegeal.

3. That, and As for all of these people wanting traffic light programs: If you can't develop a simple traffic light yourself for your PLC class, and you are supposed to be able to, perhapse you should consider going back and studying the basics a bit more. Being in a classroom enviornment myself, I understand that a lot of hte programs that we have to develop aren't practical applications, but they do build skills, and by skipping this part of your training, you are missing out on skills that you will use not only just later in class, but also in industry.




Glad that I could help to provide some cheap amusement...
 
Actually it was not cheap amusement. It was a reminder to me that there are people who sincerely want to learn. Thank you antjon1

But I still want my A homework program:beerchug:
 
All in good fun, Antjon! No offense meant!

I too, think you show good sense and hope you'll visit us often here. We just needed to rib you since you were so serious. Your ethics will get you far and so will your sense of humor!
icon14.gif
 
TWControls said:
Actually it was not cheap amusement. It was a reminder to me that there are people who sincerely want to learn. Thank you antjon1

But I still want my A homework program:beerchug:

OK, here ya go! Just hook up, oh, lets say a 3 phase 480 50HP motor directly to the PLC. Preferably a SLC500 or maybe even a PLC 5. Wire the 3 phases straight into the output card. Make SURE it says on the card "DC SOURCE". Also, here is the ladder instruction you should put in:

 XIO I:1/0 NXB XIC I:1/0 BND OTE O:2/0 



Make sure you attach a pushbutton to the 1st Input card. The 50HP motor will make thie lights work through the property of Inductive Reactance. The lights "react" to the induction of the EMF that occurs within the windings of the motor. In fact, if you are using lights that are a long distance away from the motor, you might want to remove ALL fuses from your setup and replace them with jsut a wire to jump over hte fuse socket. That way, you get more current avaliable, and therefore, more reactance.

Hope this helps!

lol

AJ
 
antjon1 said:
1. Yea, OK, ya got me...

2. If we can't at least have some ethics about what we do, what does that show the rest of the world? If we were to develop plc applications for drug dealers, how would that look to the rest of the world when the media made it known.
That, and most of those applications would be illegeal.

3. That, and As for all of these people wanting traffic light programs: If you can't develop a simple traffic light yourself for your PLC class, and you are supposed to be able to, perhapse you should consider going back and studying the basics a bit more. Being in a classroom enviornment myself, I understand that a lot of hte programs that we have to develop aren't practical applications, but they do build skills, and by skipping this part of your training, you are missing out on skills that you will use not only just later in class, but also in industry.




Glad that I could help to provide some cheap amusement...

Don't take it personally. When you need help, and we all do at one time or anither, we WILL help you. You are the kind of student we like. I am pleased you answered. It gives me/the rest of us hope that there are some good people moving in this field in the future.

David
 

Similar Topics

I have an old PLC (circa 2007) consisting of Telemecanique/Modicon/Schneider Electric devices. The system has developed errors and unfortunately...
Replies
2
Views
223
Guys, please help me with this urgently. We have Logic 5575 installed in hot n standby setup. For some reason, the primary now cannot sync with...
Replies
10
Views
372
I have DI module ICPCon M7024UD connect to my pc using COM3 MODBUS RTU and also RHT sensors are using MODBUS TCPIP.. The problem is, it cannot...
Replies
9
Views
1,658
Hi all, We are facing synching issues with redundancy module, where the Primary is ending up with disqualified secondary. Normally this would...
Replies
2
Views
621
I have the logic of OMRON but I want to do this logic in TIA 15.1 CPU 1200...
Replies
4
Views
1,822
Back
Top Bottom