Initial version of Windows.Devices.Gpio (#15)
- Code provided by Christophe Gerbier (@MikroBusNet) Signed-off-by: José Simões <jose.simoes@eclo.solutions>
This commit is contained in:
Родитель
51581f0a7b
Коммит
e9e5583b5e
|
@ -0,0 +1,19 @@
|
|||
using System.Reflection;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Windows.Devices.Gpio")]
|
||||
[assembly: AssemblyCompany("nanoFrameowrk Contributors")]
|
||||
[assembly: AssemblyProduct("Windows.Devices.Gpio")]
|
||||
[assembly: AssemblyCopyright("Copyright © nanoFrameowrk Contributors 2017")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
|
@ -0,0 +1,26 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the polarity of changes that are relevant to the associated action.
|
||||
/// </summary>
|
||||
public enum GpioChangePolarity
|
||||
{
|
||||
/// <summary>
|
||||
/// Transitions from both low to high and high to low should trigger the associated action.
|
||||
/// </summary>
|
||||
Both,
|
||||
/// <summary>
|
||||
/// Transitions from high to low should trigger the associated action.
|
||||
/// </summary>
|
||||
Falling,
|
||||
/// <summary>
|
||||
/// Transitions from low to high should trigger the associated action.
|
||||
/// </summary>
|
||||
Rising
|
||||
}
|
||||
}
|
|
@ -0,0 +1,38 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the possible results of opening a pin with the <see cref="GpioPin.TryOpenPin"/> method.
|
||||
/// </summary>
|
||||
public enum GpioOpenStatus
|
||||
{
|
||||
/// <summary>
|
||||
/// The pin is currently opened for a different function, such as I2C, SPI, or UART. Ensure the pin is not in use by another function.
|
||||
/// </summary>
|
||||
MuxingConflict,
|
||||
/// <summary>
|
||||
/// The GPIO pin was successfully opened.
|
||||
/// </summary>
|
||||
PinOpened,
|
||||
/// <summary>
|
||||
/// The pin is reserved by the system and is not available to apps that run in user mode.
|
||||
/// </summary>
|
||||
PinUnavailable,
|
||||
/// <summary>
|
||||
/// <para>The pin is currently open in an incompatible sharing mode. For example:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>The pin is already open in GpioSharingMode.Exclusive mode.</term></item>
|
||||
/// <item><term>The pin is already open in GpioSharingMode.SharedReadOnly mode when you request to open it in GpioSharingMode.Exclusive mode.</term></item>
|
||||
/// </list>
|
||||
/// </summary>
|
||||
SharingViolation,
|
||||
/// <summary>
|
||||
/// The pin could not be opened.
|
||||
/// </summary>
|
||||
UnknownError
|
||||
}
|
||||
}
|
|
@ -0,0 +1,46 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes whether a general-purpose I/O (GPIO) pin is configured as an input or an output, and how values are driven onto the pin
|
||||
/// </summary>
|
||||
public enum GpioPinDriveMode
|
||||
{
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in floating mode, with high impedance.
|
||||
/// </summary>
|
||||
Input,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin as high impedance with a pull-down resistor to ground.
|
||||
/// </summary>
|
||||
InputPullDown,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin as high impedance with a pull-up resistor to the voltage charge connection (VCC).
|
||||
/// </summary>
|
||||
InputPullUp,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in strong drive mode, with low impedance.
|
||||
/// </summary>
|
||||
Output,
|
||||
/// <summary>
|
||||
/// Configures the GPIO in open drain mode.
|
||||
/// </summary>
|
||||
OutputOpenDrain,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open drain mode with resistive pull-up mode.
|
||||
/// </summary>
|
||||
OutputOpenDrainPullUp,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open collector mode.
|
||||
/// </summary>
|
||||
OutputOpenSource,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open collector mode with resistive pull-down mode.
|
||||
/// </summary>
|
||||
OutputOpenSourcePullDown
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the possible types of change that can occur to the value of the general-purpose I/O (GPIO) pin for the GpioPin.ValueChanged event.
|
||||
/// </summary>
|
||||
public enum GpioPinEdge
|
||||
{
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin changed from high to low.
|
||||
/// </summary>
|
||||
FallingEdge,
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin changed from low to high.
|
||||
/// </summary>
|
||||
RisingEdge
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the possible values for a general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
public enum GpioPinValue
|
||||
{
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin is high.
|
||||
/// </summary>
|
||||
High,
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin is low.
|
||||
/// </summary>
|
||||
Low
|
||||
}
|
||||
}
|
|
@ -0,0 +1,30 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the modes in which you can open a general-purpose I/O (GPIO) pin.
|
||||
/// <para>These modes determine whether other connections to the GPIO pin can be opened while you have the pin open.</para>
|
||||
/// </summary>
|
||||
public enum GpioSharingMode
|
||||
{
|
||||
/// <summary>
|
||||
/// Opens the GPIO pin exclusively, so that no other connection to the pin can be opened.
|
||||
/// </summary>
|
||||
Exclusive,
|
||||
/// <summary>
|
||||
/// <para>Opens the GPIO pin as shared, so that other connections in SharedReadOnly mode to the pin can be opened.</para>
|
||||
/// <para>You can only perform operations that do not change the state of the GPIO pin in shared mode. Operations that you can perform on the GPIO pin in shared mode include:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>Calling the GpioPin.Read method.</term></item>
|
||||
/// <item><term>Calling the GpioPin.GetDriveMode method.</term></item>
|
||||
/// <item><term>Getting the values of properties, such as GpioPin.PinNumber and GpioPin.DebounceTimeout.</term></item>
|
||||
/// <item><term>Registering an event handler for the GpioPin.ValueChanged event.</term></item>
|
||||
/// </list>
|
||||
/// </summary>
|
||||
SharedReadOnly
|
||||
}
|
||||
}
|
|
@ -0,0 +1,28 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a near-simultaneous sampling of the number of times a pin has changed value, and the time at which this count was sampled.
|
||||
/// This structure can be used to determine the number of pin value changes over a period of time.
|
||||
/// </summary>
|
||||
public struct GpioChangeCount
|
||||
{
|
||||
/// <summary>
|
||||
/// The number of times the transition of polarity specified by <see cref="GpioChangeCounter.Polarity" /> occured on the pin.
|
||||
/// </summary>
|
||||
public ulong Count;
|
||||
|
||||
/// <summary>
|
||||
/// The time at which this count was sampled. The time is sampled close to (but not simultaneously with) the count.
|
||||
/// This timestamp can be used to determine the elapsed time between two GpioChangeCount records.
|
||||
/// It does not correspond to any absolute or system time.
|
||||
/// </summary>
|
||||
public TimeSpan RelativeTime;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,97 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Counts changes of a specified polarity on a general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>When the pin is an input, interrupts are used to detect pin changes. Interrupts for the pin are enabled for the specified polarity, and the count is incremented when an interrupt occurs.</para>
|
||||
/// <para>When the pin is an output, the count will increment whenever the specified transition occurs on the pin.For example, if the pin is configured as an output and counting is enabled for rising edges, writing a 0 and then a 1 will cause the count to be incremented.</para></remarks>
|
||||
public sealed class GpioChangeCounter
|
||||
{
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="GpioChangeCounter"/> class associated with the specified pin.
|
||||
/// Only a single <see cref="GpioChangeCounter"/> may be associated with a pin at any given time.
|
||||
/// </summary>
|
||||
/// <param name="pin">The pin on which to count changes.
|
||||
/// This pin must have been opened in Exclusive mode, and cannot be associated with another GpioChangeCounter.
|
||||
/// </param>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <para>E_POINTER - The pin passed in is null.</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_SHARING_VIOLATION) - The pin is already associated with a change counter.That change counter must be disposed before the pin can be associated with a new change counter.</para>
|
||||
/// <para>E_ACCESSDENIED - The pin is not opened in Exclusive mode.</para></remarks>
|
||||
public GpioChangeCounter(GpioPin pin)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets whether pin change counting is currently active.
|
||||
/// </summary>
|
||||
/// <returns><c>TRUE</c> if this pin change counting is active and <c>FALSE</c> otherwise.</returns>
|
||||
public bool IsStarted { get; }
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the polarity of transitions that will be counted. The polarity may only be changed when pin counting is not started.
|
||||
/// </summary>
|
||||
/// <remarks><para>The default polarity value is Falling. See <see cref="GpioChangePolarity"></see> for more information on polarity values. Counting a single edge can be considerably more efficient than counting both edges.</para>
|
||||
/// <para>The following exceptions can be thrown when setting the polarity:</para>
|
||||
/// <para>E_INVALIDARG - value is not a valid GpioChangePolarity value.</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change counting is currently active.Polarity can only be set before calling Start() or after calling Stop().</para>
|
||||
/// </remarks>
|
||||
public GpioChangePolarity Polarity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Reads the current count of polarity changes. Before counting has been started, this will return 0.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="GpioChangeCount" /> structure containing a count and an associated timestamp.</returns>
|
||||
/// <remarks><para>The following exception can be thrown by this method:</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change counter or the associated pin has been disposed.</para></remarks>
|
||||
public GpioChangeCount Read()
|
||||
{
|
||||
return new GpioChangeCount();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Resets the count to 0 and returns the previous count.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="GpioChangeCount" /> structure containing a count and an associated timestamp.</returns>
|
||||
/// <remarks><para>The following exception can be thrown by this method:</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change counter or the associated pin has been disposed.</para></remarks>
|
||||
public GpioChangeCount Reset()
|
||||
{
|
||||
return new GpioChangeCount();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Starts counting changes in pin polarity. This method may only be called when change counting is not already active.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>Calling Start() may enable or reconfigure interrupts for the pin.</para>
|
||||
/// <para>The following exceptions can be thrown by this method:</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change counting has already been started.</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change counter or the associated pin has been disposed.</para></remarks>
|
||||
public void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stop counting changes in pin polarity. This method may only be called when change counting is currently active.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// <para>Calling Stop() may enable or reconfigure interrupts for the pin.</para>
|
||||
/// <para>The following exceptions can be thrown by this method:</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change counting has already been started.</para>
|
||||
/// <para>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change counter or the associated pin has been disposed.</para></remarks>
|
||||
public void Stop()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,206 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a shared circular buffer between kernel mode and user mode into which high-resolution timestamps are placed when a general-purpose I/O (GPIO) pin changes value.
|
||||
/// <remarks><para>Kernel mode places a timestamp into the buffer when a pin changes value, and user mode removes items from the buffer.
|
||||
/// An overflow occurs when there is no longer sufficient room in the buffer to place additional timestamps.
|
||||
/// Upon overflow, further events are not recorded, and the IsOverflowed property will return true.</para>
|
||||
/// <para>This class is not thread-safe.Calling functions of this class concurrently from multiple threads will have unpredictable results.</para></remarks>
|
||||
/// </summary>
|
||||
public sealed class GpioChangeReader
|
||||
{
|
||||
/// <summary>
|
||||
/// Creates a new GpioChangeReader associated with the specified pin. Only a single GpioChangeReader may be associated with a pin at any given time.
|
||||
/// </summary>
|
||||
/// <param name="pin">The pin on which to read changes. The pin must have been opened in Exclusive mode, and cannot be associated with another change reader.</param>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_POINTER - The pin passed in is null.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_SHARING_VIOLATION) - The pin is already associated with a change reader.That change reader must be disposed before the pin can be associated with a new change reader.</term></item>
|
||||
/// <item><term>E_ACCESSDENIED - The pin is not opened in Exclusive mode.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioChangeReader(GpioPin pin)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Creates a new GpioChangeReader associated with the specified pin. Only a single GpioChangeReader may be associated with a pin at any given time.
|
||||
/// </summary>
|
||||
/// <param name="pin">The pin on which to read changes. The pin must have been opened in Exclusive mode, and cannot be associated with another change reader.</param>
|
||||
/// <param name="minCapacity">The minimum number of change records that the reader must be able to hold.</param>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_POINTER - The pin passed in is null.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_SHARING_VIOLATION) - The pin is already associated with a change reader.That change reader must be disposed before the pin can be associated with a new change reader.</term></item>
|
||||
/// <item><term>E_ACCESSDENIED - The pin is not opened in Exclusive mode.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioChangeReader(GpioPin pin, Int32 minCapacity)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the maximum number of change records that the GpioChangeReader can store at one time.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The maximum number of change records.
|
||||
/// </value>
|
||||
/// <remarks>When this maximum number of records is met, further changes will not be recorded and the IsOverflowed property will return true.</remarks>
|
||||
public int Capacity { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets whether there are currently zero change records in the reader.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// Returns true if there are zero change items in the reader, and false otherwise
|
||||
/// </value>
|
||||
public bool IsEmpty { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets whether an attempt to place a change record into the reader's buffer has failed due to the buffer being full.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// Returns true if an attempt at placement has been unsuccessful, and false otherwise.
|
||||
/// </value>
|
||||
/// <remarks>Removing an item from the buffer will cause IsOverflowed to reset to false.</remarks>
|
||||
public bool IsOverflowed { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets whether pin change recording is currently active.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// Returns true if pin changes are currently being recorded, and false otherwise.
|
||||
/// </value>
|
||||
public bool IsStarted { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the number of records currently in the change reader.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The current number of change records.
|
||||
/// </value>
|
||||
public int Length { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the polarity of transitions that will be recorded. The polarity may only be changed when pin change recording is not started.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// Rising or Falling. The default polarity value is Falling.
|
||||
/// </value>
|
||||
/// <remarks>
|
||||
/// <para>Listening to a single edge (Falling or Rising) can be considerably more efficient than listening to both edges.</para>
|
||||
/// <para>The following exceptions can be thrown when setting the polarity:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_INVALIDARG - value is not a valid GpioChangePolarity value.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change recording is currently active.Polarity can only be set before calling Start() or after calling Stop().</term></item>
|
||||
/// </list>
|
||||
/// </para>
|
||||
/// </remarks>
|
||||
public GpioChangePolarity Polarity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Discards all change records from the reader's buffer.
|
||||
/// </summary>
|
||||
/// <remarks>This will also reset an active overflow condition, causing the IsOverflowed property to return false.</remarks>
|
||||
public void Clear()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Removes and returns all items current in the reader's buffer.
|
||||
/// </summary>
|
||||
/// <returns>The returned vector enables random access to all the change records removed from the buffer.</returns>
|
||||
/// <remarks>This will also reset an active overflow condition, causing the IsOverflowed property to return false.</remarks>
|
||||
public GpioChangeRecord[] GetAllItems()
|
||||
{
|
||||
return new GpioChangeRecord[1];
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Retrieves and removes the earliest inserted change record from the reader's buffer.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="GpioChangeRecord"/> structure containing the timestamp and polarity (rising or falling) of the change.</returns>
|
||||
/// <remarks>This will also reset an active overflow condition, causing the IsOverflowed property to return false.
|
||||
/// <para>The following exception can be thrown by this method:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_NO_MORE_ITEMS) - the reader's buffer is empty.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioChangeRecord GetNextItem()
|
||||
{
|
||||
return new GpioChangeRecord();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Retrieves the earlier inserted change record from the reader's buffer, without removing it.
|
||||
/// </summary>
|
||||
/// <returns>A <see cref="GpioChangeRecord"/> structure containing the timestamp and polarity (rising or falling) of the change.</returns>
|
||||
/// <remarks>This will also reset an active overflow condition, causing the IsOverflowed property to return false.
|
||||
/// <para>The following exception can be thrown by this method:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_NO_MORE_ITEMS) - the reader's buffer is empty.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioChangeRecord PeekNextItem()
|
||||
{
|
||||
return new GpioChangeRecord();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Starts recording changes in pin polarity. This method may only be called when change recording is not already active.
|
||||
/// </summary>
|
||||
/// <remarks>Calling Start() may enable or reconfigure interrupts for the pin.
|
||||
/// <para>The following exceptions can be thrown by this method:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change reading is not currently active.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change reader or the associated pin has been disposed.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Stop recording changes in pin polarity. This method may only be called when change recording is currently active.
|
||||
/// </summary>
|
||||
/// <remarks>Calling Stop() may enable or reconfigure interrupts for the pin.
|
||||
/// <para>The following exceptions can be thrown by this method:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_BAD_COMMAND) - change reading is not currently active.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - the change reader or the associated pin has been disposed.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public void Stop()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Waits for the buffer to fill with at least count number of items, at which point the async action will complete. This action is cancelable.
|
||||
/// </summary>
|
||||
/// <param name="count">The number of items with which the buffer must fill before the async operation completes.</param>
|
||||
/// <remarks>If the pin or change reader is closed while a wait is in progress, the async operation will be cancelled.
|
||||
/// <para>The following exceptions can be thrown by this method:</para>
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_INVALIDARG - count is 0, or count is greater than the buffer's capacity.</term></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_INVALID_HANDLE) - The change reader was disposed of the associated pin was closed.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public void WaitForItems(Int32 count)
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Stores a relative timestap of a general-purpose I/O (GPIO) pin value change, and whether the pin transitioned from low to high or from high to low.
|
||||
/// </summary>
|
||||
public struct GpioChangeRecord
|
||||
{
|
||||
/// <summary>
|
||||
/// A <see cref="GpioPinEdge"/> object corresponding to the transition type.
|
||||
/// </summary>
|
||||
public GpioPinEdge Edge;
|
||||
|
||||
/// <summary>
|
||||
/// A relative timestamp that can be used to determine the difference in time between two change records. This timestamp does not correspond to any absolute or system time.
|
||||
/// </summary>
|
||||
public TimeSpan RelativeTime;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,132 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the default general-purpose I/O (GPIO) controller for the system.
|
||||
/// </summary>
|
||||
/// <remarks>To get a <see cref="GpioController"/> object, use the <see cref="GpioController.GetDefault"/> method.</remarks>
|
||||
public sealed class GpioController
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the number of pins on the general-purpose I/O (GPIO) controller.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The number of pins on the GPIO controller. Some pins may not be available in user mode.
|
||||
/// For information about how the pin numbers correspond to physical pins, see the documentation for your circuit board.
|
||||
/// </value>
|
||||
public int PinCount { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets all the controllers that are connected to the system asynchronously.
|
||||
/// </summary>
|
||||
/// <param name="provider">The GPIO provider for the controllers on the system.</param>
|
||||
/// <returns>When the method completes successfully, it returns a list of values that represent the controllers available on the system.</returns>
|
||||
public static GpioController[] GetControllers(IGpioProvider provider)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the default general-purpose I/O (GPIO) controller for the system.
|
||||
/// </summary>
|
||||
/// <returns>The default GPIO controller for the system, or null if the system has no GPIO controller.</returns>
|
||||
public static GpioController GetDefault()
|
||||
{
|
||||
return new GpioController();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Opens a connection to the specified general-purpose I/O (GPIO) pin in exclusive mode.
|
||||
/// </summary>
|
||||
/// <param name="pinNumber">The pin number of the GPIO pin that you want to open. The pin number must be
|
||||
/// <list type="bullet">
|
||||
/// <item><term>in range</term></item>
|
||||
/// <item><term>available to usermode applications</term></item>
|
||||
/// </list>
|
||||
/// <para>Pin numbers start at 0, and increase to the maximum pin number, which is one less than the value returned by GpioController.PinCount.</para>
|
||||
/// <para>Which pins are available to usermode depends on the circuit board on which the code is running.For information about how pin numbers correspond to physical pins, see the documentation for your circuit board.</para>
|
||||
/// </param>
|
||||
/// <returns>The opened GPIO pin.</returns>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_INVALIDARG (0x80070057)</term>
|
||||
/// <description>An invalid parameter was specified. This error will be returned if the pin number is out of range.
|
||||
/// Pin numbers start at 0 and increase to the maximum pin number, which is one less than the value returned by <see cref="GpioController.PinCount"/>.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_NOT_FOUND) (0x80070490)</term>
|
||||
/// <description>The pin is not available to usermode applications; it is reserved by the system. See the documentation for your circuit board to find out which pins are available to usermode applications.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_SHARING_VIOLATION) (0x80070020)</term>
|
||||
/// <description>The pin is currently open in an incompatible sharing mode. For example:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>The pin is already open in GpioSharingMode.Exclusive mode.</term></item>
|
||||
/// <item><term>The pin is already open in GpioSharingMode.SharedReadOnly mode when you request to open it in GpioSharingMode.Exclusive mode. </term></item>
|
||||
/// </list></description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_GPIO_INCOMPATIBLE_CONNECT_MODE) (0x80073bde)</term>
|
||||
/// <description>The pin is currently muxed to a different function; for example I2C, SPI, or UART. Ensure the pin is not in use by another function.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_GEN_FAILURE) (0x8007001f)</term>
|
||||
/// <description>The GPIO driver returned an error. Ensure that the GPIO driver is running and configured correctly.</description></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioPin OpenPin(Int32 pinNumber)
|
||||
{
|
||||
return new GpioPin();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Opens the specified general-purpose I/O (GPIO) pin in the specified mode.
|
||||
/// </summary>
|
||||
/// <param name="pinNumber">The pin number of the GPIO pin that you want to open. The pin number must be
|
||||
/// <list type="bullet">
|
||||
/// <item><term>in range</term></item>
|
||||
/// <item><term>available to usermode applications</term></item>
|
||||
/// </list>
|
||||
/// <para>Pin numbers start at 0, and increase to the maximum pin number, which is one less than the value returned by GpioController.PinCount.</para>
|
||||
/// <para>Which pins are available to usermode depends on the circuit board on which the code is running.For information about how pin numbers correspond to physical pins, see the documentation for your circuit board.</para>
|
||||
/// </param>
|
||||
/// <param name="sharingMode">The mode in which you want to open the GPIO pin, which determines whether other connections to the pin can be opened while you have the pin open.</param>
|
||||
/// <returns>The opened GPIO pin.</returns>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_INVALIDARG (0x80070057)</term>
|
||||
/// <description>An invalid parameter was specified. This error will be returned if the pin number is out of range.
|
||||
/// Pin numbers start at 0 and increase to the maximum pin number, which is one less than the value returned by <see cref="GpioController.PinCount"/>.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_NOT_FOUND) (0x80070490)</term>
|
||||
/// <description>The pin is not available to usermode applications; it is reserved by the system. See the documentation for your circuit board to find out which pins are available to usermode applications.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_SHARING_VIOLATION) (0x80070020)</term>
|
||||
/// <description>The pin is currently open in an incompatible sharing mode. For example:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>The pin is already open in GpioSharingMode.Exclusive mode.</term></item>
|
||||
/// <item><term>The pin is already open in GpioSharingMode.SharedReadOnly mode when you request to open it in GpioSharingMode.Exclusive mode. </term></item>
|
||||
/// </list></description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_GPIO_INCOMPATIBLE_CONNECT_MODE) (0x80073bde)</term>
|
||||
/// <description>The pin is currently muxed to a different function; for example I2C, SPI, or UART. Ensure the pin is not in use by another function.</description></item>
|
||||
/// <item><term>HRESULT_FROM_WIN32(ERROR_GEN_FAILURE) (0x8007001f)</term>
|
||||
/// <description>The GPIO driver returned an error. Ensure that the GPIO driver is running and configured correctly.</description></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public GpioPin OpenPin(Int32 pinNumber, GpioSharingMode sharingMode)
|
||||
{
|
||||
return new GpioPin();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Opens the specified general-purpose I/O (GPIO) pin in the specified mode, and gets a status value that you can use to handle a failure to open the pin programmatically.
|
||||
/// </summary>
|
||||
/// <param name="pinNumber">The pin number of the GPIO pin that you want to open. Some pins may not be available in user mode. For information about how the pin numbers correspond to physical pins, see the documentation for your circuit board.</param>
|
||||
/// <param name="sharingMode">The mode in which you want to open the GPIO pin, which determines whether other connections to the pin can be opened while you have the pin open.</param>
|
||||
/// <param name="pin">The opened GPIO pin if the return value is true; otherwise null.</param>
|
||||
/// <param name="openStatus">An enumeration value that indicates either that the attempt to open the GPIO pin succeeded, or the reason that the attempt to open the GPIO pin failed.</param>
|
||||
/// <returns>True if the method successfully opened the pin; otherwise false.
|
||||
/// <para>If the method returns true, the pin parameter receives an instance of a GpioPin, and the openStatus parameter receives GpioOpenStatus.PinOpened.If the method returns false, the pin parameter is null and the openStatus parameter receives the reason that the operation failed.</para></returns>
|
||||
public bool TryOpenPin(Int32 pinNumber, GpioSharingMode sharingMode, GpioPin pin, GpioOpenStatus openStatus)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
|
@ -0,0 +1,165 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents a general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
public sealed class GpioPin : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets or sets the debounce timeout for the general-purpose I/O (GPIO) pin, which is an interval during which changes to the value of the pin are filtered out and do not generate ValueChanged events.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The debounce timeout for the GPIO pin, which is an interval during which changes to the value of the pin are filtered out and do not generate ValueChanged events.
|
||||
/// If the length of this interval is 0, all changes to the value of the pin generate ValueChanged events.
|
||||
/// </value>
|
||||
extern public TimeSpan DebounceTimeout {
|
||||
[MethodImplAttribute(MethodImplOptions.InternalCall)]
|
||||
get;
|
||||
|
||||
[MethodImplAttribute(MethodImplOptions.InternalCall)]
|
||||
set;
|
||||
}
|
||||
|
||||
private int _pinNumber = 1;
|
||||
/// <summary>
|
||||
/// Gets the pin number of the general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The pin number of the GPIO pin.
|
||||
/// </value>
|
||||
public int PinNumber {
|
||||
get
|
||||
{
|
||||
// check if pin has been disposed
|
||||
if (!disposedValue)
|
||||
{
|
||||
return _pinNumber;
|
||||
}
|
||||
|
||||
throw new ObjectDisposedException();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the sharing mode in which the general-purpose I/O (GPIO) pin is open.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The sharing mode in which the GPIO pin is open.
|
||||
/// </value>
|
||||
public GpioSharingMode SharingMode { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the current drive mode for the general-purpose I/O (GPIO) pin. The drive mode specifies whether the pin is configured as an input or an output, and determines how values are driven onto the pin.
|
||||
/// </summary>
|
||||
/// <returns>An enumeration value that indicates the current drive mode for the GPIO pin.
|
||||
/// The drive mode specifies whether the pin is configured as an input or an output, and determines how values are driven onto the pin.</returns>
|
||||
public GpioPinDriveMode GetDriveMode()
|
||||
{
|
||||
return new GpioPinDriveMode();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets whether the general-purpose I/O (GPIO) pin supports the specified drive mode.
|
||||
/// </summary>
|
||||
/// <param name="driveMode">The drive mode that you want to check for support.</param>
|
||||
/// <returns>
|
||||
/// True if the GPIO pin supports the drive mode that driveMode specifies; otherwise false.
|
||||
/// If you specify a drive mode for which this method returns false when you call <see cref="SetDriveMode"/>, <see cref="SetDriveMode"/> generates an exception.
|
||||
/// </returns>
|
||||
public bool IsDriveModeSupported(GpioPinDriveMode driveMode)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Reads the current value of the general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
/// <returns>The current value of the GPIO pin. If the pin is configured as an output, this value is the last value written to the pin.</returns>
|
||||
public GpioPinValue Read()
|
||||
{
|
||||
return new GpioPinValue();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sets the drive mode of the general-purpose I/O (GPIO) pin.
|
||||
/// The drive mode specifies whether the pin is configured as an input or an output, and determines how values are driven onto the pin.
|
||||
/// </summary>
|
||||
/// <param name="value">An enumeration value that specifies drive mode to use for the GPIO pin.
|
||||
/// The drive mode specifies whether the pin is configured as an input or an output, and determines how values are driven onto the pin.</param>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_INVALIDARG : The GPIO pin does not support the specified drive mode.</term></item>
|
||||
/// <item><term>E_ACCESSDENIED : The pin is open in shared read-only mode.Close the pin and reopen it in exclusive mode to change the drive mode of the pin.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public void SetDriveMode(GpioPinDriveMode value)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Drives the specified value onto the general purpose I/O (GPIO) pin according to the current drive mode for the pin
|
||||
/// if the pin is configured as an output, or updates the latched output value for the pin if the pin is configured as an input.
|
||||
/// </summary>
|
||||
/// <param name="value">The enumeration value to write to the GPIO pin.
|
||||
/// <para>If the GPIO pin is configured as an output, the method drives the specified value onto the pin according to the current drive mode for the pin.</para>
|
||||
/// <para>If the GPIO pin is configured as an input, the method updates the latched output value for the pin. The latched output value is driven onto the pin when the configuration for the pin changes to output.</para>
|
||||
/// </param>
|
||||
/// <remarks>The following exceptions can be thrown by this method:
|
||||
/// <list type="bullet">
|
||||
/// <item><term>E_ACCESSDENIED : The GPIO pin is open in shared read-only mode. To write to the pin, close the pin and reopen the pin in exclusive mode.</term></item>
|
||||
/// </list>
|
||||
/// </remarks>
|
||||
public void Write(GpioPinValue value)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
#region IDisposable Support
|
||||
|
||||
private bool disposedValue = false; // To detect redundant calls
|
||||
|
||||
void Dispose(bool disposing)
|
||||
{
|
||||
if (!disposedValue)
|
||||
{
|
||||
if (disposing)
|
||||
{
|
||||
DisposeNative();
|
||||
}
|
||||
|
||||
// TODO: free unmanaged resources (unmanaged objects) and override a finalizer below.
|
||||
// TODO: set large fields to null.
|
||||
|
||||
disposedValue = true;
|
||||
}
|
||||
}
|
||||
|
||||
[MethodImplAttribute(MethodImplOptions.InternalCall)]
|
||||
extern private void DisposeNative();
|
||||
|
||||
~GpioPin()
|
||||
{
|
||||
// Do not change this code. Put cleanup code in Dispose(bool disposing) above.
|
||||
Dispose(false);
|
||||
}
|
||||
|
||||
// This code added to correctly implement the disposable pattern.
|
||||
void IDisposable.Dispose()
|
||||
{
|
||||
// Do not change this code. Put cleanup code in Dispose(bool disposing) above.
|
||||
Dispose(true);
|
||||
GC.SuppressFinalize(this);
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
|
@ -0,0 +1,66 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|AnyCPU">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>AnyCPU</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|AnyCPU">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>AnyCPU</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Folder Include="content\" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Content Include="..\obj\Release\Stubs\*.*">
|
||||
<Link>content\Stubs\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
<Content Include="..\obj\Release\*.txt">
|
||||
<Link>content\txt\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
<Content Include="..\obj\Release\*.dump">
|
||||
<Link>content\dump\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
<Content Include="..\obj\Release\*.strings">
|
||||
<Link>content\dump\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
<Content Include="..\obj\Release\*.resources">
|
||||
<Link>content\resources\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
<Content Include="..\obj\Release\*.il">
|
||||
<Link>content\disasm\%(RecursiveDir)%(Filename)%(Extension)</Link>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Windows.Devices.Gpio.csproj" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>8FD36AD6-387C-48F0-A695-52D9149216FB</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<NuProjPath Condition=" '$(NuProjPath)' == '' ">$(MSBuildExtensionsPath)\NuProj\</NuProjPath>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(NuProjPath)\NuProj.props" Condition="Exists('$(NuProjPath)\NuProj.props')" />
|
||||
<PropertyGroup Label="Configuration">
|
||||
<Id>nanoFramework.Windows.Devices.Gpio.DELIVERABLES</Id>
|
||||
<Version>1.0.0-preview001</Version>
|
||||
<Title>nanoFramework.Windows.Devices.Gpio.DELIVERABLES</Title>
|
||||
<Authors>nanoFramework project contributors</Authors>
|
||||
<Owners>nanoFramework project contributors</Owners>
|
||||
<Summary>nanoFramework.Windows.Devices.Gpio.DELIVERABLES is not meant for development.</Summary>
|
||||
<Description>** DON'T REFERENCE THIS PACKAGE ** Not meant for development. This package includes the deliverable artifacts of the Windows.Devices.Gpio assembly for nanoFramework. These are for testing purposes and for updating the native code base of the core library.</Description>
|
||||
<ReleaseNotes>
|
||||
</ReleaseNotes>
|
||||
<ProjectUrl>https://github.com/nanoframework/nf-class-libraries</ProjectUrl>
|
||||
<LicenseUrl>
|
||||
</LicenseUrl>
|
||||
<Copyright>Copyright (c) 2017 The nanoFramework project contributors</Copyright>
|
||||
<Tags>
|
||||
</Tags>
|
||||
<IconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</IconUrl>
|
||||
<GenerateSymbolPackage>false</GenerateSymbolPackage>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(NuProjPath)\NuProj.targets" />
|
||||
</Project>
|
|
@ -0,0 +1,42 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|AnyCPU">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>AnyCPU</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|AnyCPU">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>AnyCPU</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\Windows.Devices.Gpio.csproj" />
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>96eaba11-6a33-454d-a7b2-b96ca5617e8c</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<NuProjPath Condition=" '$(NuProjPath)' == '' ">$(MSBuildExtensionsPath)\NuProj\</NuProjPath>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(NuProjPath)\NuProj.props" Condition="Exists('$(NuProjPath)\NuProj.props')" />
|
||||
<PropertyGroup Label="Configuration">
|
||||
<Id>nanoFramework.Windows.Devices.Gpio</Id>
|
||||
<Version>1.0.0-preview001</Version>
|
||||
<Title>nanoFramework.Windows.Devices.Gpio</Title>
|
||||
<Authors>nanoFramework project contributors</Authors>
|
||||
<Owners>nanoFramework project contributors</Owners>
|
||||
<Summary>Windows.Devices.Gpio assembly for nanoFramework C# projects</Summary>
|
||||
<Description>This package includes the Windows.Devices.Gpio assembly for nanoFramework C# projects</Description>
|
||||
<ReleaseNotes>
|
||||
</ReleaseNotes>
|
||||
<ProjectUrl>https://github.com/nanoframework/nf-class-libraries</ProjectUrl>
|
||||
<LicenseUrl>
|
||||
</LicenseUrl>
|
||||
<Copyright>Copyright (c) 2017 The nanoFramework project contributors</Copyright>
|
||||
<Tags>nanoFramework C# csharp netmf netnd mscorlib</Tags>
|
||||
<IconUrl>https://secure.gravatar.com/avatar/97d0e092247f0716db6d4b47b7d1d1ad</IconUrl>
|
||||
<GenerateSymbolPackage>false</GenerateSymbolPackage>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(NuProjPath)\NuProj.targets" />
|
||||
</Project>
|
|
@ -0,0 +1,18 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="mscorlib">
|
||||
<HintPath>$(MSBuildThisFileDirectory)mscorlib.dll</HintPath>
|
||||
<Private>True</Private>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
|
||||
<!-- need this here because MSBuild insists on copying mscorlib to output folder because it holds the types that are referenced -->
|
||||
<Target Name="AfterBuild">
|
||||
<Delete Condition="Exists('$(ProjectDir)$(OutDir)mscorlib.dll')" Files="$(ProjectDir)$(OutDir)mscorlib.dll" />
|
||||
<Delete Condition="Exists('$(ProjectDir)$(OutDir)mscorlib.pe')" Files="$(ProjectDir)$(OutDir)mscorlib.pe" />
|
||||
<Delete Condition="Exists('$(ProjectDir)$(OutDir)mscorlib.pdbx')" Files="$(ProjectDir)$(OutDir)mscorlib.pdbx" />
|
||||
</Target>
|
||||
|
||||
</Project>
|
|
@ -0,0 +1,29 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents the actions common to all general-purpose I/O (GPIO) controllers.
|
||||
/// </summary>
|
||||
public interface IGpioControllerProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the number of general-purpose I/O (GPIO) pins available.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The number of GPIO pins available.
|
||||
/// </value>
|
||||
int PinCount { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Opens and returns the general-purpose I/O (GPIO) pin provider for a specific pin.
|
||||
/// </summary>
|
||||
/// <param name="pin">The desired GPIO pin number.</param>
|
||||
/// <param name="sharingMode">The sharing mode to open the pin as.</param>
|
||||
/// <returns>The GPIO pin provider for the specified pin.</returns>
|
||||
IGpioPinProvider OpenPinProvider(int pin, ProviderGpioSharingMode sharingMode);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,73 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using System;
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents actions common to general-purpose I/O (GPIO) pin providers.
|
||||
/// </summary>
|
||||
public interface IGpioPinProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets or sets the debounce timeout for the general-purpose I/O (GPIO) pin, which is an interval during which changes to the value of the pin are filtered out and do not generate ValueChanged events.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The debounce timeout for the GPIO pin, which is an interval during which changes to the value of the pin are filtered out and do not generate ValueChanged events.
|
||||
/// If the length of this interval is 0, all changes to the value of the pin generate ValueChanged events.
|
||||
/// </value>
|
||||
TimeSpan DebounceTimeout { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the pin number of the general-purpose I/O (GPIO) pin
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The pin number of the GPIO pin.
|
||||
/// </value>
|
||||
int PinNumber { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the sharing mode in which the general-purpose I/O (GPIO) pin is open.
|
||||
/// </summary>
|
||||
/// <value>
|
||||
/// The sharing mode in which the GPIO pin is open.
|
||||
/// </value>
|
||||
ProviderGpioSharingMode SharingMode { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the pin's currently configured drive mode.
|
||||
/// </summary>
|
||||
/// <returns>The drive mode of the pin.</returns>
|
||||
ProviderGpioPinDriveMode GetDriveMode();
|
||||
|
||||
/// <summary>
|
||||
/// Determines if a drive mode is supported for the pin.
|
||||
/// </summary>
|
||||
/// <param name="driveMode">The desired drive mode.</param>
|
||||
/// <returns>
|
||||
/// True if the drive mode is supported; otherwise false.
|
||||
/// </returns>
|
||||
bool IsDriveModeSupported(ProviderGpioPinDriveMode driveMode);
|
||||
|
||||
/// <summary>
|
||||
/// Reads the current value of the pin.
|
||||
/// </summary>
|
||||
/// <returns>The pin's value.</returns>
|
||||
ProviderGpioPinValue Read();
|
||||
|
||||
/// <summary>
|
||||
/// Sets the pin's drive mode.
|
||||
/// </summary>
|
||||
/// <param name="value">The desired drive mode for the pin.</param>
|
||||
void SetDriveMode(ProviderGpioPinDriveMode value);
|
||||
|
||||
/// <summary>
|
||||
/// Writes a value to the pin.
|
||||
/// </summary>
|
||||
/// <param name="value">The value to write.</param>
|
||||
void Write(ProviderGpioPinValue value);
|
||||
}
|
||||
}
|
|
@ -0,0 +1,19 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Represents actions common to general-purpose I/O (GPIO) controller providers.
|
||||
/// </summary>
|
||||
public interface IGpioProvider
|
||||
{
|
||||
/// <summary>
|
||||
/// Gets the controllers available on the system.
|
||||
/// </summary>
|
||||
/// <returns>A list of values that represent the controllers available on the system.</returns>
|
||||
IGpioControllerProvider[] GetControllers();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,46 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes whether a general-purpose I/O (GPIO) pin is configured as an input or an output, and how values are driven onto the pin.
|
||||
/// </summary>
|
||||
public enum ProviderGpioPinDriveMode
|
||||
{
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in floating mode, with high impedance.
|
||||
/// </summary>
|
||||
Input,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin as high impedance with a pull-down resistor to ground.
|
||||
/// </summary>
|
||||
InputPullDown,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin as high impedance with a pull-up resistor to the voltage charge connection (VCC).
|
||||
/// </summary>
|
||||
InputPullUp,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in strong drive mode, with low impedance.
|
||||
/// </summary>
|
||||
Output,
|
||||
/// <summary>
|
||||
/// Configures the GPIO in open drain mode.
|
||||
/// </summary>
|
||||
OutputOpenDrain,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open drain mode with resistive pull-up mode.
|
||||
/// </summary>
|
||||
OutputOpenDrainPullUp,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open collector mode.
|
||||
/// </summary>
|
||||
OutputOpenSource,
|
||||
/// <summary>
|
||||
/// Configures the GPIO pin in open collector mode with resistive pull-down mode.
|
||||
/// </summary>
|
||||
OutputOpenSourcePullDown,
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the possible types of change that can occur to the value of the general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
public enum ProviderGpioPinEdge
|
||||
{
|
||||
/// <summary>
|
||||
/// The falling edge, or when value goes from high to low.
|
||||
/// </summary>
|
||||
FallingEdge,
|
||||
/// <summary>
|
||||
/// The rising edge, or when value goes from low to high.
|
||||
/// </summary>
|
||||
RisingEdge,
|
||||
}
|
||||
}
|
|
@ -0,0 +1,22 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the possible values for a general-purpose I/O (GPIO) pin.
|
||||
/// </summary>
|
||||
public enum ProviderGpioPinValue
|
||||
{
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin is high.
|
||||
/// </summary>
|
||||
High,
|
||||
/// <summary>
|
||||
/// The value of the GPIO pin is low.
|
||||
/// </summary>
|
||||
Low,
|
||||
}
|
||||
}
|
|
@ -0,0 +1,24 @@
|
|||
//
|
||||
// Copyright (c) 2017 The nanoFramework project contributors
|
||||
// See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
namespace Windows.Devices.Gpio
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes the modes in which you can open a general-purpose I/O (GPIO) pin.
|
||||
/// These modes determine whether other connections to the GPIO pin can be opened while you have the pin open.
|
||||
/// </summary>
|
||||
public enum ProviderGpioSharingMode
|
||||
{
|
||||
/// <summary>
|
||||
/// Opens the GPIO pin exclusively, so that no other connection to the pin can be opened.
|
||||
/// </summary>
|
||||
Exclusive,
|
||||
/// <summary>
|
||||
/// Opens the GPIO pin as shared, so that other connections in SharedReadOnly mode to the pin can be opened.
|
||||
/// Only operations that do not change the state of the pin can be performed.
|
||||
/// </summary>
|
||||
SharedReadOnly,
|
||||
}
|
||||
}
|
|
@ -0,0 +1,112 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.props" Condition="Exists('packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.props')" />
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{D160797C-52FF-4136-93E1-DA1106B8AE4A}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AssemblyName>Windows.Devices.Gpio</AssemblyName>
|
||||
<RootNamespace>
|
||||
</RootNamespace>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<TargetFrameworkProfile />
|
||||
<TargetFrameworkIdentifier>
|
||||
</TargetFrameworkIdentifier>
|
||||
<TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
|
||||
<RuntimeMetadataVersion>$(RuntimeMetadataVersion)</RuntimeMetadataVersion>
|
||||
<!-- This prevents the default MsBuild targets from referencing System.Core.dll -->
|
||||
<AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences>
|
||||
<!-- These prevent the default MsBuild targets from referencing System.dll and mscorlib.dll -->
|
||||
<NoStdLib>true</NoStdLib>
|
||||
<NoCompilerStandardLib>true</NoCompilerStandardLib>
|
||||
<UseVSHostingProcess>False</UseVSHostingProcess>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
<IsCoreAssembly>true</IsCoreAssembly>
|
||||
<NuGetPackageImportStamp>
|
||||
</NuGetPackageImportStamp>
|
||||
<NF_IsCoreLibrary>True</NF_IsCoreLibrary>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<AssemblyOriginatorKeyFile>key.snk</AssemblyOriginatorKeyFile>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<DelaySign>false</DelaySign>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<!-- override default options for MetaDataProcessor -->
|
||||
<!-- generate PE: TRUE -->
|
||||
<NFMDP_PE_SKIP>false</NFMDP_PE_SKIP>
|
||||
<NFMDP_PE_Verbose>true</NFMDP_PE_Verbose>
|
||||
<NFMDP_PE_VerboseMinimize>true</NFMDP_PE_VerboseMinimize>
|
||||
<!-- generate STUBS: TRUE -->
|
||||
<NFMDP_STUB_SKIP>false</NFMDP_STUB_SKIP>
|
||||
<!-- we like verbose -->
|
||||
<NFMDP_STUB_Verbose>true</NFMDP_STUB_Verbose>
|
||||
<NFMDP_STUB_VerboseMinimize>true</NFMDP_STUB_VerboseMinimize>
|
||||
<NFMDP_STUB_GenerateSkeletonFile>Stubs\Windows_Devices_Gpio_Native</NFMDP_STUB_GenerateSkeletonFile>
|
||||
<NFMDP_STUB_GenerateSkeletonProject>Windows_Devices_Gpio</NFMDP_STUB_GenerateSkeletonProject>
|
||||
<NFMDP_STUB_LegacySkeletonInterop>true</NFMDP_STUB_LegacySkeletonInterop>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<None Include="key.snk" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="AssemblyInfo.cs" />
|
||||
<Compile Include="GpioSharingMode.cs" />
|
||||
<Compile Include="GpioPinValue.cs" />
|
||||
<Compile Include="GpioPinEdge.cs" />
|
||||
<Compile Include="GpioPinDriveMode.cs" />
|
||||
<Compile Include="GpioOpenStatus.cs" />
|
||||
<Compile Include="GpioChangePolarity.cs" />
|
||||
<Compile Include="GpioChangeCount.cs" />
|
||||
<Compile Include="GpioChangeCounter.cs" />
|
||||
<Compile Include="GpioChangeReader.cs" />
|
||||
<Compile Include="GpioChangeRecord.cs" />
|
||||
<Compile Include="GpioController.cs" />
|
||||
<Compile Include="GpioPin.cs" />
|
||||
<Compile Include="Provider\IGpioPinProvider.cs" />
|
||||
<Compile Include="Provider\IGpioControllerProvider.cs" />
|
||||
<Compile Include="Provider\IGpioProvider.cs" />
|
||||
<Compile Include="Provider\ProviderGpioSharingMode.cs" />
|
||||
<Compile Include="Provider\ProviderGpioPinValue.cs" />
|
||||
<Compile Include="Provider\ProviderGpioPinEdge.cs" />
|
||||
<Compile Include="Provider\ProviderGpioPinDriveMode.cs" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||
<PropertyGroup>
|
||||
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
|
||||
</PropertyGroup>
|
||||
<Error Condition="!Exists('packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.props')" Text="$([System.String]::Format('$(ErrorText)', 'packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.props'))" />
|
||||
<Error Condition="!Exists('packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.targets'))" />
|
||||
<Error Condition="!Exists('packages\nanoFramework.CoreLibrary.1.0.0-preview011\build\nanoFramework.CoreLibrary.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\nanoFramework.CoreLibrary.1.0.0-preview011\build\nanoFramework.CoreLibrary.targets'))" />
|
||||
</Target>
|
||||
<Import Project="packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.targets" Condition="Exists('packages\nanoFramework.Tools.MSBuildSystem.1.0.0-preview0029\build\nanoFramework.Tools.MSBuildSystem.targets')" />
|
||||
<Import Project="packages\nanoFramework.CoreLibrary.1.0.0-preview011\build\nanoFramework.CoreLibrary.targets" Condition="Exists('packages\nanoFramework.CoreLibrary.1.0.0-preview011\build\nanoFramework.CoreLibrary.targets')" />
|
||||
</Project>
|
Двоичный файл не отображается.
|
@ -0,0 +1,34 @@
|
|||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio 14
|
||||
VisualStudioVersion = 14.0.25420.1
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Windows.Devices.Gpio", "Windows.Devices.Gpio.csproj", "{D160797C-52FF-4136-93E1-DA1106B8AE4A}"
|
||||
EndProject
|
||||
Project("{FF286327-C783-4F7A-AB73-9BCBAD0D4460}") = "Nuget.Windows.Devices.Gpio", "Nuget.Windows.Devices.Gpio\Nuget.Windows.Devices.Gpio.nuproj", "{96EABA11-6A33-454D-A7B2-B96CA5617E8C}"
|
||||
EndProject
|
||||
Project("{FF286327-C783-4F7A-AB73-9BCBAD0D4460}") = "Nuget.Windows.Devices.Gpio.DELIVERABLES", "Nuget.Windows.Devices.Gpio.DELIVERABLES\Nuget.Windows.Devices.Gpio.DELIVERABLES.nuproj", "{8FD36AD6-387C-48F0-A695-52D9149216FB}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{D160797C-52FF-4136-93E1-DA1106B8AE4A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{D160797C-52FF-4136-93E1-DA1106B8AE4A}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{D160797C-52FF-4136-93E1-DA1106B8AE4A}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{D160797C-52FF-4136-93E1-DA1106B8AE4A}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{96EABA11-6A33-454D-A7B2-B96CA5617E8C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{96EABA11-6A33-454D-A7B2-B96CA5617E8C}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{96EABA11-6A33-454D-A7B2-B96CA5617E8C}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{96EABA11-6A33-454D-A7B2-B96CA5617E8C}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{8FD36AD6-387C-48F0-A695-52D9149216FB}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="nanoFramework.CoreLibrary" version="1.0.0-preview011" targetFramework="net46" />
|
||||
<package id="nanoFramework.Tools.MSBuildSystem" version="1.0.0-preview0029" targetFramework="net46" />
|
||||
</packages>
|
Загрузка…
Ссылка в новой задаче