Giter Club home page Giter Club logo

raspimouse2's Introduction

Raspimouse Node

ROS 2 node for the Raspimouse robot from RT.

https://www.rt-shop.jp/index.php?main_page=product_info&products_id=3419

This is a managed-lifecycle node. The node must be configured and activated after being launched before the robot can be used. If running the node manually, after launching the node execute the following command to configure it:

$ ros2 lifecycle set raspimouse configure

If configuration succeeds, execute the following command to activate the node:

$ ros2 lifecycle set raspimouse activate

The robot can now be controlled and sensor information will be published.

The node can be deactivated using the following command:

$ ros2 lifecycle set raspimouse deactivate

This will disable publishing sensor data and stop the motors.

When the node is active, motor functionality can be tested by turning on the motors and sending a velocity command.

$ ros2 service call /motor_power std_srvs/SetBool '{data: true}'
$ ros2 topic pub -1 /cmd_vel geometry_msgs/Twist '{linear: {x: 0.05, y: 0, z: 0}, angular: {x: 0, y: 0, z: 0.05}}'

Odometry information can be checked by echoing the odom topic.

$ ros2 topic echo /odom

Similarly other sensor information can also be viewed by echoing the relevant topic.

Topics

Subscribed

  • buzzer

    Type: std_msgs/Int16

    Used to control the buzzer. Provide a value in Hertz and the buzzer will emit that tone.

  • cmd_vel

    Type: geometry_msgs/Twist

    Controls the motors. Specify the forward and turning speeds of the robot.

  • leds

    Type: raspimouse_msgs/Leds

    Turns the four LEDs on the front of the robot on and off.

Published

  • light_sensors

    Type: raspimouse_msgs/LightSensors

    Provides the raw values from the light sensors on the front of the robot.

  • odom

    Type: nav_msgs/Odometry

    Provides odometry. If hardware pulse counters are available and the use_pulse_counters parameter is set to true, the odometry is calculated from the motor control pulse counts. Otherwise, the odometry is estimated based on the velocity commands given to the robot and elapsed time.

  • switches

    Type: raspimouse_msgs/Switches

    Provides the status of each of the three push switches on the side of the robot.

Services

  • motor_power

    Type: std_srvs/SetBool

    Call this service and pass true to enable the motors. Pass false to disable the motors.

Parameters

  • odometry_scale_left_wheel

    Type: double

    Default: 1.0

    Use to adjust the odometry input from the left wheel (when using pulse counters to calculate odometry). This is used to account for slight differences in wheel diameter and wheel slip between the left and right wheels.

  • odometry_scale_right_wheel

    Type: double

    Default: 1.0

    Use to adjust the odometry input from the right wheel (when using pulse counters to calculate odometry). This is used to account for slight differences in wheel diameter and wheel slip between the left and right wheels.

  • use_light_sensors

    Type: boolean

    Default: true

    Enable or disable the light sensors on the front of the robot.

  • use_pulse_counters

    Type: boolean

    Default: false

    Use hardware pulse counters as the odometry source. When set to true, hardware pulse counters will be used only if present.

Known problems

  • Due to instabilities in either the hardware pulse counters or the kernel driver for them, it is possible for reading from the pulse counters to cause the node to freeze. If this happens regularly, disable the hardware pulse counters using the use_pulse_counters parameter and rely on estimated odometry instead.

raspimouse2's People

Contributors

gbiggs avatar youtalk avatar shotahirama avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.