generator  1.2
Classes | Public Member Functions | Private Member Functions | Private Attributes | List of all members
Robot Class Reference

Instance of the class includes all the data structures and methods related to a robot. More...

#include <RoboticLine.h>

+ Collaboration diagram for Robot:

Classes

struct  mCompositeBlock
 The structure containing the activities in a block. More...
 

Public Member Functions

 Robot (uint32_t &fromActivityId, uint32_t &fromPointId, const uint32_t &numberOfInputs, const uint32_t &numberOfOutputs, const ProjectParameters &par)
 It constructs the robot according to the desired parameters. More...
 
std::vector< Activity * > activities () const
 
std::vector< RobotPowerMode * > robotModes () const
 
double lowerBoundOfCycleTime () const
 The method calculates an estimation of cycle time. More...
 
 ~Robot ()
 It frees the memory occupied by dynamically allocated activities and power saving modes.
 

Private Member Functions

 Robot (const Robot &)=delete
 
Robotoperator= (const Robot &)=delete
 
mCompositeBlock createSerialSequence (uint32_t &fromActivityId, uint32_t &fromPointId) const
 The method creates a block of a fixed sequence of operations, e.g. welding, cutting, without alternatives and updates the identification values. More...
 
mCompositeBlock createAssemblyBlock (uint32_t &fromActivityId, uint32_t &fromPointId, const uint32_t &numberOfInputs) const
 It creates a block composed of gathering required parts to a bench and their assembly/welding to one workpiece. More...
 
mCompositeBlock createDisassemblyBlock (uint32_t &fromActivityId, uint32_t &fromPointId, const uint32_t &numberOfOutputs) const
 It creates a block composed of disassembling/cutting the workpiece and taking its parts to other robots or benches. More...
 
mCompositeBlock createComplexBlockHelper (uint32_t &fromActivityId, uint32_t &fromPointId, const uint32_t &numberOfSeq, const std::string &op) const
 It is an auxiliary method wrapping complex calls to createBlockOfOperations method. More...
 
mCompositeBlock createBlockOfOperations (uint32_t &fromActivityId, uint32_t &fromPointId, const ActivityType &t1, const ActivityType &t2, const Interval< uint32_t > &numSeq, const Interval< uint32_t > &seqLength) const
 It is a core method for the decomposition of the robot work to well-defined blocks. More...
 
void connect (uint32_t &fromActivityId, mCompositeBlock &b, const std::vector< StaticActivity * > &from, const std::vector< StaticActivity * > &to, bool fullyConnected=true) const
 It interconnects two sub-blocks and adds the generated dynamic activities to the block b. More...
 
mCompositeBlock mergeBlocks (const std::vector< mCompositeBlock > &blocks) const
 It copies the activities (their pointers) in blocks to the one composite block. More...
 

Private Attributes

ProjectParameters mParameters
 Desired properties of generated instances defined in the input configuration file.
 
std::vector< Activity * > mActivities
 A collection of activities belonging to the robot.
 
std::vector< RobotPowerMode * > mRobotModes
 Available power saving modes for this robot.
 

Detailed Description

Instance of the class includes all the data structures and methods related to a robot.

The instance of this class corresponds to a robot with its operations and movements. The order of activities is incorporated in activities' successors and predecessors.

Definition at line 297 of file RoboticLine.h.

Constructor & Destructor Documentation

Robot::Robot ( uint32_t &  fromActivityId,
uint32_t &  fromPointId,
const uint32_t &  numberOfInputs,
const uint32_t &  numberOfOutputs,
const ProjectParameters par 
)

It constructs the robot according to the desired parameters.

Parameters
fromActivityIdAn initial activity numbering, i.e. unique identification.
fromPointIdAn initial unique identification of locations, i.e. robot configurations.
numberOfInputsThe number of input static activities for taking the workpiece/weldment from other robot or shared bench.
numberOfOutputsThe number of output static activities for passing the workpiece/weldment to other robot directly or using shared bench.
parParameters required for generation of the robot.

Definition at line 128 of file RoboticLine.cpp.

Member Function Documentation

void Robot::connect ( uint32_t &  fromActivityId,
mCompositeBlock b,
const std::vector< StaticActivity * > &  from,
const std::vector< StaticActivity * > &  to,
bool  fullyConnected = true 
) const
private

It interconnects two sub-blocks and adds the generated dynamic activities to the block b.

Parameters
fromActivityIdAn initial unique identification of new activities that will be updated.
bA block to which interconnecting dynamic activities ('from -> to') are added.
from,toStatic activities between which the interconnections will be established.
fullyConnectedIt influences the number of interconnections (true ~ all-to-all, false ~ any-to-any).

Definition at line 309 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::createAssemblyBlock ( uint32_t &  fromActivityId,
uint32_t &  fromPointId,
const uint32_t &  numberOfInputs 
) const
private

It creates a block composed of gathering required parts to a bench and their assembly/welding to one workpiece.

Parameters
fromActivityId,fromPointIdIt is a reference to an initial activity/location identification respectively.
numberOfInputsThe number of input parts to be assembled or welded.
Returns
An assembling/welding block with alternatives.
Note
Do not be confused by the name of the method, it can be also used for a creation of a welding block.
See also
mCompositeBlock, createComplexBlockHelper

Definition at line 215 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::createBlockOfOperations ( uint32_t &  fromActivityId,
uint32_t &  fromPointId,
const ActivityType t1,
const ActivityType t2,
const Interval< uint32_t > &  numSeq,
const Interval< uint32_t > &  seqLength 
) const
private

It is a core method for the decomposition of the robot work to well-defined blocks.

Parameters
fromActivityId,fromPointIdIt is a reference to an initial activity/location identification respectively.
t1The type of sub-block input activities, not necessarily IN.
t2The type of sub-block output activities, not necessarily OUT.
numSeqInterval of the number of independent fixed sequences of some work, e.g. welding, cutting, etc.
seqLengthInterval of possible lengths of fixed sequences, i.e. e.g. atomic welding/cutting sub-tasks.
Returns
A sub-block with alternatives, i.e. order of fixed sequences can be arbitrarily selected, used in complex blocks.
Warning
It updates fromActivityId and fromPointId values.
See also
mCompositeBlock, ActivityType

Definition at line 247 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::createComplexBlockHelper ( uint32_t &  fromActivityId,
uint32_t &  fromPointId,
const uint32_t &  numberOfSeq,
const std::string &  op 
) const
private

It is an auxiliary method wrapping complex calls to createBlockOfOperations method.

Parameters
fromActivityId,fromPointIdIt is a reference to an initial activity/location identification respectively.
numberOfSeqNumber of input or output parts.
opIt determines the type of a block, i.e. "assembly" or "disassembly".
Returns
A complex block which type is specified by op parameter.
Note
It greatly simplifies the implementation of createAssemblyBlock and createDisassemblyBlock methods.
See also
mCompositeBlock, createAssemblyBlock, createDisassemblyBlock, createBlockOfOperations

Definition at line 223 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::createDisassemblyBlock ( uint32_t &  fromActivityId,
uint32_t &  fromPointId,
const uint32_t &  numberOfOutputs 
) const
private

It creates a block composed of disassembling/cutting the workpiece and taking its parts to other robots or benches.

Parameters
fromActivityId,fromPointIdIt is a reference to an initial activity/location identification respectively.
numberOfOutputsThe number of parts to which the input workpiece is disassembled/cut.
Returns
An disassembling/cutting block with alternatives.
Note
Do not be confused by the name of the method, it can be also used for a creation of a cutting block.
See also
mCompositeBlock, createComplexBlockHelper

Definition at line 219 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::createSerialSequence ( uint32_t &  fromActivityId,
uint32_t &  fromPointId 
) const
private

The method creates a block of a fixed sequence of operations, e.g. welding, cutting, without alternatives and updates the identification values.

Parameters
fromActivityId,fromPointIdIt is a reference to an initial activity/location identification respectively.
Returns
A block of a fixed sequence of operations.
See also
mCompositeBlock, createBlockOfOperations

Definition at line 206 of file RoboticLine.cpp.

double Robot::lowerBoundOfCycleTime ( ) const

The method calculates an estimation of cycle time.

Returns
It returns the lower estimation of production cycle time for this robot.

Definition at line 179 of file RoboticLine.cpp.

Robot::mCompositeBlock Robot::mergeBlocks ( const std::vector< mCompositeBlock > &  blocks) const
private

It copies the activities (their pointers) in blocks to the one composite block.

Parameters
blocksThe blocks to be merged to one.
Returns
The composite block created from blocks.
See also
mCompositeBlock

Definition at line 320 of file RoboticLine.cpp.


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