Ask Your Question

packrat's profile - activity

2015-05-26 07:50:42 -0500 received badge  Good Question (source)
2014-01-28 17:30:03 -0500 marked best answer How to read encoder ticks from arduino with pyserial

I am using a arduino due to read two encoders for wheel position. How do I send those number strings to the pyserial and have pyserial read it as left, right wheel(for ros Odom)? I am not all that good at programming, so how would I setup up the sending side and the receiving side? The encoders resolution is 4096 tick/rev and full motor speed is 3k rpm. I am using the output for the differential_drive ros package.

2014-01-28 17:29:46 -0500 marked best answer serial numbers in a launch file.

I am new to ros and I am trying to create a launch file to start two motor controllers, roscore, and some other nodes. I have two motor controllers that are identical except for their serial number. When using the terminal I would type (each in its own terminal),

rosrun pololu_smc_driver smc_driver_node __name:=r_controller _smc_serial:="3800-6F06-3055-3932-7560-0343"

rosrun pololu_smc_driver smc_driver_node __name:=l_controller _smc_serial:="3800-6B06-3055-3932-4160-0343"

Doing that would make two nodes, one named "r_controller" using the device with the serial number of" 3800-6F06-3055-3932-7560-0343" and the other node being "l_controller" with its serial number. How do I do that same thing in the launch file? What would that translate to?

2014-01-28 17:29:16 -0500 marked best answer chipkit max32 Lost sync with device, restarting...

I am trying to run the rosserial tutorial "hello world" on a chipkit max 32. I can compile and upload to program to the max32. when I run "rosrun rosserial_python /dev/ttyUSB1", it returns ROS Serial Python Node Connected on /dev/ttyUSB1 at 57600 baud then after several seconds it returns [ERROR] Lost sync with device, restarting.... when I first start the python node the tx light blinks and every time the node tries to connect. I have read other posts, but non of them seem to answer or fix the issue. The max 32 is almost identical to the arduino due but it runs on a pic controller. I am using the latest mpide 23. I am not sure how to get it to connect and work.

2014-01-28 17:28:42 -0500 marked best answer what hardware should I use for wheel encoders.

I am building a differential drive robot from an old powered wheelchair. The wheels are attached to the motor by a ~10:1 gearbox. I would like to add encoders to the motors. what kind of encoders should I use. I am running a full PC onboard. I have a chip kit max32 that I could use as an interface. What is the best way to add encoders. Is there a useful usb interface? What kind resolution should I look at. The motor drivers I am using do not have encoder feedback. Thanks for any feedback.

2014-01-28 17:28:15 -0500 marked best answer Is ROS for me?

I am building a hobby robot from a old powered wheelchair. For the brains I have built a mini PC (intel core i3). For the motor controllers I am using two 25amp pololu simple motor controllers that can controlled over USB. I have a USB video camera that I'll use as well as a high power wifi radio. I consider myself to be a beginner at the software side of robotics. I have programmed some with the arduino compiler and visual basic. For right now I would like to be able to control the robot remotely and see what it sees. Just something to play around with until I can program more complex actions. My question is, is ros the best route for me to start from scratch with?

2013-10-28 09:51:57 -0500 received badge  Famous Question (source)
2013-07-24 00:31:27 -0500 received badge  Taxonomist
2013-07-23 18:20:18 -0500 marked best answer where do I need to start

I am very new to ros and i am building a robot from an old powered wheelchair containing a full PC, two USB high power motor controllers, USB camera on a RC pan and tilt, high power WiFi radio. my goal for this robot for now is remote control over the WiFi. I have installed ros and have run through most of the beginner tutorials. my question is, where do i start. what are the steps that i need to follow to make it remote controlled. i have no software written for this robot.

2013-07-18 23:52:40 -0500 received badge  Famous Question (source)
2013-06-04 18:38:44 -0500 received badge  Nice Question (source)
2013-06-04 18:34:09 -0500 marked best answer how to make rosserial work with 32 bit micro controller. please help

I have a max32 and I am trying to relay wheel encoder data from the max32 board to ros. The max32 is a arduino compatible device. It is almost identical to the arduino 2500 or the due, except the max32 is a pic32 and 32 bit. I tried rosserial_arduino, but looses connection and tries to reconnect. I'm not sure how to write a new hardware class for the chip kit. Or should I try to modify the arduino class? I am running ros groovy and Ubuntu 12.04 lts. thanks for any help you can give.

2013-05-04 03:50:21 -0500 commented answer I need help making/building a catkin package.

Any ideas?

2013-05-04 03:37:33 -0500 received badge  Famous Question (source)
2013-04-30 06:00:56 -0500 received badge  Famous Question (source)
2013-04-28 06:29:45 -0500 commented answer I need help making/building a catkin package.

Both pythons have yaml

2013-04-27 17:28:26 -0500 received badge  Notable Question (source)
2013-04-27 07:30:44 -0500 received badge  Popular Question (source)
2013-04-27 07:25:35 -0500 commented question I need help making/building a catkin package.

All I am importing is import serial import time import rospy from std_msgs.msg import Int32

2013-04-27 07:14:31 -0500 commented answer I need help making/building a catkin package.

walle@wallebase:~$ sudo apt-get install python-yaml Reading package lists... Done Building dependency tree
Reading state information... Done python-yaml is already the newest version. python-yaml set to manually installed. 0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.

2013-04-27 07:13:42 -0500 commented question I need help making/building a catkin package.

No I don't. just <build_depend>std_msgs</build_depend><build_depend>rospy</build_depend><run_depend>std_msgs</run_depend><run_depend>rospy</run_depend>

2013-04-26 12:54:12 -0500 asked a question I need help making/building a catkin package.

Let me start off by saying that I have read the tutorials on how to make a package and how to build it, but I seem to be too stupid to get it right because it never works. I am running ros groovy on Ubuntu 12.04lts. This is what I am trying to do, build a package that can be started by a launch file. The package is a python script that reads a serial line form a arduino and publishes it on a ros topic. The package that I want to make is all based around "". After I build the package, I try to run it with

walle@wallebase:~/catkin_ws$ rosrun encoder_feedback
Traceback (most recent call last):
  File "/home/walle/catkin_ws/src/encoder_feedback/scripts/", line 4, in <module>
    import rospy
  File "/opt/ros/groovy/lib/python2.7/dist-packages/rospy/", line 49, in <module>
    from .client import spin, myargv, init_node, \
  File "/opt/ros/groovy/lib/python2.7/dist-packages/rospy/", line 46, in <module>
    import yaml
ImportError: No module named yaml

What do I need to do to build a working package? Let me know if I need to post the .py code or include more info. Thanks for any help you can give.

2013-04-19 09:11:15 -0500 marked best answer how do I make a ros publisher run under python 3?

I made a python3 script that will read left, right encoder ticks from an arduino. I am trying to now get that same code to publish those ticks. This is what I have so far. sorry I not at all good with python.

    #!/usr/bin/env python3
import serial
import time
import rospy
from std_msgs.msg import Int16
# assign your port and speed
ser = serial.Serial('/dev/ttyUSB0', 1152000)
print("Reset Arduino")
while (1)  # WORKING PART
    #left encoder read
    ser.write(bytes('l', 'UTF-8'))
    left = ser.readline().decode('ascii').strip()
        #right encoder read
    ser.write(bytes('r', 'UTF-8'))
    right = ser.readline().decode('ascii').strip()
    right = right.rstrip('\r\n')
    #node to publish left to lwheel (std_msgs/Int16)
#not working part
    def leftticks():
        pub = rospy.Publisher('lwheel', Int16)
        while not rospy.is_shutdown():
            lstr = left

    if __name__ == '__main__':
        except rospy.ROSInterruptException:

    #node to pulish right to rwheel (std_msgs/Int16)
    def rightticks():
        pub = rospy.Publisher('rwheel', Int16)
        while not rospy.is_shutdown():
            rstr = right

    if __name__ == '__main__':
        except rospy.ROSInterruptException:

How do I get it all to work together. As you can tell I have no clue what I am doing. Thanks for any help you can give.

2013-04-19 09:11:15 -0500 received badge  Supporter (source)
2013-04-16 14:29:36 -0500 received badge  Notable Question (source)
2013-04-16 12:04:15 -0500 commented answer how do I make a ros publisher run under python 3?

rospy.exceptions.ROSSerializationException: field data must be an integer type

2013-04-16 12:03:59 -0500 commented answer how do I make a ros publisher run under python 3?

Traceback (most recent call last): File "Desktop/", line 20, in <module> lpub.publish(Int16(left)) File "/opt/ros/groovy/lib/python2.7/dist-packages/rospy/", line 801, in publish raise ROSSerializationException(str(e))