Difference between revisions of "FREE - Framework for Remote Experiments in Education"
Line 48: | Line 48: | ||
the struct of the is the following: {"RPi_IP":{"segredo":"password","nome":"Name_of_the_exp"},...} | the struct of the is the following: {"RPi_IP":{"segredo":"password","nome":"Name_of_the_exp"},...} | ||
+ | |||
+ | === Config File JSON === | ||
+ | |||
+ | In the projext of the Main_Server there is a folder called Configs, in there are all the cofiguracion files of the experience linked to the Main_Server, so to add a new experement you just have to copy one of the existin files and change its nome to the não of the experiment and change the parameters in the configue file: | ||
+ | |||
+ | [[File:Config_JSON.jpg]] |
Revision as of 18:19, 12 August 2021
- TODO Ainda estou a escrever(Rossa)
Contents
Pre-requisites
Build environment
- Git (2.30.2+)
- Python (3.7.0+)
Install
Raspberry PI Server (RPI_Server)
Setup python3 environment variable pointing to run the version installed (in this exemple is for python3.7) by:
$ sudo nano ~/.bashrc
edit it adding to the end:
$ alias python3="python3.7"
First checkout the project from github:
$ git clone https://github.com/e-lab-tecnico-ulisboa-pt/RPi_Server-PG
then edit the "main.py" file and change the following global variables:
SERVER = "main_server_IP" MY_IP = "RPi_IP" SEGREDO = "password" PORT = Port_to_comunication BINARY_DATA_PORT = Port_to_transfer_Binary_data
Main Server (Main_Server)
This sowftware is the thispatcher of the information. By allowing the communications form the frontend and each RPi_Server responsable for a experience. To install this you need to install at least Python 3.7 and the lib Flask (https://pypi.org/project/Flask/).
Then go to the project from github:
$ git clone https://github.com/e-lab-tecnico-ulisboa-pt/Main_Server-RexC
Edit the "main.py" file and change the following global variables:
SERVER = "main_server_IP" MY_IP = "RPi_IP" SEGREDO = "password" PORT = Port_to_comunication BINARY_DATA_PORT = Port_to_transfer_Binary_data
After that you need to change or edit this last one variable "segredos",
the struct of the is the following: {"RPi_IP":{"segredo":"password","nome":"Name_of_the_exp"},...}
Config File JSON
In the projext of the Main_Server there is a folder called Configs, in there are all the cofiguracion files of the experience linked to the Main_Server, so to add a new experement you just have to copy one of the existin files and change its nome to the não of the experiment and change the parameters in the configue file: