EngineersGarage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise
You are here: Home / Topics / I need assistance

I need assistance

|

Microcontroller › 8051 › I need assistance

  • This topic has 5 replies, 4 voices, and was last updated 13 years, 1 month ago by igbe obinna.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • June 12, 2012 at 11:55 pm #1840
    igbe obinna
    Participant

    i am working on an 4-way cross road intelligent traffic light controller as my final year project and am using 8051 microcontroller. i want to be able to sense the first car that obstructs my input sensor(cause am using an infrared transmitter and receiver as sensors) the assign right of way to that lane of the road. then the second car to trip it is given the next right. but the microcontroller ought to check this 4 roads simultenously the arrange the cars(i.e road to be given right of way) in order of priority.BUT I CANT DRAW THE FLOWCHART THAT WOULD ENABLE ME WRITE THE CODE.      HELP!!!!!

    June 13, 2012 at 12:25 pm #8021
    midhun
    Participant

    This is a very easy task. First you should write a code for reading the IR receiver output.

    IT is your wish that you are going to read the first sensor output then checking the status of vehicles or reading all the sensors at a glance then checking the status.

    Once the status is read, You can switch on respective traffic lights.yes

     

    June 14, 2012 at 5:15 am #8034
    pratik
    Participant

    if ur sensors gives a sigle bit output, program should read it as a nibble (four bit data) from an input port,

    according to the nibble read, program can give right of way to perticular road.

    i think simultaneous reading is better control option.

     

     

     

    June 19, 2012 at 4:30 am #8074
    Anonymous
    Guest

    i would like to make this microcontroller to read the outputs from these sensors simulteneously but i dont know how to structure the flowchart that would enable me write the code.

    June 19, 2012 at 12:14 pm #8076
    midhun
    Participant

    What you need to do is , first you should write a code to understand that where, which color lights should be switched ‘ON’.

    You can write seperate sub programs (functions) say, void left(void), void rignt(void), void straight(void), void (back).

    in each function you should write code to get the data from your look-up table.

    once the data is taken you can just send it to the port where your light is connected.

    June 20, 2012 at 4:17 am #8095
    igbe obinna
    Participant

    thanks all. your advice was ok

     

  • Author
    Posts
Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.
Log In

RSS Recent Posts

  • More fun with ws2812 this time XC8 and CLC July 17, 2025
  • Pic18f25q10 osccon1 settings swordfish basic July 16, 2025
  • Pickit 5 July 16, 2025
  • turbo jet fan - feedback appreciated. July 16, 2025
  • I Wanna build a robot July 16, 2025

Stay Up To Date

Newsletter Signup
EngineersGarage

Copyright © 2025 WTWH Media LLC. All Rights Reserved. The material on this site may not be reproduced, distributed, transmitted, cached or otherwise used, except with the prior written permission of WTWH Media
Privacy Policy | Advertising | About Us

Search Engineers Garage

  • Engineers Garage Main Site
  • Visit our active EE Forums
    • EDABoard.com
    • Electro-Tech-Online
  • Projects & Tutorials
    • Circuits
    • Electronic Projects
    • Tutorials
    • Components
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • Advertise