Skip to content

Commit

Permalink
Revert "Merge branch 'main' into supervisor_computer"
Browse files Browse the repository at this point in the history
This reverts commit 2d0784c, reversing
changes made to 6d27814.
Brought back Files after mistaken merge
  • Loading branch information
sdekhterman committed Oct 17, 2024
1 parent 2d0784c commit 6ebac66
Show file tree
Hide file tree
Showing 71 changed files with 10,874 additions and 4 deletions.
248 changes: 248 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,248 @@
# Prerequisites
*.d

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/
cover/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
.pybuilder/
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
# For a library or package, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# .python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# poetry
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
# This is especially recommended for binary packages to ensure reproducibility, and is more
# commonly ignored for libraries.
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
#poetry.lock

# pdm
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
#pdm.lock
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
# in version control.
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
.pdm.toml
.pdm-python
.pdm-build/

# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

# pytype static type analyzer
.pytype/

# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/

devel/
logs/
build/
bin/
lib/
msg_gen/
srv_gen/
msg/*Action.msg
msg/*ActionFeedback.msg
msg/*ActionGoal.msg
msg/*ActionResult.msg
msg/*Feedback.msg
msg/*Goal.msg
msg/*Result.msg
msg/_*.py
build_isolated/
devel_isolated/

# Generated by dynamic reconfigure
*.cfgc
/cfg/cpp/
/cfg/*.py

# Ignore generated docs
*.dox
*.wikidoc

# eclipse stuff
.project
.cproject

# qcreator stuff
CMakeLists.txt.user

srv/_*.py
*.pcd
*.pyc
qtcreator-*
*.user

/planning/cfg
/planning/docs
/planning/src

*~

# Emacs
.#*

# Catkin custom files
CATKIN_IGNORE

86 changes: 82 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,85 @@


# Rgator_computer_ws

# Rgator_supervisor_computer_ws
supervisor computer: localization, control, and vehicle interface

perception computer: sensor interface, perception, and planning


## ROS2 Packages:

### dbw:
- dbw: subscribe control command
- dbw_read: subscribe control command; read CAN bus data, convert to ROS2 topic

### joy_control:
- joy_control: subscribe joystick input and publish contorl command

### dbw_msgs:
- Dbw: define control command
- [PGNs]: vehicle CAN bus data msg

### vectornav:
- vectornav: gnss-ins-imu driver
- vectornav_msgs: gnss-ins-imu msg

### gps_nav:
- pid: control vehicle speed only
- pp_pid: pure pursuit for steering control, pid for speed control
- track_log: log x,y,heading data from imu, convert to .csv file
- path_visual: visualize track

 

## Driver Usage:

### Joystick driver:
default joystick input frequency at 20Hz:

ros2 run joy joy_node

set joystick input frequency as 40Hz:

ros2 run joy joy_node --ros-args -p autorepeat_rate:=40.0

### Drive-by-wire:
control the vehicle only:

ros2 run dbw dbw

control the vehicle and read CAN bus data:

ros2 run dbw dbw_read

### Vectornav GNSS-INS sensor:
launch with modified configuratuion file:

ros2 launch vectornav vectornav.launch.py



 

## Project Application:

### Joystick control

ros2 run joy joy_node
ros2 run joy_control joy_control
ros2 run dbw dbw

or

ros2 launch joy_control joy_control_launch.py

### Path track

ros2 launch vectornav vectornav.launch.py
ros2 run dbw dbw
ros2 run gps_nav pp_pid

### Path log

ros2 launch vectornav vectornav.launch.py
ros2 run gps_nav track_log



1 change: 1 addition & 0 deletions dbw/.~lock.R-Gator CAN Protocol.doc#
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
,jamie,jamie--P1,15.09.2023 13:33,file:///home/jamie/.config/libreoffice/4;
Binary file added dbw/R-Gator CAN Protocol.doc
Binary file not shown.
17 changes: 17 additions & 0 deletions dbw/dbw/C_library/helper.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#include <stdio.h>

int square(int i)
{
return i*i;
}

struct Sumup
{
int num1;
int num2;
};

int mysum(struct Sumup num)
{
return num.num1 + num.num2;
}
Binary file added dbw/dbw/C_library/helper.so
Binary file not shown.
Binary file added dbw/dbw/C_library/libwdt_dio.so
Binary file not shown.
10 changes: 10 additions & 0 deletions dbw/dbw/C_library/makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
CFLAGS=-Wall -Wstrict-prototypes -O2

test_CAN: test_CAN.o
gcc -pthread -o test_CAN test_CAN.o -L/usr/lib -lwdt_dio

test_CAN.o: test_CAN.c
gcc -c $(CFLAGS) -I../../include test_CAN.c

clean:
rm -f test_CAN.o test_CAN
Loading

0 comments on commit 6ebac66

Please sign in to comment.