Basic Usage
The Basic Usage Guide details the basics of using your LoCoBot including how to turn it on, how to charge it, and how to develop remotely.
Charging Your LoCoBot
Your LoCoBot should come with two AC adapter power supplies:
- A 19V 3.16A output for the Kobuki Base
- A 16.8V 2.5A output for the external battery
- Plug both of these into wall power and their respective port. The ports are sized differently and it is impossible to plug in the wrong charger.
- Turn on the Kobuki and check the Status LED on the back of the Kobuki base.
It should light up according to its charge level.
- Solid Green: Fully Charged
- Blinking Green: Charging
- Orange: Low Charge
- Check the 4 LEDs next to the external battery’s power button. They should
light up according to its charge level:
- Flashing Single LED: Low Voltage
- Solid Single LED: 0%-25% Charge
- Solid Two LEDs: 25%-50% Charge
- Solid Three LEDs: 50%-75% Charge
- Solid Four LEDs: 75%-100% Charge
- The Kobuki should take about 1.5 hours to charge. If on, it will play a sound to indicate that it is fully charged.
- The external battery should take about 6-8 hours to charge.
Note
You are able to use the devices on the robot while the external battery is charging. This includes things like developing and running programs on the NUC, using the camera, and using the lidar.
Note
You are able to use the Kobuki base while it is charging, though it is not recommended to move it around. The Kobuki base publishes data necessary for some ROS programs.
Turning On Your LoCoBot
- Press the button on the side of the external battery. The LEDs next to the battery will light up, indicating the external battery’s charge level. The battery will stay on while any connected device draws a load. Otherwise, it will automatically turn off after 30 seconds.
- Press the power button on the side of the NUC to turn it on. The NUC’s power button should light up blue.
- Flick the power switch on the rear of the Kobuki base to On. The Status LED will light up and the base will play a sound.
- Connect a monitor, mouse, and keyboard to the NUC. It is okay to unplug any peripherals so you have enough ports for the necessary devices.
LoCoBot Network Config
Note
Terminology:
- “Remote” - Your own personal computer (desktop, laptop, etc.)
- “Robot” or “LoCoBot” - The NUC computer on the LoCoBot
Note
This section assumes that you are interacting with your LoCoBot’s NUC computer using a monitor, mouse, and keyboard.
- Log into the
locobot
user on the LoCoBot using its default password,locobot
. - Open a terminal by pressing Ctrl+Alt+T.
- Type the command
hostname
to retrieve the robot’s hostname. This is the domain name of the computer that you will use when you SSH into it. This is typicallylocobot
.
Note
If you are using multiple LoCoBots, you should make each hostname unique,
i.e. locobot1
, locobot2
, etc.
$ hostnamectl set-hostname <unique_hostname>
- Connect the robot to the same WiFi that your remote computer is connected to.
- Ping the robot from your remote computer using the command below. If the
robot’s username or hostname are different than
locobot
, use that instead.
# ping usernane@hostname.local
$ ping locobot@locobot.local
- You should see something like the image below.
- Install the software that you plan to use, such as the ROS Interface. The quickstart commands for it are below. See the ROS Interface Software Setup for more information.
$ sudo apt install curl
$ curl 'https://raw.githubusercontent.com/Interbotix/interbotix_ros_rovers/main/interbotix_ros_xslocobots/install/amd64/xslocobot_amd64_install.sh' > xslocobot_amd64_install.sh
$ chmod +x xslocobot_amd64_install.sh
$ ./xslocobot_amd64_install.sh
- Reboot the NUC, remove the mouse, keyboard, and disconnect from the monitor. Plug back in any peripherals you removed.
Remote Development
Note
Terminology:
- “Remote” - Your own personal computer (desktop, laptop, etc.)
- “Robot” or “LoCoBot” - The NUC computer on the LoCoBot
General Remote Development
SSH Into the LoCoBot
- On your remote computer, install the OpenSSH Client software to allow for a secure shell connection between your remote computer and the LoCoBot computer.
$ sudo apt install openssh-client
- SSH into the LoCoBot from your remote computer with the display forwarding
flag
-X
. If the robot’s username or hostname are different thanlocobot
, use that instead.
# ssh -X username@hostname.local
$ ssh -X locobot@locobot.local
- If prompted, enter the password
locobot
and accept the SSH key. - Once logged in to the LoCoBot, you can open multiple SSH’ed terminals using the command below.
$ gnome-terminal &
- Sometimes, this doesn’t work. In that case, use the command from this Ask Ubuntu answer.
$ /usr/bin/dbus-launch /usr/bin/gnome-terminal &
VSCode Remote Development
- At Trossen Robotics, we use Microsoft’s VSCode and its Remote - SSH extension (also developed by Microsoft) for simple remote development on the LoCoBot.
- Install VSCode for Ubuntu.
- Open VSCode, Press Ctrl+P to launch the Quick Open Menu, and run the following command.
ext install ms-vscode-remote.remote-ssh
- In VSCode, press F1 and run the
Remote-SSH: Open SSH Host...
command. Enter the sameusername@hostname.local
combination you used when opening the SSH connection between your remote computer and the LoCoBot likelocobot@locobot.local
. If prompted, enter the passwordlocobot
. - Once connected, use File > Open Folder, and select the directory you
wish to operate in, i.e. the
~/interbotix_ws
directory if using the ROS Interface. - Your instance of VSCode is now attached to the LoCoBot and is open to your development workspace.
- You can open terminals in VSCode by pressing Ctrl-Shift-` or by using Terminal > New Terminal.
Note
It is not simple to configure display forwarding using the Remote-SSH extension at the time of writing this guide. To get around this, you can either follow some of the recommendations in this GitHub Issue, or just ssh into the locobot to launch programs with GUIs.
ROS Interface Development
If using the ROS Interface, we provide a remote workspace installation script. See the below commands for the remote installation quickstart commands. Run these commands on your remote computer.
$ sudo apt install curl
$ curl 'https://raw.githubusercontent.com/Interbotix/interbotix_ros_rovers/main/interbotix_ros_xslocobots/install/xslocobot_remote_install.sh' > xslocobot_remote_install.sh
$ chmod +x xslocobot_remote_install.sh
$ ./xslocobot_remote_install.sh
Alternatively, you can check the Remote Install section of the ROS Interface Software Setup for more information.
Turning Off Your LoCoBot
It is a good idea to cleanly turn off the NUC when you are finishing using it. To do this, type
sudo poweroff
in its terminal and enter your password.Note
This will kill any program currently running on the NUC. Make sure the arm is in its cradle and that ending programs will not harm the robot.
Press and hold the external battery’s power button for 2 seconds until the LEDs power off.
Flick the switch at the back of the Kobuki to power it off. The Status LED should turn off.