You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Licensed to the .NET Foundation under one or more agreements.
2
+
// The .NET Foundation licenses this file to you under the MIT license.
3
+
// See the LICENSE file in the project root for more information.
4
+
5
+
namespaceSystem.Device.I2c
6
+
{
7
+
/// <summary>
8
+
/// Provides information about whether the data transfers that the <see cref="I2cDevice.Read"/>, <see cref="I2cDevice.Write"/>, or <see cref="I2cDevice.WriteRead"/> method performed succeeded, and the actual number
/// An enumeration value that indicates if the read or write operation transferred the full number of bytes that the method requested, or the reason
26
+
/// that the full transfer did not succeed. For WriteReadPartial, the value indicates whether the data for both the write and the read operations was entirely transferred.
// Licensed to the .NET Foundation under one or more agreements.
2
+
// The .NET Foundation licenses this file to you under the MIT license.
3
+
// See the LICENSE file in the project root for more information.
4
+
5
+
namespaceSystem.Device.I2c
6
+
{
7
+
/// <summary>
8
+
/// Describes whether the data transfers that the <see cref="I2cDevice.Read"/>, <see cref="I2cDevice.Write"/>, or <see cref="I2cDevice.WriteRead"/> methods performed succeeded, or provides the reason that the transfers did not succeed.
9
+
/// </summary>
10
+
publicenumI2cTransferStatus
11
+
{
12
+
/// <summary>
13
+
/// The transfer failed for an unknown reason.
14
+
/// </summary>
15
+
UnknownError,
16
+
17
+
/// <summary>
18
+
/// The data was entirely transferred. For WriteRead, the data for both the write and the read operations was entirely transferred.
19
+
/// For this status code, the value of the <see cref="I2cTransferResult.BytesTransferred"/> member that the method returns is the same as the size of the buffer
20
+
/// you specified when you called the method, or is equal to the sum of the sizes of two buffers that you specified for WriteRead.
21
+
/// </summary>
22
+
FullTransfer,
23
+
24
+
/// <summary>
25
+
/// The transfer failed due to the clock being stretched for too long. Ensure the clock line is not being held low.
26
+
/// </summary>
27
+
ClockStretchTimeout,
28
+
29
+
/// <summary>
30
+
/// The I2C device negatively acknowledged the data transfer before all of the data was transferred.
31
+
/// For this status code, the value of the <see cref="I2cTransferResult.BytesTransferred"/> member that the method returns is the number of bytes actually transferred.
32
+
/// For <see cref="I2cDevice.WriteRead"/>, the value is the sum of the number of bytes that the operation wrote and the number of bytes that the operation read.
33
+
/// </summary>
34
+
PartialTransfer,
35
+
36
+
/// <summary>
37
+
/// The bus address was not acknowledged. For this status code, the value of the <see cref="I2cTransferResult.BytesTransferred"/> member that the method returns of the method is 0.
0 commit comments