The modulce ‘measurement.py’ permit to manage the movings and note them during a campaign
Arguments : |
|
---|
example
>>> x_max = 20
>>> y_max = 12
>>> x_step = 1
>>> y_step = 1
"measurement.Measurement(x_max,y_max,x_step,y_step)"
The function ‘configurationNetwork’ permet to collect the fileds of the network card: fragment, tx_power and rts_cts with the help of the iwconfig function
Returns: | A dictionnary of the different fields (‘Fragment thr’,’Tx-Power’,’RTS thr’) |
---|
This function allow create the client to measure the bandwidth.
Argument : |
|
---|---|
Returns: |
|
The “forceWireless” function forces the wifi card to connect to a unique SSID or to an AP via its MAC address, or to a SSID on an AP.
Argument : |
|
---|
The function ‘get_coor’ permit to collect the current position.
Returns: | The function returns a tuple with the x and y values exemple: (2,5,1) |
---|
The function ‘iwlist’ permit to make the statement of base stations detected at the moment of the measurement with the iwlist command
Returns: | A list of dictionnary of the different fields |
---|
The function ‘measurementr’ permit to display the power list at a chosen moment with the help of the iwconfig command
Returns: | A dictionnary representing the different fields we listed with the iwconfig command Here are the dictionnary fields : ESSID, Access Point, Signal level, Bit Rate and Noise level. |
---|
The function ‘moveBack’ permit to take a few steps back during the measurements notes. It will manages the incrementation and decrementation of x and y the same way than the “moveForward’ function
Returns: | The function returns ‘True’ when everything went OK, and ‘False’ when it’s not possible to move forward anymore |
---|
The function ‘moveForward’ permits to create the journey to follow, to realize the measurements list It will manage the incrementation and decrementation of x and y, while avoiding the walls.
Returns: | The function returns ‘True’ when everything went OK, and ‘False’ when it’s not possible to move forward anymore |
---|
In the initialization, we manage to find the name of the wifi interface present on the machine