Skip to content

Commit 034382b

Browse files
authored
Update board.py
1 parent c493701 commit 034382b

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

adafruit_platformdetect/board.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -832,8 +832,8 @@ def _rp2040_u2if_id(self) -> Optional[str]:
832832
# KB2040 Kee Board
833833
if product == 0x0105:
834834
return boards.KB2040_U2IF
835-
if vendor == 0x2E8A and product == 0x111F:
836-
return boards.WAVESHARE_RP2040_ONE_U2IF
835+
if vendor == 0x2E8A and product == 0x103A:
836+
return boards.RP2040_ONE_U2IF
837837
# Will only reach here if a device was added in chip.py but here.
838838
raise RuntimeError("RP2040_U2IF device was added to chip but not board.")
839839

@@ -1084,6 +1084,7 @@ def lazily_generate_conditions():
10841084
yield self.board.QTPY_U2IF
10851085
yield self.board.QT2040_TRINKEY_U2IF
10861086
yield self.board.KB2040_U2IF
1087+
yield self.board.RP2040_ONE_U2IF
10871088
yield self.board.OS_AGNOSTIC_BOARD
10881089

10891090
return any(condition for condition in lazily_generate_conditions())
@@ -1212,6 +1213,10 @@ def kb2040_u2if(self) -> bool:
12121213
return self.id == boards.KB2040_U2IF
12131214

12141215
@property
1216+
def rp2040_one_u2if(self) -> bool:
1217+
"""Check whether the current board is an RP2040 One w/ u2if."""
1218+
return self.id == boards.RP2040_ONE_U2IF
1219+
@property
12151220
def binho_nova(self) -> bool:
12161221
"""Check whether the current board is an BINHO NOVA."""
12171222
return self.id == boards.BINHO_NOVA

0 commit comments

Comments
 (0)