Skip to content

Latest commit

 

History

History
102 lines (72 loc) · 4.01 KB

README.md

File metadata and controls

102 lines (72 loc) · 4.01 KB

Visual Circuit +

Contributors Forks Stargazers Issues License

Visual Circuit+ is an open source tool to use RoboticsAcademy alongwith Visual Circuit. We start a Docker image of Robotics Academy and connect to it with our Visual Circuit instance. This is done in order to able to use Circuits directly from the web-editor and run them with RoboticsAcademy exercises.

For more information visit our site VisualCircuit

Prerequisite

Front-end

For more specific instructions check the frontend readme

  1. Clone the repository https://github.com/JdeRobot/VisualCircuit.git
  2. Change directory to frontend
  3. Run npm install

Back-end

For more specific instructions check the backend readme

  1. Clone the repository https://github.com/JdeRobot/VisualCircuit.git
  2. Change directory to backend
  3. Create a Python3 virtual environment using venv. For eg. python -m venv .venv
  4. After activating the virtual environment, install the dependencies by running pip install -r requirements.txt
  5. Add .env file to the backend folder. And add the variables as defined in .env.template
  6. Create the static files to serve during execution by python manage.py collectstatic

How to setup the VC+

  1. Navigate to VC+:cd VC+
  2. Activate the environment:source env/bin/activate
  3. Install required packages
pip install django
pip install djangorestframework
pip install django-webpack-loader
  1. Install dependencies for REACT (with Yarn or npm, required Node.JS >= 14.16)
cd react_frontend/ && yarn install 

Start Application

Step 1: Start Frontend

  1. Navigate to the frontend directory:cd frontend
  2. Start the frontend server:npm start

Step 2: Start Backend

  1. Navigate to the backend directory:cd backend
  2. Start the backend server:python3 manage.py runserver 8080

Step 4: Start VC+ Frontend

  1. Navigate to VC+:cd VC+
  2. Navigate to the react_frontend directory:cd react_frontend
  3. Run the development server:yarn run dev

Step 5: Start Another Backend Instance

  1. Open another terminal.
  2. Navigate to VC+:cd VC+
  3. Activate the environment:source env/bin/activate
  4. Start another instance of the backend server:python3 manage.py runserver

Step 6: Run Docker image RADI

sudo docker run --rm -it --name radi -p 2303:2303 -p 1905:1905 -p 8765:8765 -p 6080:6080 -p 1108:1108 -p 7163:7163 jderobot/robotics-academy:3.4.5 --no-server