## For instruction on writing tutorials ## http://www.ros.org/wiki/WritingTutorials #################################### ##FILL ME IN #################################### ## for a custom note with links: ## note = ## for the canned note of "This tutorial assumes that you have completed the previous tutorials:" just add the links ## note.0= ## descriptive title for the tutorial ## title = Network Setup ## multi-line description to be displayed in search ## description = Configuration for network communication between Robot and Remote PC ## the next tutorial description (optional) ## next = ## links to next tutorial (optional) ## next.0.link= ## next.1.link= ## what level user is this tutorial for ## level= BeginnerCategory ## keywords = #################################### <> ## AUTOGENERATED DO NOT DELETE ## TutorialCategory ## FILL IN THE STACK TUTORIAL CATEGORY HERE == First interaction with Ethernet cable == For the first time, you can access the onboard computer by connecting Ethernet cable between your computer and the Ethernet port on the user panel. To be able to establish network connection to robot, you need to set static IP address on your computer. You can choose any IP address on '''`192.168.2.x`''' IP block other than '''`192.168.2.1`''' which is the address of the onboard computer. After cable is connected, you can log in to onboard computer using SSH with command; {{{ $ ssh mrp2@192.168.2.1 }}} The default password for MRP2 robot is '''`temppwd`'''. == Wireless access == If you want to access MRP2 wireless, you can configure it to join your local wireless network. You need to configure once, after that robot will join wireless network automatically when powered up. First step is to connect to robot via cable and SSH into it (described in above). Now you need to edit network interfaces settings. Run; {{{ $ vim /etc/network/interfaces }}} For static IP application, add these lines to the bottom of the file, save and exit. {{{ auto wlan0 iface wlan0 inet static address netmask gateway wpa-ssid wpa-psk dns-nameservers }}} For example; {{{ auto wlan0 iface wlan0 inet static address 192.168.1.5 netmask 255.255.255.0 gateway 192.168.1.1 wpa-ssid MyHomeWifiNetwork wpa-psk 123456secret123456 dns-nameservers 8.8.8.8 8.8.4.4 }}} For DHCP application, add these lines to the bottom of the file, save and exit. {{{ auto wlan0 iface wlan0 inet dhcp wpa-ssid wpa-psk }}} For changes to take effect, run this command; {{{ $ sudo ifdown wlan0 && sudo ifup wlan0 }}} Now the robot should be connected to your wireless network. You can unplug the cable and login again using SSH over your wireless network. If you need to install a package from online repositories, then you will need to connect the robot to the internet. If your wireless network does not provide internet connection, then you can change the network configuration to connect another network with internet connection. After this operation, you should change the default network adapter configuration in robot upstart. To do this, run these commands; {{{ $ rosrun robot_upstart uninstall mrp2 $ rosrun robot_upstart install mrp2_bringup/launch/base.launch --setup '/etc/mrp2/setup.bash }}} If you are new in ROS and didn't navigate robot, we recommend to starting with Simulation [[mrp2_gazebo/Tutorials/Launching robot in Gazebo Simulator and driving it| Tutorial]]s.