Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: No module named baxter_interface #85

Open
le-wei opened this issue Nov 11, 2019 · 1 comment
Open

ImportError: No module named baxter_interface #85

le-wei opened this issue Nov 11, 2019 · 1 comment

Comments

@le-wei
Copy link

le-wei commented Nov 11, 2019

Hello, I followed the official steps to install the SDK and set up some items that need to be set. I get an error when I execute the code below. Since I have just been exposed to ROS and Baxter, it is not too clear what the reason is. Looking at some of the information did not solve the problem. I hope you can help me. Thank you

import  rospy
import baxter_interface
rospy.init_node('Hello_Baxter')
limb = baxter_interface.Limb('right')
angles = limb.joint_angles()
print angles
angles['right_s0']=0.0
angles['right_s1']=0.0
angles['right_e0']=0.0
angles['right_e1']=0.0
angles['right_w0']=0.0
angles['right_w1']=0.0
angles['right_w2']=0.0
print angles

limb.move_to_joint_positions(angles)
wave_1 = {'right_s0': -0.459, 'right_s1': -0.202, 'right_e0': 1.807, 'right_e1': 1.714, 'right_w0': -0.906, 'right_w1': -1.545, 'right_w2': -0.276}

wave_2 = {'right_s0': -0.395, 'right_s1': -0.202, 'right_e0': 1.831, 'right_e1': 1.981, 'right_w0': -1.979, 'right_w1': -1.100, 'right_w2': -0.448}
for _move in range(3):
    limb.move_to_joint_positions(wave_1)
    limb.move_to_joint_positions(wave_2)
quit()

Error is as follows:
$ python baxter.py
Traceback (most recent call last):
File "baxter.py", line 7, in
import baxter_interface
ImportError: No module named baxter_interface

@le-wei
Copy link
Author

le-wei commented Nov 12, 2019

Thank you very much This issue has been resolved. Just add
source ~/baxter_ws/devel/setup.sh to ~/.bashrc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant