Ask Your Question

Revision history [back]

I had the same problem. Since the EeePC 1215N was discontinued, the Turtlebot now ships from I Heart Robotics with a Lenovo ThinkPad X130e. This laptop's battery shows up in /proc/acpi/battery/BAT1, not BAT0 as is hardcoded into ROS electric's Also, the battery's capacity and charge state is reported in mW instead of mA, so just swapping BAT0 to BAT1 in the script doesn't fix it.

I've uploaded an updated version of electric's that should fix both of these problems:

I use a shell glob to find BAT*, and recognize either mW or mA for battery capacity. This should work with both EeePC and ThinkPad based turtlebots, but I only have the ThinkPad to test with. To use the new script, from your turtlebot:

  1. wget
  2. sudo cp /opt/ros/electric/stacks/turtlebot/turtlebot_node/scripts/
  3. sudo rosmake turtlebot_node
  4. sudo service turtlebot restart