mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-29 00:23:34 +08:00
initial minimal PX4_ROS2 platform and px4_ros2_default build (#20689)
- new ROS2 platform in PX4 intended for creating configs that build and run entirely in ROS2 - PX4_CONFIG defaults to px4_ros2_default if no config specified and in a colcon workspace with ROS_VERSION=2 - currently doesn't do much other than allow you to build px4 msgs interface package
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "rclcpp/rclcpp.hpp"
|
||||
|
||||
namespace px4
|
||||
{
|
||||
|
||||
class Node : public rclcpp::Node
|
||||
{
|
||||
public:
|
||||
explicit Node(const char *node_name) :
|
||||
rclcpp::Node(node_name)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
|
||||
~Node() override = default;
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
|
||||
// int main(int argc, char *argv[])
|
||||
// {
|
||||
// rclcpp::init(argc, argv);
|
||||
// rclcpp::spin(std::make_shared<MulticopterRateControl>());
|
||||
// rclcpp::shutdown();
|
||||
// return 0;
|
||||
// }
|
||||
|
||||
|
||||
// #include "rclcpp_components/register_node_macro.hpp"
|
||||
|
||||
// // Register the component with class_loader.
|
||||
// // This acts as a sort of entry point, allowing the component to be discoverable when its library
|
||||
// // is being loaded into a running process.
|
||||
// RCLCPP_COMPONENTS_REGISTER_NODE(composition::Client)
|
||||
Reference in New Issue
Block a user