ros2_rover
Loading...
Searching...
No Matches
motor_controller::VelParserNode Class Reference

#include <vel_parser_node.hpp>

Inheritance diagram for motor_controller::VelParserNode:
Collaboration diagram for motor_controller::VelParserNode:

Public Member Functions

 VelParserNode ()
 
void callback (const geometry_msgs::msg::Twist::SharedPtr msg)
 
float normalize (float value, float old_min, float old_max, float new_min, float new_max)
 
float deg_to_tick (float deg, float e_min, float e_max)
 
float radians_to_deg (float radians)
 
std::vector< float > calculate_velocity (float velocity, float radius)
 
std::vector< float > calculate_target_deg (float radius)
 
std::vector< float > calculate_target_tick (std::vector< float > target_angles)
 

Private Attributes

rclcpp::Subscription< geometry_msgs::msg::Twist >::SharedPtr subscription
 
rclcpp::Publisher< rover_msgs::msg::MotorsCommand >::SharedPtr publisher
 
int speed_factor
 
float d1
 
float d2
 
float d3
 
float d4
 
int enc_min
 
int enc_max
 
float enc_mid
 
float linear_limit
 
float angular_limit
 
float angular_factor
 

Constructor & Destructor Documentation

◆ VelParserNode()

VelParserNode::VelParserNode ( )

Member Function Documentation

◆ calculate_target_deg()

std::vector< float > VelParserNode::calculate_target_deg ( float radius)

◆ calculate_target_tick()

std::vector< float > VelParserNode::calculate_target_tick ( std::vector< float > target_angles)

◆ calculate_velocity()

std::vector< float > VelParserNode::calculate_velocity ( float velocity,
float radius )

◆ callback()

void VelParserNode::callback ( const geometry_msgs::msg::Twist::SharedPtr msg)

◆ deg_to_tick()

float VelParserNode::deg_to_tick ( float deg,
float e_min,
float e_max )

◆ normalize()

float VelParserNode::normalize ( float value,
float old_min,
float old_max,
float new_min,
float new_max )

◆ radians_to_deg()

float VelParserNode::radians_to_deg ( float radians)

Member Data Documentation

◆ angular_factor

float motor_controller::VelParserNode::angular_factor
private

◆ angular_limit

float motor_controller::VelParserNode::angular_limit
private

◆ d1

float motor_controller::VelParserNode::d1
private

◆ d2

float motor_controller::VelParserNode::d2
private

◆ d3

float motor_controller::VelParserNode::d3
private

◆ d4

float motor_controller::VelParserNode::d4
private

◆ enc_max

int motor_controller::VelParserNode::enc_max
private

◆ enc_mid

float motor_controller::VelParserNode::enc_mid
private

◆ enc_min

int motor_controller::VelParserNode::enc_min
private

◆ linear_limit

float motor_controller::VelParserNode::linear_limit
private

◆ publisher

rclcpp::Publisher<rover_msgs::msg::MotorsCommand>::SharedPtr motor_controller::VelParserNode::publisher
private

◆ speed_factor

int motor_controller::VelParserNode::speed_factor
private

◆ subscription

rclcpp::Subscription<geometry_msgs::msg::Twist>::SharedPtr motor_controller::VelParserNode::subscription
private

The documentation for this class was generated from the following files: