Skip to content

Commit 0c1604c

Browse files
committed
finished readme
1 parent 4ab5e41 commit 0c1604c

5 files changed

Lines changed: 9 additions & 19 deletions

File tree

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Follow this flow chart in order to find which script to run depending on your ne
2121
This script enables the user to extract the raw DW1000 data from the HiveBoard/BeeBoards assembly. The test-bench will turn by a chosen stepping angle and acquire the desired amount of raw data per step.
2222
#### Hardware setup
2323
- Place a BeeBoards assembly in the middle of the test-bench. The 0deg axis of the assembly needs to point in a parallel fashion to the mounted laser pointer.
24-
- The BeeBoards have to be connected to a HiveBoard mounted to the test-bench using the same cable and ports as labeled on the assembly. If the cables and assembly are not indicated be sure to note which BeeBoards are used, plugged with which cables and in which channel on which HiveBoard. The calibration will only be valid for this configuration and has to be completly re-performed if any of this component is changed or plugged differently.
24+
- The BeeBoards have to be connected to a HiveBoard mounted to the test-bench using the same cable and ports as labeled on the assembly. If the cables and assembly are not indicated be sure to note which BeeBoards are used, plugged with which cables and in which channel on which HiveBoard. **The calibration will only be valid for this configuration and has to be completly re-performed if any of this component is changed or plugged differently.**
2525
- Connect power and communication interface to the HiveBoard.
2626
- Connect a usb cable to the Arduino.
2727
- Connect power to the drive submodule (red = 12 V, white = ground)
@@ -49,13 +49,13 @@ The data extracted will be saved upon completion of the acquisition once the des
4949
Once these parameters have been adjusted, the file can be run. The *TurningStation* should turn the amount entered in `step` and then stop for 3-5 seconds for the acquisition period before starting to turn again, repeting this cycle until `destination` has been reached. A complete turn takes usually around 15 minutes.
5050

5151
#### Note
52-
Communication with the HiveBoard is done using the pheromones submodule. If communication problem occur, ensure that the version used by the script is the same as on the HiveBoard.
52+
Communication with the HiveBoard is done using the [Pheromones submodule](https://github.com/SwarmUS/Pheromones). If communication problems occur, ensure that the version used by the script is the same as on the HiveBoard.
5353
## Parser
5454
Parses and presents the PDOA values from the previously acquired raw data (from [ExtractRawData](#pxtractRawData)). The user will be prompted 2 clickable interfaces to firstly offset the data to a common reference and secondly to extract the slopes of each antenna pair.
5555
#### Runnning the script
5656
The script can be run from `src/parser`.
5757
#### Adjustable parameters
58-
`dataFolderPath` : folder path where the extracted raw data CSV produced by [ExtractRawData](#pxtractRawData) has been save.<br />
58+
`dataFolderPath` : folder path where the extracted raw data CSV produced by [ExtractRawData](#pxtractRawData) has been saved.<br />
5959
`dataName` : name of the file to parse the data from.<br />
6060
`usedPairs` : the antenna pairs to be used. Encoded as follow :<br />
6161
<pre><code> pair 0 = antenna 0 - antenna 1<br />
@@ -86,10 +86,10 @@ The script can be run from `/src/send_angle_params`.
8686
hb_stream = UsbStream('COM16')
8787
```
8888
#### Behavioral description
89-
When the script is ran, the parameters in the calibration folder will be sent to the connected Hiveboard and saved in the flash memory. Thus, there is no need to re-send the parameters on every boot cycle. The calibration should be performed occasionally to ensure the system reliability.
89+
When the script is ran, the parameters in the calibration folder will be sent to the connected Hiveboard and saved in the flash memory. Thus, there is no need to re-send the parameters on every boot cycle. **The calibration should be performed occasionally to ensure the system reliability.**
9090

9191
#### Note
92-
Communication with the HiveBoard is done using the pheromones submodule. If communication problem occur, ensure that the version used by the script is the same as on the HiveBoard.
92+
Communication with the HiveBoard is done using the [Pheromones submodule](https://github.com/SwarmUS/Pheromones). If communication problems occur, ensure that the version used by the script is the same as on the HiveBoard.
9393
## Visualization
9494
When a calibration has been completly transfered to the correspondant Hiveboard, this tool can be used to manually and visually confirm the effectiveness of the calibration. Using a emmiter, the user can move around the calibrated Hiveboard/BeeBoards assembly and see a marker representing the emmiter move around.
9595

@@ -111,7 +111,7 @@ neighbors can be hidden by unchecking the 'visible' check box in the table under
111111
![](img/visualisation_tool.png)
112112

113113
#### Note
114-
Communication with the HiveBoard is done using the pheromones submodule. If communication problem occur, ensure that the version used by the script is the same as on the HiveBoard.
114+
Communication with the HiveBoard is done using the [Pheromones submodule](https://github.com/SwarmUS/Pheromones). If communication problems occur, ensure that the version used by the script is the same as on the HiveBoard.
115115
## Validate
116116
This is a method to test the whole angles system of the interlocalisation. Using the exact same hardware setup as the calibration it is possible to extract the angle value result from the whole acquisition, linearisation and certitude algorithm. Using the test-bench assembly will automate this procedure.
117117
#### Runnning the script
@@ -135,7 +135,7 @@ testbench = TurningStation('/dev/ttyACM1', 115200)
135135
The data extracted will be saved upon completion of the acquisition once the destination has been reached.
136136

137137
#### Behavioral description
138-
Similarly to [ExtractRawData](#extractRawData), the *TurningStation* will turn by the `stepSize` incrementation until it reaches the `destination` encoder tick. At each increment, the interlocalisation is enabled and produces `NUM_DATA_POINTS_PER_ANGLE` angles. These values are the one that would be propagated in the system in a typical use case. For a complete description of the process behind these values, please refer to [link to la doc a charles sur l'interloc].
138+
Similarly to [ExtractRawData](#extractRawData), the *TurningStation* will turn by the `stepSize` incrementation until it reaches the `destination` encoder tick. At each increment, the interlocalisation is enabled and produces `NUM_DATA_POINTS_PER_ANGLE` angles. These values are the one that would be propagated in the system in a typical use case. For a complete description of the process behind these values, please refer to Swarmus official [interlocalisation documentation]( https://swarmus.github.io/SwarmUS-doc/sections/reference/Interloc/how_it_works/intro/).
139139

140140
#### Results
141141
The saved data is found in the `/src/data` folder. Each CSV is timestamped and named using the "validation_" prefix. For a visual analysis of the data, 3 plots have already been created. Running `src/analysis/analyze_interloc_validation` will produce:
@@ -147,4 +147,4 @@ Similarly to [ExtractRawData](#extractRawData), the *TurningStation* will turn b
147147
analyze_validation("../data/validation_hb6.csv")
148148
```
149149
#### Note
150-
Communication with the HiveBoard is done using the pheromones submodule. If communication problem occur, ensure that the version used by the script is the same as on the HiveBoard.
150+
Communication with the HiveBoard is done using the [Pheromones submodule](https://github.com/SwarmUS/Pheromones). If communication problems occur, ensure that the version used by the script is the same as on the HiveBoard.

img/calibration_flow.png

76 Bytes
Loading

src/parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
EXPORT_PDOA = True
1111

12-
dataFolderPath = "C:/Users/huber/USherbrooke/SwarmUs - General/Interlocalisation/Angles/HiveBoard"
12+
dataFolderPath = "../src/data"
1313
if not os.path.exists(dataFolderPath+"/"+"figures"):
1414
os.makedirs(dataFolderPath+"/"+"figures")
1515

src/parser/computeAngle.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ def PDOA(d,columnsSFD,columnsCIR,angles,offset=None):
2525

2626

2727
PDOA = {}
28-
scaleFactor = {}
2928
i = 0
3029
for col1,_ in enumerate(columnsSFD):
3130
for col2,_ in enumerate(columnsSFD):
@@ -44,7 +43,6 @@ def PDOA(d,columnsSFD,columnsCIR,angles,offset=None):
4443
else:
4544
scaleFactor = 1
4645
theta = np.mod((part2 + offset[name[i]]), 2 * np.pi) - np.pi
47-
# PDOA[name[i]][a] =theta *90/np.pi
4846
PDOA[name[i]][a] = np.arcsin(theta/np.pi) * 180/np.pi * scaleFactor
4947
i = i+1
5048
return PDOA

src/parser/parsing.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@ def bundle(df):
1111

1212
def remAnormalRx(df):
1313
cdf = df
14-
# if not the same message on the 3
15-
16-
# if the TS is anormal
1714
rxTimestampsCol = df.columns.values[[2, 6, 10]]
1815
val0 = df[rxTimestampsCol[0]]
1916
val1 = df[rxTimestampsCol[1]]
@@ -25,11 +22,6 @@ def remAnormalRx(df):
2522
cdf = cdf.drop(i-numDrop)
2623
return cdf
2724

28-
29-
# should remove the clock wrapping
30-
# def remClockWrap(dic):
31-
32-
3325
def flatten (df,columns,x=None):
3426
flat_dic = {}
3527
if x is not None:

0 commit comments

Comments
 (0)