alex-arnal / rc_templates Goto Github PK
View Code? Open in Web Editor NEWTemplates of packages based on RComponent
Templates of packages based on RComponent
It should be listening a topic all time and print a ROS_INFO every time it recives a message.
Add the subscriber to the rc_template_cpp.h in the part of the node-specific variables and functions.
Add string variable related to the topic that the subscriber will use to the rc_template_cpp.h in the part of the node-specific variables and functions.
Add the callback function that the suscriber will use to the rc_template_cpp.h in the part of the node-specific variables and functions.
Initialize the topic variable in the rosReadParams method. Set the value of the variable reading it as a ROS param.
Initialize the subscriber in the rosSetup method.
Define the callback.
Check that there is no any compilation error and that the node works as expected.
Comment all changes. This way, the template will have a ROS Subscriber that actually works, but the user will decide if he will use it, uncommenting it or not.
It should be called with an empty request. It will print a ROS_INFO every time is triggered
Add the service server to the rc_template_cpp.h in the part of the node-specific variables and functions.
Add string variable related to the name of the service to the rc_template_cpp.h in the part of the node-specific variables and functions.
Add the callback function that the service will use to the rc_template_cpp.h in the part of the node-specific variables and functions.
Initialize the service name variable in the rosReadParams method. Set the value of the variable reading it as a ROS param.
Initialize the subscriber in the rosSetup method.
Define the callback.
Check that there is no any compilation error and that the node works as expected.
Comment all changes. This way, the template will have a ROS Service Server that actually works, but the user will decide if he will use it, uncommenting it or not.
It will uncomment parts of the template based on the needs of the user (publisher, subscriber, etc.)
/* Test Publisher
CODE
*/
Once are detected, delete the comments.
Let the script get arguments to select what to uncomment.
It should publish data every time the controlLoop of the RComponent is executed and the component is in READY_STATE.
Add the publisher to the rc_template_cpp.h in the part of the node-specific variables and functions.
Add string variable related to the topic that the publisher will use to the rc_template_cpp.h in the part of the node-specific variables and functions.
Initialize the topic variable in the rosReadParams method. Set the value of the variable reading it as a ROS param.
Initialize the publisher in the rosSetup method.
Make the publisher send data in the readyState method.
Check that there is no any compilation error and that the node works as expected.
Comment all changes. This way, the template will have a ROS Publisher that actually works, but the user will decide if he will use it, uncommenting it or not.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.