From 6e1445c22c3d3db9b2ecb21448b87399f4d2289e Mon Sep 17 00:00:00 2001 From: Simon Fortier Date: Fri, 10 Nov 2017 21:54:56 -0500 Subject: [PATCH] Updated Hardware: LiDAR (markdown) --- Hardware:-LiDAR.md | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Hardware:-LiDAR.md b/Hardware:-LiDAR.md index f3e5240..4848f08 100644 --- a/Hardware:-LiDAR.md +++ b/Hardware:-LiDAR.md @@ -13,8 +13,13 @@ Hardware ID: `0x0003` | `2` | `GET_PATH` | `50 kJ` | Calculate the shortest path to the specified coordinates and copy it to memory| | `3` | `GET_MAP` | `10 kJ` | Generate the current World's map and copy it to memory | -`GET_PATH` Generates a path as a direction sequence of 1 word each starting at memory address `0x0000` -`GET_MAP` Generates a map of the current world as a tile sequence of 256 words starting at memory address `0x0100`, each word representing a tile. The LiDAR starts reading the tiles west to east, north to south: (0,0) (1,0) (2,0) ... (15,0) (0,1) (1,1) ... +`GET_PATH` generates a path as a direction sequence of 1 word each starting at memory address `0x0000` + `NORTH` = `0x0000` +`EAST` = `0x0001` +`SOUTH` = `0x0002` +`WEST` = `0x0003` + +`GET_MAP` generates a map of the current world as a tile sequence of 256 words starting at memory address `0x0100`, each word representing a tile. The LiDAR starts reading the tiles west to east, north to south: (0,0) (1,0) (2,0) ... (15,0) (0,1) (1,1) ... Each tile is is encoded as a bit field: `1000 0000 0000 0000` (`0x8000`) : Blocked (wall) tile