Skip to content

uw-midsun/CAN-Explorer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CAN-Explorer

An application to visualize CAN data and interact with the CAN bus

SSH into the vagrant box and run

git clone https://github.com/uw-midsun/CAN-Explorer.git
cd CAN-Explorer

Docker install

If you haven't installed Docker on the development box already, run the following

curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh ./get-docker.sh
sudo groupadd docker
sudo usermod -aG docker $USER
newgrp docker

Note: To verify that the installation was successful you can run

docker run hello-world

To set up Docker Compose run

sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose

To verify that the installation was successful you can run

docker-compose --version

If any issues prop up, please consult the official Docker installation article for Ubuntu Linux and post-installation steps

Usage

To test without a CAN bus run sudo make socketcan.

To start the frontend and the influxdb engine, run docker-compose up then head over to localhost:3000 in your local browser to view the CAN-Explorer frontend.

To stop the containers, run docker-compose stop

InfluxDB login

Username: firmware

Password: ilovecans

To visualize the data coming in, refer to the "Explore" section in the InfluxDB UI

For some handy common templates, look through the Boards we have under the CAN-Explorer dashboard.

Flux cheatsheet

The default graphs should have most of the common views you'll be using often. However if you want to add some extra constraints, you will need to specify so using InfluxDB's special SQL-like language "Flux". Here's a quick cheatsheet for commands you'll likely need.

Specify values between a range

from(bucket:"example-bucket")
  |> range(start:-1h)
  |> filter(fn: (r) => r._value > 50.0 and r._value < 65.0 )

Look for a certain CAN Message

from(bucket: "converted_data")
  |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
  |> filter(fn: (r) => r["_field"] == "vehicle_velocity_left") // replace with appropriate CAN Message
  |> group()

Only keep certain columns

from(bucket: "raw_data")
  |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
  |> keep(columns: ["bin", "hex"])
  |> group()

Consult the official Flux Documentation for more examples.

About

An application to visualize CAN data and interact with the CAN bus

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published