This repository contains portions of the code for the Unicamp E-Racing telemetry system, showcasing the work done for demonstration purposes.
In the "How It Works" folder, you'll find detailed information about the architecture. Feel free to explore!
To run the complete telemetry stack in production mode, first install Docker and Docker Compose.
Before installing SocketCAN, it's recommended to verify if it's already available on your system. Open a terminal and execute the following command:
sudo modprobe can
Note: If the command returns an error message, SocketCAN is not installed. If it returns nothing, SocketCAN is already installed.
If SocketCAN is not already installed, follow these steps:
- Open a terminal window and install the
can-utils
package:
sudo apt-get install can-utils
- After the package is installed, load the CAN module:
sudo modprobe can
- Create a virtual CAN using the script "create_vcan.sh":
sh simulator/create_vcan.sh
- Run the CAN message decoder:
python3 decode_can.py
- In a separate terminal, launch the CAN message metric generator:
python3 pycan.py
- In yet another terminal (yes, quite a few terminals), execute:
bash scripts/run-dev.sh
Note: Front-end may not be built yet.
- Open your preferred browser and visit:
-
Log in using the following credentials:
- User: admin
- Password: admin
-
Access our Data Source on the side bar:
- Configuration > Data Sources > Unicamp E-Racing
Note: Select it and run a test.
-
Select "Create" and then "Import", import the .json files from the dashboards and then access them.
* Production mode doesn't allow frontend/backend debugging, hot code reloads and unsigned Grafana plugins. Refer to the Development Setup if you want to run it in development mode.