- Install necessary tools and utilities
sudo apt install git
sudo apt install net-tools
- Install ROS Melodic
- http://wiki.ros.org/melodic/Installation/Ubuntu
- Perform full desktop installation
- Install necessary ROS packages
sudo apt install ros-melodic-joy
- If you do not have a catkin workspace set up, create one:
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/src
echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc
- Clone repo into src directory. Make sure you are in catkin_ws/src.
git clone https://github.com/SDSU-Robotics/phoenix-template.git
.
- Build repository
cd ~/catkin_ws; catkin_make
- Source executables
source ~/.bashrc
Configure Interface
-
sudo gedit /etc/network/interfaces
(if that doesnt work, trynano
in plasce ofgedit
) -
Add these lines below the text already in the file and save (Each point is one line)
allow-hotplug can0
iface can0 can static
bitrate 1000000
txqueuelen 1000
up /sbin/ip link set $IFACE down
up /sbin/ip link set $IFACE up type can
-
A warning about not being able to save metadata will show up, that is fine.
Connect the CAN interface. The light will turn green if it is configured properly
- Connect CAN interface
- Connect game controller
- Call launch file
roslaunch phoenix-template TalonTest.launch
- Motor controller lights will turn to flashing orange
- Replace
TalonTest.launch
with the name of whatever launch file you wan to run.