C# Class KMotion_dotNet.KM_IO

IO class for KM_Controller Use to control a single point(bit) of IO Currently supported IO: Digital Input, Digital Output
ファイルを表示 Open project: parhansson/KMotionX

Protected Properties

Property Type Description
_Controller KM_Controller
_ID int
_IOType IO_TYPE
_Name string

Public Methods

Method Description
GetAnalogValue ( ) : int

Reads the digital expression of an analog value

GetDigitalValue ( ) : bool

Gets the current status of a point of IO

KM_IO ( KM_Controller controller, int id, string name, IO_TYPE iotype ) : System

Primary Construtor for IO object

SetAnalogValue ( int value ) : void

Sets the output level of an analog output

SetDigitalValue ( bool value ) : void

Sets the value if the IOType is Digital output Otherwise will throw an exception

Toggle ( ) : void

Toggle a Digital Output Bit

Protected Methods

Method Description
UpdateIOType ( ) : void

Uptdates the IO direction

Method Details

GetAnalogValue() public method

Reads the digital expression of an analog value
public GetAnalogValue ( ) : int
return int

GetDigitalValue() public method

Gets the current status of a point of IO
public GetDigitalValue ( ) : bool
return bool

KM_IO() public method

Primary Construtor for IO object
public KM_IO ( KM_Controller controller, int id, string name, IO_TYPE iotype ) : System
controller KM_Controller
id int Bit Number
name string Call Name
iotype IO_TYPE Sets the IO direction
return System

SetAnalogValue() public method

Sets the output level of an analog output
public SetAnalogValue ( int value ) : void
value int -2048...2047
return void

SetDigitalValue() public method

Sets the value if the IOType is Digital output Otherwise will throw an exception
public SetDigitalValue ( bool value ) : void
value bool new value for IO point
return void

Toggle() public method

Toggle a Digital Output Bit
public Toggle ( ) : void
return void

UpdateIOType() protected method

Uptdates the IO direction
protected UpdateIOType ( ) : void
return void

Property Details

_Controller protected_oe property

KM_Controller Object for used for device access
protected KM_Controller _Controller
return KM_Controller

_ID protected_oe property

Bit Number
protected int _ID
return int

_IOType protected_oe property

Direction of IO Only Digital Input and Digital Output Are currently supported
protected IO_TYPE _IOType
return IO_TYPE

_Name protected_oe property

Call Name Use to describe what the IO controls i.e. Start Button, Clamp Pneumatic, etc...
protected string _Name
return string