CSharpRoboticsLib.FlowControl.EdgeTrigger.GetRising C# (CSharp) Method

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
        public bool GetRising(bool trigger)
        {
            return (trigger && !m_feedback);
        }

Usage Example

 public void ManualUpdateRisingToFalling()
 {
     EdgeTrigger t = new EdgeTrigger();
     t.Update(false);
     Assert.IsTrue(t.GetRising(true));
     t.Update(true);
     Assert.IsTrue(t.GetFalling(false));
 }