Go Down

Topic: Line maze solver/w shortest path algorithm (Read 2598 times) previous topic - next topic

AwesomeDeepesh

hello every one....
I am trying to make a line maze solver with the shortest path algorithm
and I need a little help I have attached the code please have a look at it and help me out
and please tell me if I can do anything to replace the 999999999999999999999999999999
in my code




Thanks in advance to anyone who tries to help me out

MarkT

You are going to need some datastructures to represent the maze.  Is that what the path thing is for?
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

PaulS

Code: [Select]
char path[999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999]

I don't think my PC even has enough memory to hold that array, and it has 8,000,000 times as much memory as a Uno.
The art of getting good answers lies in asking good questions.

AwesomeDeepesh

#3
Dec 23, 2015, 06:09 pm Last Edit: Dec 23, 2015, 06:32 pm by AwesomeDeepesh
i have changed the 99999999999999999999999999999999999999999999999999999999999 to 500

PaulS

i have hanged the 99999999999999999999999999999999999999999999999999999999999 to 999
And? What happened?
The art of getting good answers lies in asking good questions.

AwesomeDeepesh

#5
Dec 23, 2015, 06:26 pm Last Edit: Dec 23, 2015, 06:40 pm by AwesomeDeepesh
please refer to this website


http://embedjournal.com/shortest-path-line-follower-robot-logic-revealed/

I got the algorithm from here and I am not able to complete it...
I have fixed some parts of the code please review it
I am having trouble with the cancellation part

AwesomeDeepesh


PaulS

The code you posted does what? How does that differ from what you want?
The art of getting good answers lies in asking good questions.

Go Up