2018-08-06 14:02:17 -06:00
|
|
|
#!/usr/bin/env python
|
|
|
|
from panda import Panda
|
|
|
|
|
|
|
|
def get_panda_password():
|
2019-07-19 20:35:50 -06:00
|
|
|
|
2018-08-06 14:02:17 -06:00
|
|
|
try:
|
|
|
|
print("Trying to connect to Panda over USB...")
|
|
|
|
p = Panda()
|
2019-07-19 20:35:50 -06:00
|
|
|
|
2018-08-06 14:02:17 -06:00
|
|
|
except AssertionError:
|
|
|
|
print("USB connection failed")
|
|
|
|
sys.exit(0)
|
|
|
|
|
|
|
|
wifi = p.get_serial()
|
|
|
|
#print('[%s]' % ', '.join(map(str, wifi)))
|
|
|
|
print("SSID: " + wifi[0])
|
|
|
|
print("Password: " + wifi[1])
|
2019-07-19 20:35:50 -06:00
|
|
|
|
2018-08-06 14:02:17 -06:00
|
|
|
if __name__ == "__main__":
|
|
|
|
get_panda_password()
|