1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

URGENT - Uni Projct - Autonomous model car - CIRCUIT

Discussion in 'Homework Help' started by 3slink, Mar 4, 2017.

  1. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    Any help is greatly appreciated.

    Basically i need to make a autonomous model car to hit a wall at an unknown distance and return to its original position.

    My idea was to potentially have a capacitor charge and discharge 2 different motors, with a DPDT switch to reverse the polarity of the 2nd motor so that it reverses.

    A circuit diagram would be incredibly helpful.

    Thanks in advance.
     
  2. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,326
    Likes:
    1,231
    Location:
    Cardiff, Wales
    This presumably is a school/college assignment?
    I have no idea what you mean. You can't 'charge' a motor.
    Why do you need two motors?
    What will the first motor do when the second one is reversed?
     
  3. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    Because it has to hit a wall at unknown distance i thought a capacitor could charge on the way there. Then when it hits the wall it starts to discharge in reverse so it goes back to original position.

    i have attached what i kind of had in mind.
     

    Attached Files:

  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,592
    Likes:
    952
    Location:
    Canada, of course!

    I think you will have one motor to drive the car forwards and reverse. Then the second motor is a generator that measures the distance by charging a capacitor while the car drives forwards then the capacitor discharges while the car drives in reverse and causes the car to stop when it is completely discharged. Then you need an electronic circuit to measure the capacitor voltage as it discharges and to stop the car when it detects a full discharge.

    The battery must power the driving motor in reverse because even a huge capacitor cannot produce enough power to drive the car.
     
    • Like Like x 1
  6. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    What would the circuit look like and how exactly would i measure the voltage for when the capacitor discharges? What type of capacitor would i need?

    Also would a DPDT switch need to be put into the circuit to reverse the car when it hits the wall?

    The motor i am going to use is a "Single Output Shaft Inline Motor and Gearbox 1:200" that has power of 3-12V DC.
     
    Last edited: Mar 4, 2017
  7. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,592
    Likes:
    952
    Location:
    Canada, of course!
    A simple circuit can use a comparator IC to measure the discharging capacitor voltage.
    Use any capacitor that is charged by another motor used as a generator on one of the wheels.
    The DPDT switch can reverse the motor and activate the comparator circuit.
     
    • Like Like x 1
  8. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    Excuse my knowledge, quality of image and representation of the components but is this something it would look like?
     

    Attached Files:

  9. cowboybob

    cowboybob Well-Known Member Most Helpful Member

    Joined:
    Oct 22, 2011
    Messages:
    3,053
    Likes:
    479
    Location:
    James Island, SC
    Welcome to ETO, 3slink!

    Have you built the car yet?

    If not, I'd suggest (for simplicity) that you start with a car that has only one motor, with the idea that you'll simply reverse the voltage for the return trip. With a 1:200 gear ratio, the second motor, unless powered, will introduce far to much resistance to movement to make the car practical.

    Then test it to get an idea of how well it works (speed, power, etc.). Then we can work on the circuit needed to do the task as you have described it. And I might add that controlling the return trip to stop at the starting point is doable, of course, but might it surprise you as to what is likely to be needed.

    If you've already built the car, please share with us how you built it and in what configuration. Photos would be helpful.

    Also, do you have any test equipment, for instance, a Volt/ammeter?
     
    • Like Like x 1
  10. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,592
    Likes:
    952
    Location:
    Canada, of course!
    You show the drive motor powered only for a fraction of a second while the capacitor charges then the drive motor stops. Also, you show a single pole switch (SPDT) that completely disconnects the drive motor when it is switched to the comparator. But your comparator circuit looks like a simple resistor that will do nothing.
    Why try to do an electrical/electronic project when you know nothing about them?
     
  11. JimB

    JimB Super Moderator Most Helpful Member

    Joined:
    Sep 11, 2004
    Messages:
    6,393
    Likes:
    593
    Location:
    Peterhead, Scotland
    ONLINE
    A few questions for clarification...

    The title of the thread says "Uni Projct", can you tell us what you are studying at university?
    How long is the course and at what stage are you in the course?
    What are you trying to demonstrate with this project?
    You say that this is "URGENT", when is it due to be submitted?

    Answers to these questions may help to shape the replies here in the forum.

    JimB
     
    • Agree Agree x 1
  12. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    I am a first year Mech. Eng. student.
    We are not trying to demonstrate anything, it's just a project.
    It is to be submitted tomorrow.
     
  13. Les Jones

    Les Jones Well-Known Member

    Joined:
    May 15, 2015
    Messages:
    1,474
    Likes:
    191
    Location:
    Lancashire UK
    I think the idea of measuring the distance an storing the information aa a charge on a capacitor is a non starter. I would suggest putting a sensor on the motor to count revolutions. Use the pulses to increment a counter when the car is moving forward and decrement them when it is reversing. When the counter reaches it's starting value (Which could be chosen to be zero.) the motor is stopped. Using a microcontroller would be the simplest way to implement this.

    Les.
     
    • Agree Agree x 2
    • Like Like x 1
  14. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    Thanks for that, seems much simpler than the capacitor design :)
    Are there motors that already have these sensors on or if not how would I attach it to the motor?
    And how would I reverse the motor and have the pulses decrement when the model vehicle is in contact with the wall?
     
  15. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,326
    Likes:
    1,231
    Location:
    Cardiff, Wales
    Google should find you motors with sensors ('shaft encoders'). An H-bridge of transistors can be used to reverse a motor. Incrementing/decrementing a count is a standard software procedure.
     
    • Like Like x 1
  16. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    Would I still need a DPDT switch then?
    And do you recommend a certain programme?
    Thanks
     
  17. Les Jones

    Les Jones Well-Known Member

    Joined:
    May 15, 2015
    Messages:
    1,474
    Likes:
    191
    Location:
    Lancashire UK
    You wil not need the DPDT switch as the reversing of the motor can be done using a H-bridge as alec_t suggested. You will need some form of switch or sensor to detect when it reaches the wall. You can get motors with quadrature encoders which give direction information as well as the number of positiones moved. You may get away with just simple sensor that gives one (Or more.) pulses per revolution. You would then use the direction informaton to decide if a pulse increments od decrements the counter. I have used this system to control a roller blind. It had to initially be tought the count coresponding to the up and down positions. It has worked perfectly for several years.
    You will have to write your own software for the microcontroller. I would suggest one of the PIC16F series or Atmel ATtiny series of microcontrollers. You could do this without a microcontroller but it would take quite a number of ICs.

    Les.
     
    • Like Like x 1
    • Agree Agree x 1
  18. alec_t

    alec_t Well-Known Member Most Helpful Member

    Joined:
    Jul 10, 2011
    Messages:
    9,326
    Likes:
    1,231
    Location:
    Cardiff, Wales
    If this project is due to be submitted tomorrow I assume it's an 'on paper only' one?
     
    • Like Like x 1
  19. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    yeah pretty much, just come up with the design of the vehicle, circuit diagrams and parts list.

    It would be much appreciated if you could assist me on designing the circuit for this
     
    Last edited: Mar 5, 2017
  20. audioguru

    audioguru Well-Known Member Most Helpful Member

    Joined:
    Mar 16, 2004
    Messages:
    32,592
    Likes:
    952
    Location:
    Canada, of course!
    If the car has at least one wheel that is not driven by the motor then a simple revolution counter can be made on it. Then the main driven wheels can slip or "burn rubber" and the distance measured by this revolution counter will be accurate.
    I was thinking that you were going to let the car slam into the wall at the end which changes the position of the DPDT switch to change the motor direction.
     
    • Like Like x 1
  21. 3slink

    3slink New Member

    Joined:
    Mar 4, 2017
    Messages:
    10
    Likes:
    0
    I was thinking of attaching the motor to the axle so the car moves as straight as possible.
    And yes, one way was that if the car, coming in contact with the wall, would cause the DPDT switch to change motor directions
     

Share This Page