AGX Dynamics 2.42.3.1
Loading...
Searching...
No Matches
agxModel::VacuumSystem Class Reference

Basic model for a vacuum system used by a SuctionGripper. More...

#include <SuctionGripper.h>

+ Inheritance diagram for agxModel::VacuumSystem:

Public Member Functions

 VacuumSystem (agx::Real desiredVacuum)
 Create a vacuum system with a constant desired vacuum level.
 
 AGXSTREAM_DECLARE_SERIALIZABLE_BASE (agxModel::VacuumSystem)
 
virtual agx::Real calculateAvailableVacuumForce (SuctionCup *cup) const
 A virtual function which is responsible to calculate the actual force a suction cup can apply to objects, given the current situation.
 
agx::Real calculateGasSpeedAtLip (const SuctionCup *cup) const
 
agx::Real calculateMaximumSuctionForce (SuctionCup *cup) const
 
agx::Real getCurrentVacuum () const
 
agx::Real getDesiredVacuum () const
 Set the desired vacuum level (0-1) for the system.
 
bool getEnablePump () const
 
agx::Real getOutsideGasDensity () const
 Get the gas density outside the vacuum system [kg / m^3].
 
agx::Real getOutsidePressure () const
 Get the pressure outside the vacuum system in Pascal[Pa].
 
void setDesiredVacuum (agx::Real vacuumLevel)
 Set the current vacuum level (0-1) for the system If set outside the valid range, the value is clamped to be inside.
 
void setEnablePump (const bool &enable)
 
void setOutsideGasDensity (agx::Real density)
 Set the gas density outside the vacuum system [kg / m^3].
 
void setOutsidePressure (agx::Real pressure)
 Set the pressure outside the vacuum system in Pascal [Pa].
 
virtual void step (agx::Real dt, const SuctionGripper *gripper)
 A virtual function for updating the vacuum system.
 
- Public Member Functions inherited from agx::Referenced
 Referenced ()
 Default constructor.
 
 Referenced (const Referenced &)
 
template<typename T >
T * as ()
 Subclass casting.
 
template<typename T >
const T * as () const
 
template<typename T >
T * asSafe ()
 Safe subclass casting, return nullptr if template type does not match.
 
template<typename T >
const T * asSafe () const
 
int getReferenceCount () const
 
template<typename T >
bool is () const
 Subclass test.
 
Referenced & operator= (const Referenced &)
 Assignment operator. Will increment the number of references to the referenced object.
 
void reference (void *ptr=nullptr) const
 Explicitly increment the reference count by one, indicating that this object has another pointer which is referencing it.
 
void unreference (void *ptr=nullptr) const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
void unreference_nodelete () const
 Decrement the reference count by one, indicating that a pointer to this object is referencing it.
 
- Public Member Functions inherited from agxStream::Serializable
virtual ~Serializable ()
 Destructor for normal C++ use but hidden from SWIG bindings.
 
virtual const char * getClassName () const
 
bool getEnableSerialization () const
 
bool getEnableUuidGeneration ()
 
agx::UInt32 getIndex () const
 This index is given at creation of this object.
 
virtual StorageAgent * getStorageAgent () const =0
 
agx::Uuid getUuid () const
 
bool isFinished () const
 
void setEnableSerialization (bool flag)
 Set to false to disable serialization of this object.
 
void setFinished ()
 Tells this class that it is restored correctly and should not be deleted during destruction of an Archive.
 
void setUuid (const agx::Uuid &uuid)
 Explicitly set a Uuid on a serializable object.
 

Static Public Member Functions

static agxStream::Serializable * create (agxStream::InputArchive &)
 
- Static Public Member Functions inherited from agx::Referenced
template<typename T >
static bool ValidateCast (const Referenced *object)
 
- Static Public Member Functions inherited from agxStream::Serializable
static void setEnableUuidGeneration (bool flag)
 Specify if there should be UUID:s generated for each new Serializable object. By default it is enabled.
 

Protected Member Functions

 VacuumSystem ()
 
virtual ~VacuumSystem ()
 
void setCurrentVacuum (agx::Real vacuum)
 Set the current vacuum for the system.
 
- Protected Member Functions inherited from agx::Referenced
virtual ~Referenced ()
 Destructor.
 
void allocateObserverVector () const
 
void deleteUsingDeleteHandler () const
 
- Protected Member Functions inherited from agxStream::Serializable
 Serializable ()
 Default constructor.
 
 Serializable (const Serializable &other)
 Copy constructor.
 
void generateUuid ()
 

Protected Attributes

agx::Real m_currentTime
 
agx::Real m_currentVacuum
 
agx::Real m_desiredVacuum
 
agx::Real m_outsideGasDensity
 
agx::Real m_outsidePressure
 
bool m_pumpEnabled
 
agx::Real m_timeOfPumpStateToggled
 
- Protected Attributes inherited from agx::Referenced
Mutex m_mutex
 
ObserverContainer m_observers
 
AtomicValue m_refCount
 

Additional Inherited Members

- Static Protected Member Functions inherited from agx::Referenced
static DeleteHandler * getDeleteHandler ()
 
static void setDeleteHandler (DeleteHandler *handler)
 Internal: Set a DeleteHandler to which deletion of all referenced counted objects will be delegated to.
 

Detailed Description

Basic model for a vacuum system used by a SuctionGripper.

virtual function calculateAvailableVacuumForce need to compute the current force a suction cup will add to the rigid bodies near the cup.

Unless anything else is said, all vacuum system are considered as one shapeless volume, with homogenius internal pressure.

Definition at line 279 of file SuctionGripper.h.

Constructor & Destructor Documentation

◆ VacuumSystem() [1/2]

agxModel::VacuumSystem::VacuumSystem ( agx::Real  desiredVacuum)

Create a vacuum system with a constant desired vacuum level.

The level must be between 0-1, where 0 is atmospheric pressure and 1 is perfect vacuum.

Parameters
desiredVacuum- the vacuum level (0-1)

This vacuum system assume all interactions will get the full vacuum force possible.

◆ ~VacuumSystem()

virtual agxModel::VacuumSystem::~VacuumSystem ( )
protectedvirtual

◆ VacuumSystem() [2/2]

agxModel::VacuumSystem::VacuumSystem ( )
protected

Member Function Documentation

◆ AGXSTREAM_DECLARE_SERIALIZABLE_BASE()

agxModel::VacuumSystem::AGXSTREAM_DECLARE_SERIALIZABLE_BASE ( agxModel::VacuumSystem  )

◆ calculateAvailableVacuumForce()

virtual agx::Real agxModel::VacuumSystem::calculateAvailableVacuumForce ( SuctionCup *  cup) const
virtual

A virtual function which is responsible to calculate the actual force a suction cup can apply to objects, given the current situation.

◆ calculateGasSpeedAtLip()

agx::Real agxModel::VacuumSystem::calculateGasSpeedAtLip ( const SuctionCup *  cup) const
Returns
estimated gas flow through the suction cup lip

◆ calculateMaximumSuctionForce()

agx::Real agxModel::VacuumSystem::calculateMaximumSuctionForce ( SuctionCup *  cup) const
Returns
the maximum force a specific cup can apply to interacted objects.
Parameters
cup- a suction cup.

◆ create()

static agxStream::Serializable * agxModel::VacuumSystem::create ( agxStream::InputArchive &  )
inlinestatic

Definition at line 363 of file SuctionGripper.h.

◆ getCurrentVacuum()

agx::Real agxModel::VacuumSystem::getCurrentVacuum ( ) const
Returns
the current vacuum level (0-1).

◆ getDesiredVacuum()

agx::Real agxModel::VacuumSystem::getDesiredVacuum ( ) const

Set the desired vacuum level (0-1) for the system.

◆ getEnablePump()

bool agxModel::VacuumSystem::getEnablePump ( ) const
Returns
true if the pump is active.

◆ getOutsideGasDensity()

agx::Real agxModel::VacuumSystem::getOutsideGasDensity ( ) const

Get the gas density outside the vacuum system [kg / m^3].

◆ getOutsidePressure()

agx::Real agxModel::VacuumSystem::getOutsidePressure ( ) const

Get the pressure outside the vacuum system in Pascal[Pa].

◆ setCurrentVacuum()

void agxModel::VacuumSystem::setCurrentVacuum ( agx::Real  vacuum)
protected

Set the current vacuum for the system.

Parameters
vacuum- the current vacuum level

◆ setDesiredVacuum()

void agxModel::VacuumSystem::setDesiredVacuum ( agx::Real  vacuumLevel)

Set the current vacuum level (0-1) for the system If set outside the valid range, the value is clamped to be inside.

Parameters
vacuumLevel- the current vacuum level

◆ setEnablePump()

void agxModel::VacuumSystem::setEnablePump ( const bool &  enable)
Parameters
enable- if true, the pump will become activated, otherwise disabled.

◆ setOutsideGasDensity()

void agxModel::VacuumSystem::setOutsideGasDensity ( agx::Real  density)

Set the gas density outside the vacuum system [kg / m^3].

◆ setOutsidePressure()

void agxModel::VacuumSystem::setOutsidePressure ( agx::Real  pressure)

Set the pressure outside the vacuum system in Pascal [Pa].

◆ step()

virtual void agxModel::VacuumSystem::step ( agx::Real  dt,
const SuctionGripper *  gripper 
)
virtual

A virtual function for updating the vacuum system.

The default model will not be affected, but this function invites to have a time dependent vacuum system.

Member Data Documentation

◆ m_currentTime

agx::Real agxModel::VacuumSystem::m_currentTime
protected

Definition at line 377 of file SuctionGripper.h.

◆ m_currentVacuum

agx::Real agxModel::VacuumSystem::m_currentVacuum
protected

Definition at line 374 of file SuctionGripper.h.

◆ m_desiredVacuum

agx::Real agxModel::VacuumSystem::m_desiredVacuum
protected

Definition at line 373 of file SuctionGripper.h.

◆ m_outsideGasDensity

agx::Real agxModel::VacuumSystem::m_outsideGasDensity
protected

Definition at line 379 of file SuctionGripper.h.

◆ m_outsidePressure

agx::Real agxModel::VacuumSystem::m_outsidePressure
protected

Definition at line 378 of file SuctionGripper.h.

◆ m_pumpEnabled

bool agxModel::VacuumSystem::m_pumpEnabled
protected

Definition at line 375 of file SuctionGripper.h.

◆ m_timeOfPumpStateToggled

agx::Real agxModel::VacuumSystem::m_timeOfPumpStateToggled
protected

Definition at line 376 of file SuctionGripper.h.


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