Merge pull request #301 from toozhsu/main

Add support for Tinker Board 2 and Tinker Edge R
This commit is contained in:
Melissa LeBlanc-Williams 2023-06-20 10:06:25 -07:00 committed by GitHub
commit 6cc5669dfb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 24 additions and 2 deletions

View file

@ -154,7 +154,14 @@ class Board:
elif chip_id == chips.RK3308: elif chip_id == chips.RK3308:
board_id = self._rock_pi_id() board_id = self._rock_pi_id()
elif chip_id == chips.RK3399: elif chip_id == chips.RK3399:
board_id = self._rock_pi_id() or self._armbian_id() or self._diet_pi_id() board_id = (
self._rock_pi_id()
or self._armbian_id()
or self._diet_pi_id()
or self._asus_tinker_board_id()
)
elif chip_id == chips.RK3399PRO:
board_id = self._asus_tinker_board_id()
elif chip_id == chips.RK3399_T: elif chip_id == chips.RK3399_T:
board_id = self._rock_pi_id() or self._armbian_id() board_id = self._rock_pi_id() or self._armbian_id()
elif chip_id == chips.ATOM_X5_Z8350: elif chip_id == chips.ATOM_X5_Z8350:
@ -614,6 +621,11 @@ class Board:
board = None board = None
if board_value and "ASUS Tinker Board" in board_value: if board_value and "ASUS Tinker Board" in board_value:
board = boards.ASUS_TINKER_BOARD board = boards.ASUS_TINKER_BOARD
if board_value and "ASUS TINKER BOARD 2" in board_value:
board = boards.ASUS_TINKER_BOARD_2
if board_value and "ASUS_TINKER_EDGE_R" in board_value:
board = boards.ASUS_TINKER_EDGE_R
return board return board
def _pcduino_board_id(self) -> Optional[str]: def _pcduino_board_id(self) -> Optional[str]:

View file

@ -226,6 +226,9 @@ class Chip:
if self.detector.check_dt_compatible_value("radxa,rock-4c-plus"): if self.detector.check_dt_compatible_value("radxa,rock-4c-plus"):
return chips.RK3399_T return chips.RK3399_T
if self.detector.check_dt_compatible_value("rockchip,rk3399pro"):
return chips.RK3399PRO
if self.detector.check_dt_compatible_value("rockchip,rk3399"): if self.detector.check_dt_compatible_value("rockchip,rk3399"):
return chips.RK3399 return chips.RK3399

View file

@ -35,6 +35,8 @@ GIANT_BOARD = "GIANT_BOARD"
# ASUS Tinker Boards # ASUS Tinker Boards
ASUS_TINKER_BOARD = "ASUS_TINKER_BOARD" ASUS_TINKER_BOARD = "ASUS_TINKER_BOARD"
ASUS_TINKER_BOARD_2 = "ASUS_TINKER_BOARD_2"
ASUS_TINKER_EDGE_R = "ASUS_TINKER_EDGE_R"
# Clockwork Pi boards # Clockwork Pi boards
CLOCKWORK_CPI3 = "CLOCKWORK_CPI3" CLOCKWORK_CPI3 = "CLOCKWORK_CPI3"
@ -203,7 +205,11 @@ KHADAS_VIM3 = "KHADAS_VIM3"
_KHADAS_40_PIN_IDS = (KHADAS_VIM3,) _KHADAS_40_PIN_IDS = (KHADAS_VIM3,)
# Asus Tinkerboard # Asus Tinkerboard
_ASUS_TINKER_BOARD_IDS = (ASUS_TINKER_BOARD,) _ASUS_TINKER_BOARD_IDS = (
ASUS_TINKER_BOARD,
ASUS_TINKER_BOARD_2,
ASUS_TINKER_EDGE_R,
)
# STM32MP1 # STM32MP1
_STM32MP1_IDS = ( _STM32MP1_IDS = (

View file

@ -55,6 +55,7 @@ H616 = "H616"
RK3308 = "RK3308" RK3308 = "RK3308"
RK3399 = "RK3399" RK3399 = "RK3399"
RK3399_T = "RK3399_T" RK3399_T = "RK3399_T"
RK3399PRO = "RK3399PRO"
RK3328 = "RK3328" RK3328 = "RK3328"
LPC4330 = "LPC4330" LPC4330 = "LPC4330"
RK3288 = "RK3288" RK3288 = "RK3288"