Arduino Motor Documentation

class arduino_motor.ArduinoMotor[source]

Sends commands to the Arduino to relay to the motor controller

begin()[source]

Start the node and spin forever

callback(msg)[source]

Updates the linear and angular velocity instance variables

The message definition can be found here: http://docs.ros.org/api/geometry_msgs/html/msg/Twist.html

Parameters:msg (geometry_msgs.msg.Twist) – The desired speed
reset_arduino()[source]
send_speed_to_motor(m1, m2)[source]
Parameters:
  • m1 (float) – The left motor’s speed in m/s
  • m2 (float) – The right motor’s speed in m/s
spin_once()[source]

Sends the speeds to the motor once and retries if it fails