Description

Viper rover class.

This class encapsulates the location and rotation information of all Viper parts wrt the chassis. This class should be the entry point to create a complete rover.

#include <Viper.h>

Public Member Functions

 Viper (ChSystem *system, ViperWheelType wheel_type=ViperWheelType::RealWheel)
 
ChSystemGetSystem () const
 Get the containing system.
 
void SetDriver (std::shared_ptr< ViperDriver > driver)
 Attach a driver system.
 
void SetWheelContactMaterial (std::shared_ptr< ChMaterialSurface > mat)
 Set wheel contact material.
 
void SetChassisFixed (bool fixed)
 Fix the chassis to ground.
 
void SetChassisVisualization (bool state)
 Enable/disable visualization of the rover chassis (default: true).
 
void SetWheelVisualization (bool state)
 Enable/disable visualization of rover wheels (default: true).
 
void SetSuspensionVisualization (bool state)
 Enable/disable visualization of rover suspensions (default: true).
 
void Initialize (const ChFrame<> &pos)
 Initialize the Viper rover at the specified position.
 
std::shared_ptr< ViperChassisGetChassis () const
 Get the rover chassis.
 
std::shared_ptr< ViperWheelGetWheel (ViperWheelID id) const
 Get the specified rover wheel.
 
std::shared_ptr< ViperUprightGetUpright (ViperWheelID id) const
 Get the specified rover upright.
 
std::shared_ptr< ViperUpperArmGetUpperArm (ViperWheelID id) const
 Get the specified rover upper arm.
 
std::shared_ptr< ViperLowerArmGetLowerArm (ViperWheelID id) const
 Get the specified rover lower arm.
 
std::shared_ptr< ChShaftGetDriveshaft (ViperWheelID id) const
 Get the specified rover driveshaft.
 
ChVector GetChassisPos () const
 Get chassis position.
 
ChQuaternion GetChassisRot () const
 Get chassis orientation.
 
ChVector GetChassisVel () const
 Get chassis linear velocity.
 
ChVector GetChassisAcc () const
 Get chassis linear acceleration.
 
ChVector GetWheelLinVel (ViperWheelID id) const
 Get wheel speed.
 
ChVector GetWheelAngVel (ViperWheelID id) const
 Get wheel angular velocity.
 
ChVector GetWheelContactForce (ViperWheelID id) const
 Get wheel contact force.
 
ChVector GetWheelContactTorque (ViperWheelID id) const
 Get wheel contact torque.
 
ChVector GetWheelAppliedForce (ViperWheelID id) const
 Get wheel total applied force.
 
double GetWheelTracTorque (ViperWheelID id) const
 Get wheel tractive torque - if DC control set to off.
 
ChVector GetWheelAppliedTorque (ViperWheelID id) const
 Get wheel total applied torque.
 
double GetRoverMass () const
 Get total rover mass.
 
double GetWheelMass () const
 Get total wheel mass.
 
std::shared_ptr< ChFunction_SetpointGetDriveMotorFunc (ViperWheelID id) const
 Get drive motor function. More...
 
std::shared_ptr< ChFunction_ConstGetSteerMotorFunc (ViperWheelID id) const
 Get steer motor function.
 
std::shared_ptr< ChLinkMotorRotationGetDriveMotor (ViperWheelID id) const
 Get drive motor. More...
 
std::shared_ptr< ChLinkMotorRotationGetSteerMotor (ViperWheelID id) const
 Get steer motor.
 
void Update ()
 Viper update function. More...
 

Friends

class ViperDCMotorControl
 

Member Function Documentation

◆ GetDriveMotor()

std::shared_ptr<ChLinkMotorRotation> chrono::viper::Viper::GetDriveMotor ( ViperWheelID  id) const
inline

Get drive motor.

This will return an empty pointer if the associated driver uses torque control.

◆ GetDriveMotorFunc()

std::shared_ptr<ChFunction_Setpoint> chrono::viper::Viper::GetDriveMotorFunc ( ViperWheelID  id) const
inline

Get drive motor function.

This will return an empty pointer if the associated driver uses torque control.

◆ Update()

void chrono::viper::Viper::Update ( )

Viper update function.

This function must be called before each integration step.


The documentation for this class was generated from the following files:
  • /builds/uwsbel/chrono/src/chrono_models/robot/viper/Viper.h
  • /builds/uwsbel/chrono/src/chrono_models/robot/viper/Viper.cpp