mirror of
https://github.com/elephantrobotics/mycobot_ros.git
synced 2026-07-05 19:47:04 +00:00
change baud
This commit is contained in:
parent
63d872461b
commit
cca5330483
1 changed files with 3 additions and 5 deletions
|
|
@ -25,12 +25,10 @@ def callback(data):
|
|||
def listener():
|
||||
global mc
|
||||
rospy.init_node("mycobot_reciver", anonymous=True)
|
||||
port = subprocess.check_output(['echo -n /dev/ttyAMA*'],
|
||||
shell=True)
|
||||
|
||||
port = rospy.get_param("~port", port)
|
||||
baud = rospy.get_param("~baud", 1000000)
|
||||
# 1000000
|
||||
port = rospy.get_param("~port", "/dev/ttyAMA0")
|
||||
baud = rospy.get_param("~baud", 115200)
|
||||
# 115200
|
||||
mc = MyCobot(port, baud)
|
||||
|
||||
rospy.Subscriber("joint_states", JointState, callback)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue