-
Notifications
You must be signed in to change notification settings - Fork 766
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
publish charge rate to MQTT #4130
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -43,6 +43,7 @@ defmodule TeslaMate.Vehicles.Vehicle.ChargingTest do | |
date: _, | ||
charge_energy_added: 0.1, | ||
rated_battery_range_km: 1.61, | ||
charge_rate: 0, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. with a charge_rate of 0 no energy would have been added, innit? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If plugged into a charger and using more energy to precondition the cabin than the charger can supply, charge rate becomes 0 when charging. This is why I want to track this specifically. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yeah understood, but I do want to introduce a separate test case for this. |
||
ideal_battery_range_km: 1.61 | ||
}} | ||
|
||
|
@@ -54,6 +55,7 @@ defmodule TeslaMate.Vehicles.Vehicle.ChargingTest do | |
date: _, | ||
charge_energy_added: 0.2, | ||
rated_battery_range_km: 3.22, | ||
charge_rate: 2, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these values should set to realisitc values There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as before, |
||
ideal_battery_range_km: 3.22 | ||
}} | ||
|
||
|
@@ -64,6 +66,7 @@ defmodule TeslaMate.Vehicles.Vehicle.ChargingTest do | |
date: _, | ||
charge_energy_added: 0.3, | ||
rated_battery_range_km: 4.83, | ||
charge_rate: 10, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these values should set to realisitc values There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As before, realistic value of preconditioning lowering requirement There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as before |
||
ideal_battery_range_km: 4.83 | ||
}} | ||
|
||
|
@@ -76,6 +79,7 @@ defmodule TeslaMate.Vehicles.Vehicle.ChargingTest do | |
date: _, | ||
charge_energy_added: 0.4, | ||
rated_battery_range_km: 6.44, | ||
charge_rate: 10, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. these values should set to realisitc values There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As before There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as before |
||
ideal_battery_range_km: 6.44 | ||
}} | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -263,6 +263,7 @@ defmodule TeslaMateWeb.CarControllerTest do | |
charger_voltage: 229, | ||
charger_actual_current: 16, | ||
battery_range: 200, | ||
charge_rate: 123, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wonder if 123 is a realistic charge rate There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See previous comments There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as before |
||
est_battery_range: 180, | ||
ideal_battery_range: 175, | ||
charging_state: "Charging", | ||
|
@@ -316,6 +317,7 @@ defmodule TeslaMateWeb.CarControllerTest do | |
charging_state: "Charging", | ||
charge_energy_added: "4.32", | ||
ideal_battery_range: 200, | ||
charge_rate: 123, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wonder if 123 is a realistic charge rate There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See previous comments There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as before |
||
time_to_full_charge: 0.33 | ||
} | ||
)} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if 123 is a realistic charge rate
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is, if configured in km it would be an equivalent ~17kW
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then
charge_rate
is not a self explaining variable name.duration_min
is clear, butcharge_rate
is not.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's the rate in distance/time et which you're effectively charging, it has the same name in the API. It's the number that gets displayed when you switch your cars battery level to distance.