PathElemOff (STRUCT) ¶ TYPE PathElemOff : STRUCT A path element and its offset in the path. InOut: Name Type Comment elem PathElem The path element dS0 LREAL The offset of the path element in the path
Trj_Sample (STRUCT) ¶ TYPE Trj_Sample : STRUCT InOut: Name Type Comment phaseType Trj_PhaseType The phase type of this sample. dTDuration LREAL Duration of the sample in seconds. dJerkCur LREAL Constant jerk value during interval. wEnd DynState Dynamics at the end of the interval. eState ETrajectoryState State at the end of the interval. eNextStop ETrajectoryLimit The limit that is the reason for the next stop. nSegment SegmentId The segment number. This number is incremented at every stop, i.e. between buffered movements. nTrajectory TrajectoryId The trajectory number. This number is incremented whenever the synchonicity between planner and fineinterpolator is lost because of a gap in the sample queue. scheduleInfo Trj_Sample_ScheduleInfo Information about the point in time when this sample is expected to be interpolated. dbgData Trj_DebugData
Trj_SampleQueue (FB) ¶ FUNCTION_BLOCK FINAL Trj_SampleQueue A fifo queue of trajectory samples. The queue is written by one task and read by the other. The method Append is only called by the producer task, the methods GetFirst and RemoveFirst are only called by the consumer task. See PathElemQueue for a description of the interface between the planner and the FineInterpolator. Methods: AddReadCursorTimeOffset Append CopyRange Full GetDuration GetFromEnd GetFromStart GetReadPos GetSampleDuration GetWritePos Init IsEmpty NumElems RemoveAll RemoveFirst Reset SetPointer SetReadPos SetWritePos SpaceLeft Structure: AddReadCursorTimeOffset (Method) Append (Method) CopyRange (Method) Full (Method) GetDuration (Method) GetFromEnd (Method) GetFromStart (Method) GetReadPos (Method) GetSampleDuration (Method) GetWritePos (Method) Init (Method) IsEmpty (Method) NumElems (Method) RemoveAll (Method) RemoveFirst (Method) Reset (Method) SetPointer (Method) SetReadPos (Method) SetWritePos (Method) SpaceLeft (Method)
Trj_SampleQueue.GetDuration (METH) ¶ METHOD FINAL GetDuration : LREAL Returns the total duration in seconds stored in the queue. InOut: Scope Name Type Comment Return GetDuration LREAL Output durationUntilFinalTau3Phase LREAL The duration until the final tau3 phase. If the queue does not end on a tau3 phase, the total duration is returned.
Trj_SampleQueue.GetFromEnd (METH) ¶ METHOD FINAL GetFromEnd : POINTER TO Trj_Sample Returns a pointer to the n-last sample if the queue is at least n elements, otherwise 0. The pointer is valid until the next call to RemoveFirst. Only to be called safely from the writing task, or when it is made sure that no elements are removed concurrently. InOut: Scope Name Type Input n UDINT Return GetFromEnd POINTER TO Trj_Sample
Trj_SampleQueue.AddReadCursorTimeOffset (METH) ¶ METHOD FINAL AddReadCursorTimeOffset Moves the read cursor of the sample queue by a given time offset. Must be smaller or equal to the remaining duration of the first sample. InOut: Scope Name Type Input timeOffset LREAL
Trj_SampleQueue.Append (METH) ¶ METHOD FINAL Append : BOOL Tries to append a new element to the queue. Returns TRUE if the queue was not full yet, FALSE otherwise. InOut: Scope Name Type Inout Const sample Trj_Sample Input nSegment SegmentId nTrajectory TrajectoryId Return Append BOOL
Trj_SampleQueue.GetFromStart (METH) ¶ METHOD FINAL GetFromStart : POINTER TO Trj_Sample Returns a pointer to the n-th element if the queue is at least n elements, otherwise 0. The pointer is valid until the next call to RemoveFirst. Only to be called safely from the reading task, or when it is made sure that no elements are removed concurrently. InOut: Scope Name Type Input n UDINT Return GetFromStart POINTER TO Trj_Sample
Trj_SampleQueue.GetReadPos (METH) ¶ METHOD PUBLIC FINAL GetReadPos InOut: Scope Name Type Inout readCursor Trj_SampleQueue_Cursor
Trj_SampleQueue.CopyRange (METH) ¶ METHOD FINAL CopyRange : BOOL Copies at most nSamples samples from the sampleQueue to this queue, starting with the sample at iFirstSample . Only fails, if there is not enough space left in this queue. Has to be called from a task that is the producer task of this queue, but the consumer task of the input sampleQueue . InOut: Scope Name Type Inout Const sampleQueue Trj_SampleQueue Input iFirstSample UDINT nSamples UDINT Return CopyRange BOOL