Skip to content
This repository has been archived by the owner on Apr 19, 2022. It is now read-only.

Add toggle to GpioPin #14

Merged
merged 1 commit into from
May 24, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions source/Gpio​Pin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,16 @@ internal void OnPinChangedInternal(GpioPinEdge edge)
callbacks?.Invoke(this, new GpioPinValueChangedEventArgs(edge));
}

/// <summary>
/// Toggles the output of the general purpose I/O (GPIO) pin if the pin is configured as an output.
/// </summary>
/// <remarks>
/// This method is exclusive of nanoFramework and it's not available in the UWP API.
/// </remarks>
[MethodImpl(MethodImplOptions.InternalCall)]
public extern void Toggle();


#region IDisposable Support

private bool _disposedValue;
Expand Down