Arduino Based Line Maze Solver

UPDATE : 5/24/2014: New video added ( with path shortening )

This was my 2nd robot. Back then, I had built it to solve a line maze but there wasn't a path shortening routine. And then, I came to know about Patrick Mccabe's maze solver. I had a look at his code, and edited it a bit just to get it working with the different sensors and motors used in my robot. So, credits for the code go to him.

The robot used plastic geared motors back then which is why it was quite difficult to abruptly change the direction of the motors or break their movement. As a result, I had to slow down the PWM value to an absolute minimum which resulted in an all-time slow robot but one that is super efficient in solving a non-looped line maze.

Sorry for the bad lights in the video, but the robot is running fine.

Future updates? Now that i have a couple of micro metal-geared motors, i might try using them for some more speed.

********************************************************************************************************************************************************

Hey there guys,

Here's a maze solver using arduino.

 

 

So, it basically traverses a non-looped maze structure made up using black tape on a white background. I made this one using an arduino uno clone and an L293D motor driver module. It's a bit shaky as the code is shaky and it needs revision.

 

It uses a Magician Chasis as a platform which comes with two acrylic plates, a pair of wheels, a pair of DC geared motors.

 

As you may have already known, it uses the left-hand-on-the-wall technique. So the order of preferences of turns is:

1) Make a left turn

2) Else move forward

3) Else make a right turn

4) Finally, if there's a dead end, make a 180 turn.

I am looking forward to implementing the path shortening routine in it soon.

-Ashim


Solves a non-looped line maze

  • Actuators / output devices: DC Geared Motors 12V
  • Control method: autonomous
  • CPU: Arduino
  • Operating system: none
  • Power source: 3S Lipo 2200 mAh
  • Programming language: wiring
  • Sensors / input devices: TCRT 5000 Array
  • Target environment: indoor

This is a companion discussion topic for the original entry at https://community.robotshop.com/robots/show/arduino-based-line-maze-solver

tcrt5000 code

Hi,

I am using the same infrared sensor array (digital one) . But I was not able to optimize my code for line follower. Is it possible to post the code?

Thanks,

I should have mentioned it

I should have mentioned it in the post above but since it is really popular, I didn’t. The code is from patrick mccabe’s maze solver. It is written for the pololu array sensor but can be edited to suit the tcrt5000 array. 

Also, which gear motors are you using? As the code contains tweaks to keep the robot as close to the line as possible , if you have plastic geared dc motors, it might be a bit unstable.

-Ashim

 

Dear Ashim,I am also using

Dear Ashim,

I am also using magician chassis with plastic gear motors. When you are done with your code, I would like to compare with yours.

Ozhan

Did you check out the code

Did you check out the code that I mentioned? Check that out and I don’t think you will have much problems. The only difference is that it has values for the analog sensor so you’ll just need to replace them with the digital values. And you might want to add PWM too, just to lessen the speed of the plastic-geared motors.

I don’t think I have the code right now as this robot was built a year ago. Please post your edited code in the forum and I and the others will be happy to help you out!

Cheers,

-Ashim

 

need code

pls share code on [email protected]

need code

pls share code on [email protected]

code…

I am aslo working on this same project…please can u give me ur new code …it would be very helpful for me [email protected]

 

reg… maze solving robot

 i am working on this project can you please share the code and connections that you have done.

mail: [email protected]

i need the code please can i get its link or can you mail me at [email protected]

Hi, could you pass me the code for this robot? Thanks