C# Класс ControlSystem.Wrapper

Contains a wrapper for the C++ functions in the dll file(USBC.dll). Good idea to check USBC-documentation.pdf. Notes: Uses IntPtr arg for different types of C++ pointers. Same function names as C++ but has "Wrapped" at the end. Try to have handlers in delegates which in entire use of wrapper, so the memory for the handler doesn´t get removed by GC. \todo Add behind factory class.
Наследование: IWrapper
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
closeGripperWrapped ( ) : bool
closeManualWrapped ( ) : bool
closeWatchDigitalInputWrapped ( ) : bool
controlWrapped ( enumAxisSettings _axisSettingsGroup, bool _bControlOnOrOff ) : bool
defineVectorWrapped ( enumAxisSettings _enumGroup, string _sVectorName, short _shrtLength ) : bool
enterManualWrapped ( enumManualType _enummanMoveType ) : bool
getCurrentPosition ( ) : VecPoint

Returns the position of the robot. \warning Ignoring wrapper int return value. \warning Not sure about buffer type to use in impl.

getInstance ( ) : Wrapper

Gets the wrapper.

getJawWrapped ( short &_shrtPerc, short &_shrtWidth ) : bool
homeWrapped ( enumAxisSettings _axisSettingsGroup, DLL _funcptrHomingEventHandler ) : bool
initializationWrapped ( enumSystemModes _sysmodeMode, enumSystemTypes _systypeType, DLL _funcptrSuccess, DLL _funcptrError ) : bool

Initializes the robot. Note: Should wait for it to be done before calling other functions. \todo Refactor delegate to contain ConfigData and ErrorInfo if found necessary.

isOnlineOkWrapped ( ) : bool
moveLinearWrapped ( string _sNameOfVector, int _iIndex ) : bool

Moves the robot in a linear motion. \warning Not using pos 2 in wrapped dll function. \warning Seems to be unfunctional.

moveManualWrapped ( enumManualModeWhat _enumWhatToMove, int _lSpeed ) : bool
openGripperWrapped ( ) : bool
speedWrapped ( enumAxisSettings _bGroup, long _mSpeed ) : bool
stopWrapped ( enumAxisSettings _bWhatToStop ) : bool
teachWrapped ( SIRVector vecTheSirVector ) : bool
timeWrapped ( enumAxisSettings _bGroup, long _mTime ) : bool
watchDigitalInputWrapped ( DLL _funcptrCallbackEvent ) : bool
watchMotionWrapped ( DLL _funcptrCallbackEnd, DLL _funcptrCallbackStart ) : void

Adds functions to be called when motion starts and motion ends. Note: Ignoring return value.

Приватные методы

Метод Описание
Wrapper ( ) : System
axisSettingsToByte ( enumAxisSettings axisSettingsArg ) : byte
manualMovementToByte ( enumManualModeWhat enumArg ) : byte

Описание методов

closeGripperWrapped() публичный Метод

public closeGripperWrapped ( ) : bool
Результат bool

closeManualWrapped() публичный Метод

public closeManualWrapped ( ) : bool
Результат bool

closeWatchDigitalInputWrapped() публичный Метод

public closeWatchDigitalInputWrapped ( ) : bool
Результат bool

controlWrapped() публичный Метод

public controlWrapped ( enumAxisSettings _axisSettingsGroup, bool _bControlOnOrOff ) : bool
_axisSettingsGroup enumAxisSettings
_bControlOnOrOff bool
Результат bool

defineVectorWrapped() публичный Метод

public defineVectorWrapped ( enumAxisSettings _enumGroup, string _sVectorName, short _shrtLength ) : bool
_enumGroup enumAxisSettings
_sVectorName string
_shrtLength short
Результат bool

enterManualWrapped() публичный Метод

public enterManualWrapped ( enumManualType _enummanMoveType ) : bool
_enummanMoveType enumManualType
Результат bool

getCurrentPosition() публичный Метод

Returns the position of the robot. \warning Ignoring wrapper int return value. \warning Not sure about buffer type to use in impl.
public getCurrentPosition ( ) : VecPoint
Результат VecPoint

getInstance() публичный статический Метод

Gets the wrapper.
public static getInstance ( ) : Wrapper
Результат Wrapper

getJawWrapped() публичный Метод

public getJawWrapped ( short &_shrtPerc, short &_shrtWidth ) : bool
_shrtPerc short
_shrtWidth short
Результат bool

homeWrapped() публичный Метод

public homeWrapped ( enumAxisSettings _axisSettingsGroup, DLL _funcptrHomingEventHandler ) : bool
_axisSettingsGroup enumAxisSettings
_funcptrHomingEventHandler DLL
Результат bool

initializationWrapped() публичный Метод

Initializes the robot. Note: Should wait for it to be done before calling other functions. \todo Refactor delegate to contain ConfigData and ErrorInfo if found necessary.
public initializationWrapped ( enumSystemModes _sysmodeMode, enumSystemTypes _systypeType, DLL _funcptrSuccess, DLL _funcptrError ) : bool
_sysmodeMode enumSystemModes Mode.[Normally use online mode]
_systypeType enumSystemTypes Type of connection.[Normally use default]
_funcptrSuccess DLL Function to be called on success.
_funcptrError DLL Function to be called on error.
Результат bool

isOnlineOkWrapped() публичный Метод

public isOnlineOkWrapped ( ) : bool
Результат bool

moveLinearWrapped() публичный Метод

Moves the robot in a linear motion. \warning Not using pos 2 in wrapped dll function. \warning Seems to be unfunctional.
public moveLinearWrapped ( string _sNameOfVector, int _iIndex ) : bool
_sNameOfVector string Name of the vector in the Robot.
_iIndex int Index for point
Результат bool

moveManualWrapped() публичный Метод

public moveManualWrapped ( enumManualModeWhat _enumWhatToMove, int _lSpeed ) : bool
_enumWhatToMove enumManualModeWhat
_lSpeed int
Результат bool

openGripperWrapped() публичный Метод

public openGripperWrapped ( ) : bool
Результат bool

speedWrapped() публичный Метод

public speedWrapped ( enumAxisSettings _bGroup, long _mSpeed ) : bool
_bGroup enumAxisSettings
_mSpeed long
Результат bool

stopWrapped() публичный Метод

public stopWrapped ( enumAxisSettings _bWhatToStop ) : bool
_bWhatToStop enumAxisSettings
Результат bool

teachWrapped() публичный Метод

public teachWrapped ( SIRVector vecTheSirVector ) : bool
vecTheSirVector SIRVector
Результат bool

timeWrapped() публичный Метод

public timeWrapped ( enumAxisSettings _bGroup, long _mTime ) : bool
_bGroup enumAxisSettings
_mTime long
Результат bool

watchDigitalInputWrapped() публичный Метод

public watchDigitalInputWrapped ( DLL _funcptrCallbackEvent ) : bool
_funcptrCallbackEvent DLL
Результат bool

watchMotionWrapped() публичный Метод

Adds functions to be called when motion starts and motion ends. Note: Ignoring return value.
public watchMotionWrapped ( DLL _funcptrCallbackEnd, DLL _funcptrCallbackStart ) : void
_funcptrCallbackEnd DLL Function to be called when motion has ended.
_funcptrCallbackStart DLL Function to be called when motion has started.
Результат void