-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add togglable debug, fix distance to empty, reformat using black
- Loading branch information
1 parent
c238d30
commit 9b8ff48
Showing
8 changed files
with
467 additions
and
339 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
__pycache__ | ||
.venv | ||
*.json | ||
/*.json | ||
test.py | ||
dist | ||
*.egg-info |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"[python]": { | ||
"editor.defaultFormatter": "ms-python.black-formatter" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,12 +10,15 @@ | |
from py_uconnect import Client | ||
from py_uconnect.brands import BRANDS | ||
|
||
c = Client('[email protected]', 'very_secret', pin='1234', brand=brands.FIAT_EU) | ||
c.refresh() | ||
v = c.get_vehicles() | ||
# Create client | ||
client = Client('[email protected]', 'very_secret', pin='1234', brand=brands.FIAT_EU) | ||
# Fetch the vehicle data into cache | ||
client.refresh() | ||
|
||
for veh in v.values(): | ||
print(veh.to_json(indent=2)) | ||
# List vehicles | ||
vehicles = client.get_vehicles() | ||
for vehicle in vehicles.values(): | ||
print(vehicle.to_json(indent=2)) | ||
``` | ||
|
||
This would emit something similar to: | ||
|
Oops, something went wrong.