Skip to content

Commit

Permalink
Merge pull request #78 from WildernessLabs/develop
Browse files Browse the repository at this point in the history
Update main for 0.94.2
  • Loading branch information
adrianstevens authored Feb 7, 2023
2 parents dd68a1c + 7e7180d commit c1f3ce8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,29 +10,22 @@ public interface II2cController
/// </summary>
public static I2cBusSpeed DefaultI2cBusSpeed = I2cBusSpeed.Standard;

/// <summary>
/// Creates an I2C bus instance for the default pins.
/// </summary>
/// <param name="busNumber">The bus number</param>
/// <returns>An instance of an I2cBus</returns>
II2cBus CreateI2cBus(
int busNumber = 0);

/// <summary>
/// Creates an I2C bus instance for the default pins and the requested bus speed
/// </summary>
/// <param name="busSpeed">The bus speed.</param>
/// <param name="busSpeed">The bus speed</param>
/// <param name="busNumber">The bus number</param>
/// <returns>An instance of an I2cBus</returns>
II2cBus CreateI2cBus(
int busNumber,
I2cBusSpeed busSpeed
int busNumber = 1,
I2cBusSpeed busSpeed = I2cBusSpeed.Standard
);

/// <summary>
/// Creates an I2C bus instance for the requested pins and bus speed
/// </summary>
/// <param name="busSpeed">The bus speed.</param>
/// <param name="pins">An array of two pins holding the I2C clock and data pins</param>
/// <param name="busSpeed">The bus speed</param>
/// <returns>An instance of an I2cBus</returns>
II2cBus CreateI2cBus(
IPin[] pins,
Expand All @@ -42,7 +35,9 @@ I2cBusSpeed busSpeed
/// <summary>
/// Creates an I2C bus instance for the requested pins and bus speed
/// </summary>
/// <param name="busSpeed">The bus speed.</param>
/// <param name="clock">The I2C clock pin</param>
/// <param name="data">The I2C data pin</param>
/// <param name="busSpeed">The bus speed</param>
/// <returns>An instance of an I2cBus</returns>
II2cBus CreateI2cBus(
IPin clock,
Expand Down
2 changes: 1 addition & 1 deletion Source/Meadow.Contracts/IPlatformOS.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public partial interface IPlatformOS : IPowerController
public SerialPortName? GetSerialPortName(string portName)
{
return GetSerialPortNames().FirstOrDefault(
p => string.Compare(p.FriendlyName, "portName", true) == 0
p => string.Compare(p.FriendlyName, portName, true) == 0
|| string.Compare(p.SystemName, portName, true) == 0);
}
}
Expand Down

0 comments on commit c1f3ce8

Please sign in to comment.