Skip to content

Commit eba71dd

Browse files
committed
Merge pull request raspberry-sharp#3 from kerams/master
Add Pi 3B detection
2 parents 4b59e9c + 0573be7 commit eba71dd

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

Raspberry.System/Board.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,9 @@ private Model LoadModel()
239239
case 0x1041:
240240
return Model.B2;
241241

242+
case 0x2082:
243+
return Model.B3;
244+
242245
default:
243246
return Model.Unknown;
244247
}
@@ -259,6 +262,7 @@ private ConnectorPinout LoadConnectorPinout()
259262
case Model.ComputeModule:
260263
case Model.APlus:
261264
case Model.B2:
265+
case Model.B3:
262266
return ConnectorPinout.Plus;
263267

264268
default:

Raspberry.System/Model.cs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,12 @@ public enum Model
4646
/// <summary>
4747
/// Pi 2 Model B.
4848
/// </summary>
49-
B2
49+
B2,
50+
51+
/// <summary>
52+
/// Pi 3 Model B.
53+
/// </summary>
54+
B3
5055
}
5156

5257
/// <summary>
@@ -79,6 +84,8 @@ public static string GetDisplayName(this Model model)
7984
return "Raspberry Pi Compute Module";
8085
case Model.B2:
8186
return "Raspberry Pi 2 Model B";
87+
case Model.B3:
88+
return "Raspberry Pi 3 Model B";
8289

8390
default:
8491
throw new ArgumentOutOfRangeException("model");

0 commit comments

Comments
 (0)