Use platform detect to see if board is Pi5
This commit is contained in:
parent
41516d60bf
commit
03c93a553d
1 changed files with 8 additions and 0 deletions
|
|
@ -697,6 +697,14 @@ class Shell:
|
|||
detector = adafruit_platformdetect.Detector()
|
||||
return detector.board.id
|
||||
|
||||
@staticmethod
|
||||
def is_pi5_or_newer():
|
||||
"""
|
||||
Use PlatformDetect to check if this is a Raspberry Pi 5 or newer
|
||||
"""
|
||||
detector = adafruit_platformdetect.Detector()
|
||||
return detector.board.any_raspberry_pi_5_board
|
||||
|
||||
@staticmethod
|
||||
def get_architecture():
|
||||
"""
|
||||
|
|
|
|||
Loading…
Reference in a new issue