INOS
CINOSMovePathPartCircle Class Reference

#include <cinosmovepathpartcircle.h>

Inheritance diagram for CINOSMovePathPartCircle:

Public Types

enum  { eOptNone = 0x00000000 , eOptClockWise = 0x00000001 }
 circle options
 
- Public Types inherited from CINOSMovePathPart
enum  {
  eTypeUnknown , eTypeLinear , eTypeLinearBay , eTypeCircle ,
  eTypeRapid
}
 

Public Member Functions

virtual uint8 GetMainAxisIndex ()
 get main axis index (relevant for abs/inc/nlg)
 
virtual uint32 GetInvolved ()
 get mask of involved axes
 
double GetRadius ()
 get circle radius
 
virtual double Prepare (uint32 auIncremental, double *apPosition)
 prepare part
 
virtual void GetPosition (double adP, double *apPosition)
 get position at P
 
virtual void GetDerivative (uint32 auLevel, double adP, double *apDerivative)
 get auLevel derivative at P
 
virtual void GetD2max (double *apD2max)
 get max 2. derivative of part
 
virtual void GetD3max (double *apD2max)
 get max 3. derivative of part
 
virtual double GetMaxVectorLength (double adError)
 get max linear error
 
virtual bool IsStartBlendingAllowed ()
 return true if start blending allowed
 
virtual bool IsEndBlendingAllowed ()
 return true if end blending allowed
 
 CINOSMovePathPartCircle (uint8 auIndex1, uint8 auIndex2, double adMid1, double adMid2, double adAngle, bool abAngleAbsolute, uint32 auOptions)
 
 CINOSMovePathPartCircle (uint8 auIndex1, uint8 auIndex2, double adEnd1, double adEnd2, double adMid1, double adMid2, uint32 auOptions)
 
 CINOSMovePathPartCircle (uint8 auIndex1, uint8 auIndex2, double adEnd1, double adEnd2, double adRadius, uint32 auOptions)
 
virtual ~CINOSMovePathPartCircle ()
 destructor
 
- Public Member Functions inherited from CINOSMovePathPart
uint8 GetType ()
 get part type
 
virtual bool IsContinuous (uint32 auLevel)
 return true if part is auLevel continuous
 
 CINOSMovePathPart ()
 constructor
 
 CINOSMovePathPart (uint8 auType)
 constructor
 
virtual ~CINOSMovePathPart ()
 destructor
 
void SetSegment (class CINOSMovePathSegment *apSegment)
 set pointer to my segment
 

Protected Member Functions

 DECLARE_DYNAMIC (CINOSMovePathPartCircle)
 
- Protected Member Functions inherited from CINOSMovePathPart
 DECLARE_DYNAMIC (CINOSMovePathPart)
 

Protected Attributes

uint8 m_uSubType
 circle type
 
uint8 m_uIndex [2]
 axis indexes
 
uint32 m_uOptions
 circle options
 
double m_dAngle
 requested angle
 
double m_dAlpha
 calculated angle
 
double m_dAlpha0
 starting angle
 
double m_dRadius
 requested radius
 
double m_dRadiusEnd
 radius at end of circle
 
double m_dMidO [2]
 circle middle point (original)
 
double m_dMidC [2]
 circle middle point (calculated)
 
double m_dEndO [2]
 circle end point (original)
 
double m_dEndC [2]
 circle end point (calculated)
 
- Protected Attributes inherited from CINOSMovePathPart
uint8 m_uType
 part type
 
class CINOSMovePathSegmentm_pSegment
 pointer to my segment
 

Friends

class CINOSMovePath
 

Detailed Description

Used to move along a circle or a part of a circle (arc). The circle/arc can be defined by different mathematical models (see the different constructors) - depending on the application, one model may fit better than the other. Finally, it doesn't matter which CTOR is chosen as the circle/arc definition is converted into the same internal representation.

Constructor & Destructor Documentation

◆ CINOSMovePathPartCircle() [1/3]

CINOSMovePathPartCircle::CINOSMovePathPartCircle ( uint8  auIndex1,
uint8  auIndex2,
double  adMid1,
double  adMid2,
double  adAngle,
bool  abAngleAbsolute,
uint32  auOptions 
)

Circle/arc defined by: The center of the circle (x/y), an angle [degree] which is either relative or absolute and the moving direction. Implicitly, the "current axes position" lies on the arc as well.

e.g. (adMid1/adMid2) = (0 [mm] / 0 [mm]), adAngle = -90 [degree], abAngleAbsolute = false (move relative from current position on the circle), abCw = true (move clock wise)

Parameters
auIndex1Index of the first axis
auIndex2Index of the second axis
adMid1Position of center of the circle of the axis defined by auIndex1 in the units of the axis. e.g. x=30 for 30mm
adMid2Position of center of the circle of the axis defined by auIndex2 in the units of the axis. e.g. y=45 for 45mm
adAngleAngle in [degree] of the arc. e.g. 90 degree: causes a quarter circle if abAngleAbsolute is false, or causes an arc from the current position to 90 degree on the circle absolute (where 0.0 degree absolute is on the "right side" of the circle see http://en.wikipedia.org/wiki/Unit_circle)
auOptionssee enum circle options

◆ CINOSMovePathPartCircle() [2/3]

CINOSMovePathPartCircle::CINOSMovePathPartCircle ( uint8  auIndex1,
uint8  auIndex2,
double  adEnd1,
double  adEnd2,
double  adMid1,
double  adMid2,
uint32  auOptions 
)

Circle/arc defined by: The end point of the circle or arc (x/y), the center of it (x/y) and the moving direction. Implicitly, the "current axes position" lies on the arc as well.

e.g. center: (adMid1/adMid2) = (0 [mm] / 0 [mm]), (adEnd1/adEnd2) = (1 [mm] / 2 [mm]), clock wise

Parameters
auIndex1Index of the first axis
auIndex2Index of the second axis
adEnd1Position of end point of the arc of the axis defined by auIndex1 in the units of the axis. e.g. x=89 for 89mm
adEnd2Position of end point of the arc of the axis defined by auIndex2 in the units of the axis. e.g. y=67 for 67mm
adMid1Position of center of the circle of the axis defined by auIndex1 in the units of the axis. e.g. x=30 for 30mm
adMid2Position of center of the circle of the axis defined by auIndex2 in the units of the axis. e.g. y=45 for 45mm
auOptionssee enum circle options

◆ CINOSMovePathPartCircle() [3/3]

CINOSMovePathPartCircle::CINOSMovePathPartCircle ( uint8  auIndex1,
uint8  auIndex2,
double  adEnd1,
double  adEnd2,
double  adRadius,
uint32  auOptions 
)

Circle/arc defined by: The end point of the circle or arc (x/y), the radius of it in the unit of the axes and the rotation direction. implicitly, the "current axes position" lies on the arc as well.

Note: Mathematically, the calculation of the circle center point yields two solutions. To have a perfectly defined circle/arc, the 'sign of the radius' (adRadius) will be taken together with the chosen moving direction (abCw) to either chose the resulting arc with "the smaller moving distance" (positive radius) or the solution resulting with an arc "with the bigger moving distance" (negative radius). Defining an arc like this is common in CNC applications.

e.g. center: (x/y) = (3 [mm] / 4 [mm]), radius: -1 [mm] (radius is negative; means: chose the center point resulting with the bigger arc), move counter clock wise

Parameters
auIndex1Index of the first axis
auIndex2Index of the second axis
adEnd1Position of end point of the arc of the axis defined by auIndex1 in the units of the axis. e.g. x=89 for 89mm
adEnd2Position of end point of the arc of the axis defined by auIndex2 in the units of the axis. e.g. y=67 for 67mm
adRadiusRadius of the circle/arc in the unit of the axes. The radius may be negative, see the notes above for an explanation of this feature
auOptionssee enum circle options

Member Function Documentation

◆ GetD2max()

virtual void CINOSMovePathPartCircle::GetD2max ( double apD2max)
virtual

get max 2. derivative of part

Implements CINOSMovePathPart.

◆ GetD3max()

virtual void CINOSMovePathPartCircle::GetD3max ( double apD2max)
virtual

get max 3. derivative of part

Implements CINOSMovePathPart.

◆ GetDerivative()

virtual void CINOSMovePathPartCircle::GetDerivative ( uint32  auLevel,
double  adP,
double apDerivative 
)
virtual

get auLevel derivative at P

Implements CINOSMovePathPart.

◆ GetInvolved()

virtual uint32 CINOSMovePathPartCircle::GetInvolved ( )
inlinevirtual

get mask of involved axes

Implements CINOSMovePathPart.

◆ GetMainAxisIndex()

virtual uint8 CINOSMovePathPartCircle::GetMainAxisIndex ( )
inlinevirtual

get main axis index (relevant for abs/inc/nlg)

Implements CINOSMovePathPart.

◆ GetMaxVectorLength()

virtual double CINOSMovePathPartCircle::GetMaxVectorLength ( double  adError)
virtual

get max linear error

Reimplemented from CINOSMovePathPart.

◆ GetPosition()

virtual void CINOSMovePathPartCircle::GetPosition ( double  adP,
double apPosition 
)
virtual

get position at P

Implements CINOSMovePathPart.

◆ IsEndBlendingAllowed()

virtual bool CINOSMovePathPartCircle::IsEndBlendingAllowed ( )
inlinevirtual

return true if end blending allowed

Reimplemented from CINOSMovePathPart.

◆ IsStartBlendingAllowed()

virtual bool CINOSMovePathPartCircle::IsStartBlendingAllowed ( )
inlinevirtual

return true if start blending allowed

Reimplemented from CINOSMovePathPart.

◆ Prepare()

virtual double CINOSMovePathPartCircle::Prepare ( uint32  auIncremental,
double apPosition 
)
virtual

prepare part

Implements CINOSMovePathPart.


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