Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: New Service Call - Update All Vehicles Data #311

Conversation

coreywillwhat
Copy link
Contributor

@coreywillwhat coreywillwhat commented Mar 26, 2024

audiconnect.update_all_vehicles_data

Overview:

This pull request introduces the audiconnect.update_all_vehicles_data service call. The service leverages an existing backend function, now made accessible through the Home Assistant UI. It's designed to update vehicle data from an online source for all vehicles linked to an account without initiating a vehicle-side refresh.

Use Case:

Given some limitations with the "Refresh Vehicle Data" functionality, this service call provides a workaround by allowing users to manually trigger data updates. It's particularly useful for users who prefer to extend the default refresh interval significantly and wish to manually request updates at specific moments, such as after starting climate control or during periods of inactivity.

Service Call Description:

  • Functionality: Updates data for all vehicles from the online source, mirroring the action performed at integration startup or during scheduled refresh intervals.
  • Behavior: Does not force a vehicle-side data refresh. Consequently, if vehicles haven't recently pushed updates, retrieved data might be outdated.
  • Recommended Usage: Ideal for post-command updates (e.g., after initiating climate control). To ensure data accuracy, a delay of approximately 30 seconds is recommended between command issuance and this service call.
  • Note: This service essentially replicates the function of restarting the integration, offering a more granular control over data refresh moments.

This addition aims to enhance user control over data updates, addressing specific scenarios where updated information is crucial without unnecessarily frequent automated refreshes.

coreywillwhat and others added 19 commits March 24, 2024 12:22
to submit as separate pull request
More Scan Interval Updates
- Initial scan interval to 15
- if user enters less than 15, set to 15
Reference .const DEFAULT_UPDATE_INTERVAL and MIN_UPDATE_INTERVAL.
- default scan interval to default
- if user entered value is less than minimum, set to minimum
Add New Service to Update All Vehicles Data using existing function.
Update services.yaml with new service call `update_all_vehicles_data`
@coreywillwhat coreywillwhat changed the title feat: New Service - Update All Vehicles Data feat: New Service Call - Update All Vehicles Data Mar 26, 2024
@Kolbi
Copy link
Contributor

Kolbi commented Mar 26, 2024

I didn't checked all lines yet but with PR includes all content from #306 ?

@coreywillwhat
Copy link
Contributor Author

coreywillwhat commented Mar 26, 2024

Sorry to cause any confusion. I have not merged your PRs. Currently all (3) of them are still separate, each with a separate purpose:
#311 (This PR) New Service Call - Update All Vehicles Data
#287 Device Drop Downs in Service Calls
#306 New Service Call - Start Climate Control

Edit: I tried to keep them separate...seems my two have merged into this one. yours are not included. again....sorry for the confusion.

@coreywillwhat coreywillwhat deleted the new-update-all-vehicles-data branch March 26, 2024 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants