#NEWLINE# @ staticmethod #NEWLINE# def findSerialDevices( hardwareID = '1B4F:9206' ) : #NEWLINE# #INDENT# hardwareID = ( '(?i)' + hardwareID ) #NEWLINE# if ( len ( SerialGamePad . foundDevices ) == 0 ) : #NEWLINE# #INDENT# SerialGamePad . foundDevices = [ ] #NEWLINE# for port in serial . tools . list_ports . grep ( hardwareID ) : #NEWLINE# #INDENT# SerialGamePad . foundDevices . append ( hardwareID [ 0 ] ) #NEWLINE# #UNINDENT# #UNINDENT# return SerialGamePad . foundDevices