Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions applications/lds_driver/lds_driver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

namespace lds
{
LFCDLaser::LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_service & io)
LFCDLaser::LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_context & io)
: port_(port), baud_rate_(baud_rate), shutting_down_(false), serial_(io, port_)
{
serial_.set_option(boost::asio::serial_port_base::baud_rate(baud_rate_));
Expand Down Expand Up @@ -136,7 +136,7 @@ int main(int argc, char ** argv)
uint16_t rpms;
port = "/dev/ttyUSB0";
baud_rate = 230400;
boost::asio::io_service io;
boost::asio::io_context io;

try {
lds::LFCDLaser laser(port, baud_rate, io);
Expand Down
2 changes: 1 addition & 1 deletion applications/lds_driver/lds_driver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class LFCDLaser
* @param io Boost ASIO IO Service to use when creating the serial port object
Comment thread
traversaro marked this conversation as resolved.
Outdated
*/

LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_service & io);
LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_context & io);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

To maintain consistency with the code change, it's recommended to update the Doxygen comment for the io parameter on line 54. It should refer to Boost ASIO IO Context instead of Boost ASIO IO Service.

/**
* @brief Default destructor
*/
Expand Down
2 changes: 1 addition & 1 deletion applications/lds_polar_graph/lds_polar_graph.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ private Q_SLOTS:
qreal angular_max_;
qreal radial_min_;
qreal radial_max;
boost::asio::io_service io_;
boost::asio::io_context io_;
std::string port_;
uint32_t baud_rate_;
bool shutting_down_;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class LFCDLaser
* @param baud_rate The baud rate to open the serial port at.
* @param io Boost ASIO IO Service to use when creating the serial port object
Comment thread
traversaro marked this conversation as resolved.
Outdated
*/
explicit LFCDLaser(boost::asio::io_service & io);
explicit LFCDLaser(boost::asio::io_context & io);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

For consistency, the Doxygen comment for the io parameter on line 57 should be updated to reflect the change from io_service to io_context. It currently still refers to Boost ASIO IO Service.


/**
* @brief Default destructor
Expand Down
2 changes: 1 addition & 1 deletion include/hls_lfcd_lds_driver/lfcd_laser.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class LFCDLaser
* @param baud_rate The baud rate to open the serial port at.
* @param io Boost ASIO IO Service to use when creating the serial port object
Comment thread
traversaro marked this conversation as resolved.
Outdated
*/
LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_service & io);
LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_context & io);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Please update the Doxygen comment for the io parameter on line 55 to refer to Boost ASIO IO Context. This will align the documentation with the code change from io_service to io_context.


/**
* @brief Default destructor
Expand Down
4 changes: 2 additions & 2 deletions src/hlds_laser_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

namespace hls_lfcd_lds
{
LFCDLaser::LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_service & io)
LFCDLaser::LFCDLaser(const std::string & port, uint32_t baud_rate, boost::asio::io_context & io)
: port_(port), baud_rate_(baud_rate), shutting_down_(false), serial_(io, port_)
{
serial_.set_option(boost::asio::serial_port_base::baud_rate(baud_rate_));
Expand Down Expand Up @@ -127,7 +127,7 @@ int main(int argc, char ** argv)

auto node = rclcpp::Node::make_shared("hlds_laser_publisher");
rclcpp::Publisher<sensor_msgs::msg::LaserScan>::SharedPtr laser_pub;
boost::asio::io_service io;
boost::asio::io_context io;

std::string port;
std::string frame_id;
Expand Down
4 changes: 2 additions & 2 deletions src/hlds_laser_segment_publisher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

namespace hls_lfcd_lds
{
LFCDLaser::LFCDLaser(boost::asio::io_service & io)
LFCDLaser::LFCDLaser(boost::asio::io_context & io)
: serial_(io),
shutting_down_(false)
{
Expand Down Expand Up @@ -132,7 +132,7 @@ int main(int argc, char * argv[])
{
ros::init(argc, argv, "hlds_laser_segment_publisher");

boost::asio::io_service io;
boost::asio::io_context io;
hls_lfcd_lds::LFCDLaser laser(io);

while (ros::ok()) {
Expand Down
Loading