EV3 Robot mapping, nodes and an objective

This is where you talk about the EV3 software itself, installation issues, and programming talk.

Moderators: roger, gloomyandy, skoehler

New User
Posts: 4
Joined: Thu Nov 26, 2015 7:49 pm

EV3 Robot mapping, nodes and an objective

Postby Egert » Mon Jan 18, 2016 5:21 pm

Hello Lejos developers!

It has been while since I last wrote to you, but now I've run into a big problem regarding the mapping of the board and nodes. We were trying to force the map reading at first, but got an awful answer from the teacher as he wants us to use heurestic search rather than forcing it through.
I came here to ask for some examples or tutorials that teach how the node class of ev3 works.

My goal is to map the whole board, ignoring the red borders with a color sensor ( these are classed as walls ). To remove the node from its neigbour i was thinking of using node.removeNeigbour. Also I need to ignore going into two tiles that have Sheeps (two objects regonizable by ultrasonic sensor).

After the whole map is visited at least one time(or marked that there was an obstacle in that tile), it has to return to the starting position.

After this he has to get the two objects to the final position across the map.

I was wondering if anyone has worked this way with the node class and could give me some tips and tricks.

My idea was trying to check it tile by tile, row by row until whole map is cleared of obstacles.

I will add a pseudocode.

Code: Select all

   Move East until on border
      check Walls and Sheeps
         go around them
   Move tile up and continue until:
      finished map horizontally.
   Go through map vertically to assure every connection between nodes has been checked.
   return to start

The map is a 6x6 square with possible positions of walls in all between them ( including a case where a tile might be blocked by 4 walls (deleting the node? ))

Return to “EV3 Software”

Who is online

Users browsing this forum: No registered users and 2 guests