Code Monkey home page Code Monkey logo

domoticz-toyota-plugin's People

Contributors

dependabot[bot] avatar joro75 avatar soar245 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

soar245

domoticz-toyota-plugin's Issues

Update to mytoyota 0.8

Update to mytoyota 0.8
Also include a version check on the mytoyota library.
If the version is lower than 0.8, include an error in the log.
If the version number cannot be determined it is below 0.8.

When the door status is not provided, a device is created which is never updated

A door open/locked status device is always created, also if that status information is not provided by the MyT information of the monitored car. This will result in a door open/locked status that is never updated.

It would be better that if the door status is not provided by the MyT information, the device is not created at all.

Upgrade to newest python version

Hello, its me from the parent library.
Would it be possible for you to upgrade to the newest python version 3.12 (3.11 or 3.10 would also be fine. This is so I don't need to support older python versions ๐Ÿ˜„

Pinning a specific version of mytoyota

Hey, the author of mytoyota python module here.

It is humbling to see you build on my work. Awesome project! ๐Ÿ‘ ๐ŸŽ‰

As mytoyota is changing often because of new endpoints being discovered and Toyota changing things on there end (and me becoming a better developer). I would recommend pining a specific version in requirements.txt so users don't accidentally install a version that does not work with you plugin.

Have a nice day!

Add support for Lexus

The mytoyota library now also has support to retrieve the information from cars from Lexus.
Please extend the domoticz plugin to also support Lexus cars.
Proposal is to add an additional dropdown box, where the car manufacturer can be selected: Toyota / Lexus.

And additional improvement can be to also add an 'Auto' option to the dropdown box. This would first trying 'Toyota', and if that isn't working can try 'Lexus'. The working car manufacturer can then be cached and reused in subsequent calls.

Also should update the icon to show the Lexus icon, and include references to the app on the Lexus websites.

If a car has not moved during a day, no record is present in the month view of the distance device

If a car has not moved during a day, no record is present in the month view of the distance device.
For example the car is not used on thuesday, wednesday and thursday. Then only data is included for the other days.
Also a sloped line is shown going from monday directly to friday. This then shows in the graph as if the car was at another distance on wednesday, than it was in reality.

The solution for this problem is also simple.
Some caching is done for the distance, if the distance is not changed, then this caching is causing that no record is added for several days. To resolve this problem, the caching should be reduced in such a way that at least once a day, an update of the actual distance is forwarded to Domoticz, even if the value is the same as the previous value.

Include a check that the mileage is actually increasing

To investigate and prevent a problem, it would be better if we check that the mileage that is returned by the Toyota servers is increased since the last time. If for some unknown reason a lower mileage is returned than we already have, we should ignore the update, assuming that it is a response of outdated data.

Daily milleage not updated

Hi,

Works very well and I'm happy with it, but, just a remark, if the trip is divide during the day, the Mileage is not added in the daily / monthly / yearly graph.

EX: both ways of 32Kms, it displays only 32Kms at the end of the day and not 64Km
Screenshot 2021-12-01 at 09-06-38 Domoticz
s
Rgds,

Marc

Also include a version check on geopy

Similar to what is done with the version check of mytoyota, also a check on the actually used version of geopy should be added.
And if it is too old, we should include a message in the domoticz log to update it.

Also update the README.md, to include reference to this check.

'Too many requests' Exception is raised when retrieving the vehicle information

A 'Too many requests' Exception is raised when retrieving the vehicle information.
See the Log-file

2022-12-05 21:00:08.059 RAV4: Updating vehicle status
2022-12-05 21:00:09.215 Error: RAV4: 'onHeartbeat' failed 'ToyotaApiError':'HTTP: 429 - Too Many Requests. Please try again later.'.
2022-12-05 21:00:09.216 Error: RAV4: Exception traceback:
2022-12-05 21:00:09.217 Error: RAV4: ----> Line 798 in '/home/pi/domoticz/plugins/Domoticz-Toyota-Plugin/plugin.py', function onHeartbeat
2022-12-05 21:00:09.217 Error: RAV4: ----> Line 164 in '/home/pi/domoticz/plugins/Domoticz-Toyota-Plugin/plugin.py', function onHeartbeat
2022-12-05 21:00:09.218 Error: RAV4: ----> Line 752 in '/home/pi/domoticz/plugins/Domoticz-Toyota-Plugin/plugin.py', function update_devices
2022-12-05 21:00:09.218 Error: RAV4: ----> Line 245 in '/home/pi/domoticz/plugins/Domoticz-Toyota-Plugin/plugin.py', function retrieve_vehicle_status
2022-12-05 21:00:09.219 Error: RAV4: ----> Line 50 in '/usr/lib/python3.7/asyncio/runners.py', function run
2022-12-05 21:00:09.219 Error: RAV4: ----> Line 584 in '/usr/lib/python3.7/asyncio/base_events.py', function run_until_complete
2022-12-05 21:00:09.219 Error: RAV4: ----> Line 254 in '/usr/local/lib/python3.7/dist-packages/mytoyota/client.py', function get_vehicle_status
2022-12-05 21:00:09.219 Error: RAV4: ----> Line 73 in '/usr/local/lib/python3.7/dist-packages/mytoyota/api.py', function get_vehicle_status_endpoint
2022-12-05 21:00:09.219 Error: RAV4: ----> Line 226 in '/usr/local/lib/python3.7/dist-packages/mytoyota/controller.py', function request

Information from 2022-11-29 is still available, and seems to be the latest retrieved information. Since then no updates are received anymore.
Domoticz is already restarted, but doesn't seem to make any difference.

Synchronize the status updates to be happening very close before the hour

At this moment the status from the Toyota servers is updated every 5 minutes. This is depending on when Domoticz and/or the plugin is started.
It would be better if the update of the toyota servers is done in such a way that it is done just before the next hour starts. In this way the information is updated in the correct hour, just before the new hour starts.

By slowly increasing or decreasing the interval of the updates, it should be possible to have the update in the last minute of the hour.

Provide correct links to local country websites

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.