C# Class CSharpRoboticsLib.FlowControl.EdgeTrigger

Used to detect changes in a boolean state
Mostra file Open project: shockwave4488/CSharpRoboticsLib Class Usage Examples

Public Methods

Method Description
EdgeTrigger ( )

EdgeTrigger with initial value false

EdgeTrigger ( bool initial )

EdgeTrigger with the given initial value

GetFalling ( bool trigger ) : bool

Returns true if there is a falling edge, does not update the internal state

GetFallingUpdate ( bool trigger ) : bool

Returns true if there is a falling edge and updates the internal state

GetRising ( bool trigger ) : bool

Returns true if there is a rising edge, does not update the internal state

GetRisingUpdate ( bool trigger ) : bool

Returns true if there is a rising edge and updates the internal state

Update ( bool trigger ) : void

Manually update the internal state

Method Details

EdgeTrigger() public method

EdgeTrigger with initial value false
public EdgeTrigger ( )

EdgeTrigger() public method

EdgeTrigger with the given initial value
public EdgeTrigger ( bool initial )
initial bool

GetFalling() public method

Returns true if there is a falling edge, does not update the internal state
public GetFalling ( bool trigger ) : bool
trigger bool Current value of the edge triggered state
return bool

GetFallingUpdate() public method

Returns true if there is a falling edge and updates the internal state
public GetFallingUpdate ( bool trigger ) : bool
trigger bool Current value of edge triggered state
return bool

GetRising() public method

Returns true if there is a rising edge, does not update the internal state
public GetRising ( bool trigger ) : bool
trigger bool Current value of the edge triggered state
return bool

GetRisingUpdate() public method

Returns true if there is a rising edge and updates the internal state
public GetRisingUpdate ( bool trigger ) : bool
trigger bool Current value of edge triggered state
return bool

Update() public method

Manually update the internal state
public Update ( bool trigger ) : void
trigger bool Current value of the edge triggered state
return void