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

Tesla not going to sleep if plugged-in but not charging #332

Closed
leiweke opened this issue Jan 1, 2020 · 17 comments
Closed

Tesla not going to sleep if plugged-in but not charging #332

leiweke opened this issue Jan 1, 2020 · 17 comments

Comments

@leiweke
Copy link

leiweke commented Jan 1, 2020

First of all many thanks for this software.
Setup local Docker install version 1.14.1
Describe the bug
Tesla Model X SW 2019.40.50.1
Plugged into a Go-E Charger conntrolled by OpenWB to only charge if PV is producing energy.
Checking teslamate car is going to sleep for seconds, but then back online do to polling of teslamate. timings are standard 15 min and 21 min.
check the state in grafana and the attached teslamate log attached.
no scheduled departure

Reproduce-able

Expected behavior
car should g to sleep if plugged in but not charging

Teslamate logs:

13:21:14.087 car_id=1 [info] Derived efficiency factor: 216.0 Wh/km (12x confirmed)                                                                                                                                                                          
13:21:14.087 car_id=1 [info] Charging / Disconnected / 29.020000000000003 kWh – 227 min                                                                                                                                                                      
13:21:14.087 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
13:21:14.191 [info] Querying location for elevation takes longer than 100ms ...                                                                                                                                                                              
13:36:18.737 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
13:41:50.403 [info] Repairing drive #56 ...                                                                                                                                                                                                                  
13:41:50.403 [info] OK                                                                                                                                                                                                                                       
13:57:30.639 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
14:10:59.393 car_id=1 [info] Start / :online 
14:25:45.393 [error] TeslaApi.Error / 502 – "<!DOCTYPE html>\n<html>\n<head>\n  <title>We're sorry, but something went wrong (500)</title>\n  <style type=\"text/css\">\n    body { background-color: #fff; color: #666; text-align: center; font-family: ari
al, sans-serif; }\n    div.dialog {\n      width: 25em;\n      padding: 0 4em;\n      margin: 4em auto 0 auto;\n      border: 1px solid #ccc;\n      border-right-color: #999;\n      border-bottom-color: #999;\n    }\n    h1 { font-size: 100%; color: #f0
0; line-height: 1.5em; }\n  </style>\n</head>\n\n<body>\n  <!-- This file lives in public/500.html -->\n  <div class=\"dialog\">\n    <h1>We're sorry, but something went wrong.</h1>\n  </div>\n</body>\n</html>\n"                                         
14:25:45.393 car_id=1 [error] Error / :unknown                                                                                                                                                                                                               
14:26:19.770 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
14:47:31.548 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
14:48:13.782 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
14:51:25.624 car_id=1 [warn] Error / upstream timeout                                                                                                                                                                                                        
14:58:04.112 [info] GET /                                                                                                                                                                                                                                    
14:58:04.117 [info] Sent 200 in 4ms                                                                                                                                                                                                                          
15:03:19.659 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
15:24:31.520 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
15:25:14.773 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
15:40:29.338 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
16:01:41.163 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
16:02:22.861 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
16:12:34.494 [info] GET /                                                                                                                                                                                                                                    
16:12:34.499 [info] Sent 200 in 5ms                                                                                                                                                                                                                          
16:17:23.323 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
16:38:34.525 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
17:04:23.774 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
17:19:37.729 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
17:40:49.517 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
17:41:31.719 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
17:56:37.497 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
18:17:49.281 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
18:18:31.879 car_id=1 [info] Start / :online                                                                                                                                                                                                                 
18:33:44.124 car_id=1 [info] Suspending logging                                                                                                                                                                                                              
18:54:55.929 car_id=1 [info] Start / :asleep                                                                                                                                                                                                                 
19:21:14.318 [info] Adding elevation to 3 positions ...                                                                                                                                                                                                      
19:41:50.400 [info] Repairing drive #56 ...                                                                                                                                                                                                                  
19:41:50.400 [info] OK                                                                                                                                                                                                                                       
20:47:29.875 [info] GET /                                                                                                                                                                                                                                    
20:47:29.879 [info] Sent 200 in 4ms                                                                                                                                                                                                                          
20:51:29.314 [info] GET /                                                                                                                                                                                                                                    
20:51:29.327 [info] Sent 200 in 12ms                                                                                                                                                                                                                         
20:51:32.009 [info] GET /                                                                                                                                                                                                                                    
20:51:32.014 [info] Sent 200 in 5ms                                                                                                                                                                                                                          
20:51:52.451 [info] GET /                                                                                                                                                                                                                                    
20:51:52.456 [info] Sent 200 in 4ms                                                                                                                                                                                                                          
20:51:56.265 [info] GET /                                                                                                                                                                                                                                    
20:51:56.276 [info] Sent 200 in 10ms   

Screenshots

Screen Shot 2019-12-31 at 21 48 40

Thanks Sebastian

@leiweke leiweke added the kind:bug Something isn't working label Jan 1, 2020
@adriankumpf adriankumpf removed the kind:bug Something isn't working label Jan 1, 2020
@leiweke
Copy link
Author

leiweke commented Jan 2, 2020

Hello Adrian, what is the solution ?

@timguy99
Copy link

timguy99 commented Jan 2, 2020

This might be similar to my issue while NOT charging. My car didn't go to sleep after the last couple of updates. Last 3 actually caused it. The first two time I was able to do a reset in the car and that worked. With this last update that didn't work either.

So it may have nothing to do with charging and likely nothing to do with TeslaMate either.

@adriankumpf
Copy link
Collaborator

I can assure you that TeslaMate is not the one to blame here. It never wakes your car. The API calls to wake up vehicles aren’t even implemented. So once your car is asleep, it usually stays asleep unless something else causes it to wake up. Did you double check / rule out the usual suspects already?

  • Try disabling the Tesla App widget from your phone.  When the widget it viewed it makes a connection the car which can prevent the car from sleeping or wake it up.
  • Force close the Tesla App on your phone.  Some android users have found that the Tesla App may be running in the background and keeping the vehicle awake for a period of time until the app shuts down.
  • Make sure no other third-party loggers/services are connected to your account. Turn off any other monitoring app or site and change your Tesla.com password to invalidate your token used to obtain data from your vehicle.  If any other sites or apps are also monitoring the data from your vehicle it may be trying to obtain data while TeslaMate is trying to allow the vehicle to sleep and preventing the car from sleeping.
  • Make sure no key fobs or other bluetooth keys are near the vehicle.  This may prevent the car from sleeping.
  • Try restarting the onboard computer in the vehicle by holding down both scroll wheels on the steering wheel until the main screen restarts.
  • Check your wifi connection to the vehicle.  If the vehicle has a weak wifi signal it may be disconnecting and connecting to the wifi network repeatedly and preventing the vehicle from sleeping.  If you think you may have a weak wifi signal try turning off wifi all together to test if things change.
  • If you have a Model S or X built prior to March 2018 make sure 'Always Connected' is turned off and 'Energy Savings' is turned on in the vehicle.
  • Disable Summon Standby-Mode:  Found in the vehicle in Autopilot settings.  Summon Standbye-Mode will keep the sensors, camera, and computers powered to reduce the amount of time required to begin Summon.  This feature can be disabled all together or for Home, Work or Favorite Locations.
  • Try disabling 'Cabin Overheat Protection' in the vehicle.  This may keep the vehicles systems awake to monitor the inside temperature of the cabin on hot days and prevent it from sleeping.

@timguy99
Copy link

timguy99 commented Jan 2, 2020

Excellent writupe @adriankumpf - perhaps it would be best to put this response in the docs somewhere or do you have a FAQ that you can point to?

I'm still debugging my situation. The only thing I haven't tried is disabling a widget I have for Tesla app on my iPhone. I don't think the regular Tesla app is keeping a connection because anytime I pull it up it shows data from the last time I had the app open which could be like 12 hours ago. But I will try killing the app too even though they suggest not to do that.

@leiweke
Copy link
Author

leiweke commented Jan 2, 2020

I can assure you that TeslaMate is not the one to blame here. It never wakes your car. The API calls to wake up vehicles aren’t even implemented. So once your car is asleep, it usually stays asleep unless something else causes it to wake up. Did you double check / rule out the usual suspects already?

Hello Adrian, thanks for the feedback. My assumption was that each 36 Minutes the Tesla goes to sleep for some seconds and then back to online. 15 + 21 configured in teslamate =36 minutes.
That interval i can see in Grafana timestamps repeatedly

  • Try disabling the Tesla App widget from your phone.  When the widget it viewed it makes a connection the car which can prevent the car from sleeping or wake it up.
    iPhone tesla app with NO background sync, no widget. App normally not running.
  • Force close the Tesla App on your phone.  Some android users have found that the Tesla App may be running in the background and keeping the vehicle awake for a period of time until the app shuts down.
    iPhone app normally not running on phone, no background sync allowed
  • Make sure no other third-party loggers/services are connected to your account. Turn off any other monitoring app or site and change your Tesla.com password to invalidate your token used to obtain data from your vehicle.  If any other sites or apps are also monitoring the data from your vehicle it may be trying to obtain data while TeslaMate is trying to allow the vehicle to sleep and preventing the car from sleeping.
    no other logger used.
  • Make sure no key fobs or other bluetooth keys are near the vehicle.  This may prevent the car from sleeping.
    Sure, they are in a metal box in the house 15 meters away from the garage
  • Try restarting the onboard computer in the vehicle by holding down both scroll wheels on the steering wheel until the main screen restarts.
    Okay will do tomorrow.
  • Check your wifi connection to the vehicle.  If the vehicle has a weak wifi signal it may be disconnecting and connecting to the wifi network repeatedly and preventing the vehicle from sleeping.  If you think you may have a weak wifi signal try turning off wifi all together to test if things change.
    Wifi AP is in the garage, full coverage
  • If you have a Model S or X built prior to March 2018 make sure 'Always Connected' is turned off and 'Energy Savings' is turned on in the vehicle.
    Model X from May 2019, on option
  • Disable Summon Standby-Mode:  Found in the vehicle in Autopilot settings.  Summon Standbye-Mode will keep the sensors, camera, and computers powered to reduce the amount of time required to begin Summon.  This feature can be disabled all together or for Home, Work or Favorite Locations.
    Not enabled, not usable in Europe :-(
  • Try disabling 'Cabin Overheat Protection' in the vehicle.  This may keep the vehicles systems awake to monitor the inside temperature of the cabin on hot days and prevent it from sleeping.
    Yes disabled.

As i say the interval is 36 Minutes 15+21 configured in Teslamate.
is there any debug logging that i can provide you with ?
Test for tomorrow:
I will NOT reboot the onboard comp. I will shut down teslamate, plug in but not charging. after some hours i will fire up Tesla app and see if "wake up" is coming up. If so i need your help :-)
If app is directly connected (car not sleeping) i will report an do the reboot of the onboard.
Okay? any other hints/ideas/logging ?
Thanks a million
Sebastian

@Tigwin
Copy link

Tigwin commented Jan 4, 2020

Are you doing scheduled charging? I have a model 3 with scheduled charging and it doesn't wake up at all unless it charges.

image

@leiweke
Copy link
Author

leiweke commented Jan 4, 2020

No scheduled charging. Just received SW40.50.7 will install, do a reboot and plug in without charging until the sun will come out :-) possible tomorrow.

@leiweke
Copy link
Author

leiweke commented Jan 5, 2020

Test 1 done, Result no change. TM on 1.41.2
at 9:21pm I did SW 40.50.7 installed,
reset done on all systems: Reset of 'most' systems (4 fingers) ~~
Put/keep foot on brake. Press and hold both scroll buttons and steering wheel buttons above the scroll wheels. Keep foot on brake until CD and IC display are non-blank.
wait for all systems boot up,
then plug in. go-e charger is connected but not providing power (no Sun),
no scheduled departure
Result: online for 36 minutes (15+21 configured in TeslaMate) then for 30-50 seconds asleep then again online for 36 minutes, then again asleep an so on the night.
at 10:45 I unplugged and at 11:10 he goes to sleep until now.
here the log:
Screen Shot 2020-01-05 at 12 26 34

here the docker log:
04:53:07.579 car_id=1 [info] Start / :online
05:03:46.220 [info] Repairing drive #56 ... what is this, I see this very often
05:03:46.220 [info] OK
05:08:21.699 car_id=1 [info] Suspending logging
05:29:33.722 car_id=1 [info] Start / :asleep
05:30:16.490 car_id=1 [info] Start / :online
05:45:28.968 car_id=1 [info] Suspending logging
06:06:40.776 car_id=1 [info] Start / :asleep
06:07:22.944 car_id=1 [info] Start / :online
06:22:32.425 car_id=1 [info] Suspending logging
06:43:43.570 car_id=1 [info] Start / :asleep
06:44:25.771 car_id=1 [info] Start / :online
06:59:38.521 car_id=1 [info] Suspending logging
07:20:49.679 car_id=1 [info] Start / :asleep
07:21:31.913 car_id=1 [info] Start / :online
07:36:42.799 car_id=1 [info] Suspending logging
07:57:54.574 car_id=1 [info] Start / :asleep
07:58:36.755 car_id=1 [info] Start / :online
08:13:50.752 car_id=1 [info] Suspending logging
08:25:01.788 [info] Adding elevation to 3 positions ...
08:35:02.623 car_id=1 [info] Start / :asleep
08:35:44.742 car_id=1 [info] Start / :online
08:50:57.010 car_id=1 [info] Suspending logging
09:12:08.916 car_id=1 [info] Start / :asleep
09:12:51.072 car_id=1 [info] Start / :online
09:28:02.383 car_id=1 [info] Suspending logging
09:38:31.487 [info] GET /
09:38:31.493 [info] Sent 200 in 6ms
09:49:05.459 car_id=1 [info] Suspending logging
10:10:17.271 car_id=1 [info] Start / :asleep
11:03:46.222 [info] Repairing drive #56 ...
11:03:46.222 [info] OK
11:08:50.639 [info] GET /
11:08:50.647 [info] Sent 200 in 7ms
11:08:53.721 [info] GET /
11:08:53.728 [info] Sent 200 in 6ms
11:09:14.214 [info] GET /
11:09:14.222 [info] Sent 200 in 7ms
11:09:34.967 [info] GET /

this makes Solar charging totally useless as I drains energy for nothing (not blaming TM :-))

Next test tonight : same setup and scheduled departure for 9:00

@Tigwin
Copy link

Tigwin commented Jan 5, 2020

Did you try disabling bt on your phones to make sure the app isnt keeping the car awake? How about changing your Tesla password in case you have another service still using it.

@leiweke
Copy link
Author

leiweke commented Jan 5, 2020

@Tigwin Tesla App is off and no background sync allowed, see above. no other service used. Password changed already as first.

@Tigwin
Copy link

Tigwin commented Jan 5, 2020

That's crazy. Are you able to measure the vampire drain on the battery caused by the car always being awake? If so, you could test overnight with teslamate enabled, and the next day do the same test with teslamate turned off and compare to see if it improved or not.

@leiweke
Copy link
Author

leiweke commented Jan 5, 2020

@Tigwin just started the scheduled departure test, see above. SOC 68% set to80% so should start charing about 8pm.

@timguy99
Copy link

timguy99 commented Jan 5, 2020

I’ve had similar issues after an update with the car not sleeping. See other issue thread. Sorry, don’t have the number right now. Seems to be unrelated to TelsaMate as far as I can determine. I once fixed it by resetting the car but this last time it didn’t help.

@leiweke
Copy link
Author

leiweke commented Jan 5, 2020

Test 2 done.
scheduled departure set to 10:00 pm and plugged in. Tesla charged only 0,35 kw to sync the charging speed and then Tesla switched off charging and TM said it will start charging 7:55pm.
AND now Tesla goes to sleep :-)

Result, it is not Teslamate.

my assumption is that if Tesla is not in charge to steer the charging (scheduled charging) it will not go to sleep and wait for what ever.
I think this has changed in the last several SW releases.
This makes Solar powered steed charging useless :-(

@adriankumpf, I don't know you wallbox setup, but could you disable scheduled departure, plug in and don't charge (if you wallbox allow this) ?

Test 3 no scheduled departure, plugged in and not charging (wallbox not providing power to car). test 3 just running
any ideas are welcome :-)

@adriankumpf
Copy link
Collaborator

@adriankumpf, I don't know you wallbox setup, but could you disable scheduled departure, plug in and don't charge (if you wallbox allow this) ?

My wallbox doesn't allow that :-(

I wonder if we can close this as the problem seems to be caused by the firmware or the charger itself? Maybe they can help you on Reddit or one of the Tesla forums?

@leiweke
Copy link
Author

leiweke commented Jan 14, 2020

Okay closed
Thanks for your support

@leiweke leiweke closed this as completed Jan 14, 2020
@profex1337
Copy link

Hi, whats the solution here?

I have the same problem with my Model S.
My Model 3 is sleeping without problems.

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

No branches or pull requests

5 participants