element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Arduino
  • Products
  • More
Arduino
Arduino Forum Object searching robot problem :( Please Help Beginner
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Arduino to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 5 replies
  • Subscribers 392 subscribers
  • Views 484 views
  • Users 0 members are here
Related

Object searching robot problem :( Please Help Beginner

the_future
the_future over 7 years ago

Please help doing a project and trying to improve my skills with this new robot kit

i got with a few sensors (Robot: Magician Chassis Robot)

 

 

image

 

Task: make a robot that passes through a corridor first with a width of 50cm that then enters a larger space where the robot must search and find a box

 

Sensors: ultrasonic and IR sensor

 

 

I have managed to get the robot to pass through the corridor without touching the corridors by attaching ultrasonic sensors on each side of the robot

but now I am trying to get the robot to search and find the box after it first enters the larger area I was told this might be a "collection of distances" problem

but I have no idea what that means and how I would go about programming or creating an algorithm (easy flowchart) for

 

Please help thank you !!

  • Sign in to reply
  • Cancel

Top Replies

  • jomoenginer
    jomoenginer over 7 years ago in reply to the_future +1
    Well, a chair has many definitions; it could be a bean bag, a rocking chair or a standard 4 leg chair. In the case of a standard 4 leg chair, the leg of a chair will have a much narrower detection area…
Parents
  • jomoenginer
    jomoenginer over 7 years ago

    What you need to do is check the room and collect the distance readings where you will find some that are a closer than others indicating there is an object is in the path.  This distance should be less than the wall behind it so once you have this you can focus the bot on moving toward the object.  Then at a close distance you would stop in from of it.  This might be best with the ultrasonic sensor and use the IR sensors to keep the bot from hitting the walls.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • the_future
    the_future over 7 years ago in reply to jomoenginer

    how would I code this if you dont mind helping? and in the case for example if some parts of the wall are closer than other like a maze for example and is not an nice and easy shape shown in the diagram would the robot think that the closer parts of the wall in the object out of interest?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • jomoenginer
    jomoenginer over 7 years ago in reply to the_future

    You have a few choices.  You could use the Ultrasonic Sensor to sweep the room and collect that data in a data structure such as an array and look for the value(s) that is not consistent with the others.   The walls will have a consistent set of values depending on whether or not they are closer or far away.  The object will be the inconsistent value and should stand out from the others.   You can do this if you have the Ultrasonic Sensor on a servo and sweep from left to right.  If that is not an option , then you might have to move the bot from left to right collecting the data.   The IR sensors could be used to detect if you get close to an object such as a wall.

     

    The other option is use the Ultrasonic Sensor to keep track of the wall distances and the IR sensors to detect when you reach an object.  If the IR sensor detects an object that is closer then the wall distance, then you can determine if you have reached the object or not.  In this case, the ultrasonic sensor would be mounted higher than the IR sensors.  If the object is small, then this might be the best option.  In this case, you will have to calibrate both sensors to get an idea of what values determine an object or a wall.

     

    You'll have to play with the ultrasonic sensor to determine how it senses when an object in the path vs when it detects a wall.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • the_future
    the_future over 7 years ago in reply to jomoenginer

    last question thank you for being so helpful in the event that the box is in a larger vast space without any other objects besides a chair how would the robot know

    the different from the box and the chair the box is the white box in the image image

     

    image

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • the_future
    the_future over 7 years ago in reply to jomoenginer

    last question thank you for being so helpful in the event that the box is in a larger vast space without any other objects besides a chair how would the robot know

    the different from the box and the chair the box is the white box in the image image

     

    image

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
  • jomoenginer
    jomoenginer over 7 years ago in reply to the_future

    Well, a chair has many definitions; it could be a bean bag, a rocking chair or a standard 4 leg chair.  In the case of a standard 4 leg chair, the leg of a chair will have a much narrower detection area than the box does.   In the case of the Ultrasonic Sensor, the leg will only be seen in a very specific area of the sweep.  the box will have a much wider area of sweep.   With the IR sensors, if you are using an array of IR sensors, the chair will only show up on something like 1 or 2 sensors, where the box will more likely show up on more than 2. 

     

    My suggestion is that you put together an IR and a Ultrasonic sensor circuit and see how they indicate when an object is in front of them.  If you are using an IDE that has debug capabilities, then you could set a breakpoint where the senor is read and use a variable to add to a watch list.  Then just loop through reading the sensor with and without an object in its path to see the difference in the reading.  If you are using something like the Arduino IDE, then you can use the serial output to send the data to see how the values change.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube