You can install our site as a web app on your iOS device by utilizing the Add to Home Screen feature in Safari. Please see this thread for more details on this.
Note: This feature may not be available in some browsers.
its running on a free instance in google cloud.
How do you get a free instance in GC?
Sorry init6, how do I do that? Complete numpty when it comes to this.Log into the database and check the drives table is ok. (just to see if the problem is with Grafana or the DB)
from the command line on your server:Sorry init6, how do I do that? Complete numpty when it comes to this.
I am running TM on free GC.
docker exec -it teslamate_database_1 psql -U teslamate
SELECT * FROM drives ORDER BY start_date desc;
Thanks will try that, but I changed the time filter in grafana to 1 year and I got drives until 30 October 22. Nothing thereafterfrom the command line on your server:
It'll ask for your db password
then:
That should give you a list of all your drives. Check that your new ones are showing up. If not share the output.
What happened/changed on the 30th of October?Thanks will try that, but I changed the time filter in grafana to 1 year and I got drives until 30 October 22. Nothing thereafter
Is this close_drives script in Teslamate?Just for completeness. OP had a lot of unclosed drives - possibly due to poor connectivity. We upped the database_timeout setting and that seems to have stopped the drives from being left unclosed and also allowed the close_drives script to plonk (albeit slowly) through the missing drives.
Yes and no.Is this close_drives script in Teslamate?
i got loads of inclosed drives as my connection drops when I arrive home in the underground parking garage
Thanks for your help. There were over 1000 unclosed drives!Just for completeness. OP had a lot of unclosed drives - possibly due to poor connectivity. We upped the database_timeout setting and that seems to have stopped the drives from being left unclosed and also allowed the close_drives script to plonk (albeit slowly) through the missing drives.
On a slightly different teslamate related topic to it not working. does anyone know how some of the metrics are worked out.
I was looking at efficiency screen and it has the current rated efficiency and a series of derived ideal effiociencies which are more or less the same. I can't see in any of the API data where efficiency is actually provided, so is the "rated efficiency" the best fit of the "derived ideal efficiencies" or something else? The reason why I ask is I still have data for my old M3 in there, and itis showing that has a worse ideal efficiency than my MY which might be true, but would surprise me it if was (both are LR models on srd wheels).
Edit Pressed return too soon. Hold on for an answer for part 2.Each charging session will trigger a recalculation of the efficiency, which is applied retroactively to all data. In other words, the longer you use TeslaMate, the more accurate the efficiency value will become.
Net is calculated from (start_range - end_range)*efficiency for each drive >=0.1kmOn a similar basis I'm trying to understand the "Net" v "Gross" efficiency figures on the overview screen and how they're calculated (I don't mean "with and without heating", more what data points are provided by the car to calculate them, unless those figures are provided by the car)
Great - I hadn't thought of browsing github for answers.The efficiency figure is calculated at each charge:
Edit Pressed return too soon. Hold on for an answer for part 2.
It was logged out again this morning when I checked.What do the logs say?
teslamate_1 | 2023-03-01 20:09:35.241 [warning] Retrying in 5 minutes...
teslamate_1 | 2023-03-01 20:10:00.403 [info] GET https://owner-api.teslamotors.com/api/1/vehicles/<snip> -> 401 (194.778 ms)
teslamate_1 | 2023-03-01 20:10:00.404 [info] Refreshing access token ...
teslamate_1 | 2023-03-01 20:10:00.405 car_id=1 [error] Error / :unauthorized
teslamate_1 | 2023-03-01 20:10:05.436 [error] POST https://auth.tesla.com/oauth2/v3/token -> error: "timeout" (5030.454 ms)
teslamate_1 | 2023-03-01 20:10:05.437 [warning] Token refresh failed: %TeslaApi.Error{env: nil, message: "timeout", reason: :token_refresh}
teslamate_1 | 2023-03-01 20:10:05.437 [warning] Retrying in 5 minutes...
teslamate_1 | 2023-03-01 20:10:30.896 [info] GET https://owner-api.teslamotors.com/api/1/vehicles/<snip> -> 401 (488.077 ms)
teslamate_1 | 2023-03-01 20:10:30.897 [info] Refreshing access token ...
teslamate_1 | 2023-03-01 20:10:30.897 car_id=1 [error] Error / :unauthorized
teslamate_1 | 2023-03-01 20:10:35.923 [error] POST https://auth.tesla.com/oauth2/v3/token -> error: "timeout" (5024.283 ms)
teslamate_1 | 2023-03-01 20:10:35.923 [warning] Token refresh failed: %TeslaApi.Error{env: nil, message: "timeout", reason: :token_refresh}
teslamate_1 | 2023-03-01 20:10:35.923 [warning] Retrying in 5 minutes...
teslamate_1 | 2023-03-01 20:11:01.249 [info] GET https://owner-api.teslamotors.com/api/1/vehicles/<snip> -> 401 (348.356 ms)
teslamate_1 | 2023-03-01 20:11:01.251 car_id=1 [error] Error / not_signed_in
teslamate_1 | 2023-03-01 20:11:25.992 [notice] :alarm_handler: {:set, {:"Elixir.TeslaMate.Api.unauthorized", :fuse_blown}}
teslamate_1 | 2023-03-01 20:11:25.993 [notice] :alarm_handler: {:set, {TeslaMate.Vehicles.Vehicle_1_api_error, :fuse_blown}}
teslamate_1 | 2023-03-01 20:13:21.019 [info] GET /
teslamate_1 | 2023-03-01 20:13:21.078 [info] Sent 302 in 59ms
teslamate_1 | 2023-03-01 20:13:21.087 [info] GET /sign_in
teslamate_1 | 2023-03-01 20:13:21.117 [info] Sent 200 in 29ms
teslamate_1 | 2023-03-01 20:15:35.924 [warning] Cannot refresh access token: :not_signed_in
teslamate_1 | 2023-03-01 20:22:46.404 [info] GET /
teslamate_1 | 2023-03-01 20:22:46.433 [info] Sent 302 in 28ms
teslamate_1 | 2023-03-01 20:22:46.466 [info] GET /sign_in
teslamate_1 | 2023-03-01 20:22:46.526 [info] Sent 200 in 60ms
teslamate_1 | 2023-03-01 20:23:18.371 [info] POST https://auth.tesla.com/oauth2/v3/token -> 200 (614.431 ms)
teslamate_1 | 2023-03-01 20:23:18.384 [info] Scheduling token refresh in 6 h
teslamate_1 | 2023-03-01 20:23:18.713 [info] GET /
teslamate_1 | 2023-03-01 20:23:19.035 [info] Starting logger for 'Dave'
teslamate_1 | 2023-03-01 20:23:19.052 [info] Sent 200 in 338ms
teslamate_1 | 2023-03-01 20:23:19.373 car_id=1 [info] Start / :asleep
It was logged out again this morning when I checked.
logs look like a lot of this:
Code:teslamate_1 | 2023-03-01 20:09:35.241 [warning] Retrying in 5 minutes... teslamate_1 | 2023-03-01 20:10:00.403 [info] GET https://owner-api.teslamotors.com/api/1/vehicles/<snip> -> 401 (194.778 ms) teslamate_1 | 2023-03-01 20:10:00.404 [info] Refreshing access token ... teslamate_1 | 2023-03-01 20:10:00.405 car_id=1 [error] Error / :unauthorized teslamate_1 | 2023-03-01 20:10:05.436 [error] POST https://auth.tesla.com/oauth2/v3/token -> error: "timeout" (5030.454 ms) teslamate_1 | 2023-03-01 20:10:05.437 [warning] Token refresh failed: %TeslaApi.Error{env: nil, message: "timeout", reason: :token_refresh} teslamate_1 | 2023-03-01 20:10:05.437 [warning] Retrying in 5 minutes... [/QUOTE] Anything changed on your [URL='https://github.com/adriankumpf/teslamate/issues/2726']network[/URL]? ISTR seeing this fixed with a router reboot.