![]() |
|
#1
|
|||
|
|||
Traffic Control Program 8051Hello everyone!
I am supposed to write a program of a traffic control system. The statement of the question is as below: Quote:
The program I have written so far is this: Code:
Could anyone please have a look at it, and find out the errors, my countdown subroutine isn't working properly I think, or maybe there are some other problems too. What I am basically doing is running the traffic lights in a clockwise fashion in the main program. Before the countdown it checks whether manual traffic has been added via the keyboard. If yes, then it adjusts the delay according to the traffic so if traffic was 50, for 50 seconds. For the road selection what I am doing is setting up two switches with an enter button, which is connected to an interrupt. When a road is selected, the user presses enter, and it goes into its interrupt where it stores the traffic for each road. The key point over here is that when a user selects traffic, the clockwise operation of the four lights should not cease. They should keep on operating as before but when the road that has been selected arrives, the delay and the countdown is adjusted according to this new traffic. Hope I have been clear. Please help. Last edited by hira : 05-May-2009 at 06:27.
|
|||
|
#2
|
|||
|
|||
Re: Traffic Control Program 8051So my new error-free program is this:
CPP / C++ / C Code:
but it is giving some sort of a logical error coz the output on proteus isn't right. I would really appreciate it if someone could take a look. |
|
#3
|
|||
|
|||
Re: Traffic Control Program 8051What assembler are you using?
|
|
#4
|
|||
|
|||
Re: Traffic Control Program 8051Using Keil.
|
Recent GIDBlog
Problems with the Navy (Chiefs) by crystalattice
| Thread Tools | Search this Thread |
| Rate This Thread | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Equation solver | RazoR | C Programming Language | 3 | 18-May-2008 10:24 |
| Systemize, Outsource, and Grow with the Traffic Assistant Program | oms3ta | Member Announcements, Advertisements & Offers | 0 | 07-Nov-2007 18:30 |
| Two-Tier data dissemination code installation problem | nidhibansal1984 | Computer Software Forum - Linux | 6 | 16-Sep-2007 11:13 |
| Help! Some basal questions about MFC | xutingnjupt | MS Visual C++ / MFC Forum | 1 | 05-Dec-2004 04:38 |
Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The