Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register
  • We just completed a significant update, but we still have some fixes and adjustments to make, so please bear with us for the time being. Cheers!

TESLA APP FOR PC

Jupiter

New Member
Oct 18, 2017
3
6
Wales
Although I use an iPhone, I control my house from my PC (in my case Windows 10) e.g. Wind Turbine/Security Camera/Entertainment Channels etc. For me, it would be helpful and logical if I could view my Powerwall 2 data this way as well. I am sure that if there are enough of us interested, Tesla will produce a PC based programme.

Any one interested?
 

Tiger

Active Member
Oct 31, 2016
1,622
1,200
Estonia
Me too .... I'm boycotting smartphones, so yes, windows or linux would be great, or something that works in chrome.
 

Parzival

Member
Aug 11, 2013
148
98
Houston, TX
The built in web server in the gateway already provides some data, and with 1.9.0 it got a little better. I imagine at some point it will likely offer the same controls as the smartphone app. Maybe they'll offer a full web-based UI on Tesla.com at some point. It seems illogical to build desktop PC apps.
 
  • Like
Reactions: miimura

Teresajill

New Member
Mar 7, 2018
1
1
California
Although I use an iPhone, I control my house from my PC (in my case Windows 10) e.g. Wind Turbine/Security Camera/Entertainment Channels etc. For me, it would be helpful and logical if I could view my Powerwall 2 data this way as well. I am sure that if there are enough of us interested, Tesla will produce a PC based programme.

Any one interested?
I'd love to be able to see the same info on my Windows 10 PC as I see on the iphone app.
 
  • Like
Reactions: MP3Mike

FlyF4

Son of a MX
Mar 21, 2017
823
548
moved to San Diego
Although I use an iPhone, I control my house from my PC (in my case Windows 10) e.g. Wind Turbine/Security Camera/Entertainment Channels etc. For me, it would be helpful and logical if I could view my Powerwall 2 data this way as well. I am sure that if there are enough of us interested, Tesla will produce a PC based programme.

Any one interested?
By taking the title literally, it isn't going to happen. But I presume what you really mean is you want the ability to view your data on a Windows 10 platform. It will happen in the form of a web server based platform that you view with a web browser. The main reason is that it will work on a much wider variety of platforms without the need to design code for various device platforms.
 

TomDiego

Member
Jan 28, 2018
42
34
San Diego, CA
This is a good looking app but doesn't have all of the functionality of the Tesla smartphone app in that it doesn't allow you to customize your reserve capacity. If this app were expanded to have that capability and also add the capability to automate changes to the reserve capacity on a schedule, then it could be used for TOU.

PVOutput with extended data will tell you more than this app.
 

ausmeerkat

Member
Mar 7, 2018
17
11
Sydney
Thanks Tom. There is an API to get and change the reserve capacity, but I thought it would be safer to keep the app as read only (I don't want to inadvertantly break someone's system with a bad API call).

I understand proper Time Of Use settings are coming imminently, but if you did want to roll your own I'd suggest doing this with a script you can launch with the scheduler, rather than a GUI app.
 

pv135

Member
Mar 13, 2018
14
0
Australia
Thanks Tom. There is an API to get and change the reserve capacity, but I thought it would be safer to keep the app as read only (I don't want to inadvertantly break someone's system with a bad API call).

I understand proper Time Of Use settings are coming imminently, but if you did want to roll your own I'd suggest doing this with a script you can launch with the scheduler, rather than a GUI app.

Thanks for the app works great. I have been trying for some time to do exactly as you outline, I have my own script which reads the powerwall data fine and controls a few things around the house accordingly (mainly hot water booster) but I'd love to be able to adjust the reserve as weather / solar predictions arn't going to be part of Tesla's app for some time I would think. I can't however get the API to work, have you done this? The Tesla forums (which for some reason I can't post as I am blocked!) say you get get the token using /api/login/Basic and set the level using the retrieved token with /api/operation. I cant get past step 1 and retrieve the token

curl -i -X POST -d "{"username":"","password":"Sxxxxxxxxx","force_sm_off":false}" "http://xxx.xxx.x.xxx/api/login/Basic"
or many variations the best I can get is

HTTP/1.1 401 Unauthorized
Access-Control-Allow-Credentials: false
Access-Control-Allow-Headers: X-Requested-With, X-HTTP-Method-Override, Content-Type, Accept, Accept-Encoding, Authorization
Access-Control-Allow-Methods: GET, POST, PUT, DELETE, PATCH, HEAD, OPTIONS
Access-Control-Allow-Origin: *
Access-Control-Max-Age: 86400
Content-Type: application/json
X-Content-Type-Options: nosniff
Date: Wed, 14 Mar 2018 02:35:35 GMT
Content-Length: 66

{"code":401,"error":"Invalid Credentials","message":"Login Error"}

the password and ip address I use are definitely correct as I log into the wizard ok.

Also once I have the token I am assuming send something like
curl -i -X POST -d "{"backup_reserve_percent": 50, "mode":"self_consumption", "token":"the_retrieved_token"}" http://xxx.xxx.x.xxx/api/operation"

curl -X GET "http://xxx.xxx.x.xxx/api/config/completed"
curl -X GET "htttp://xxx.xxx.x.xxx/api/sitemaster/start"
??

I'm a rotten programmer but usually can get by, but clearly am missing something here, any advice would be appreciated.
Cheers
 

cwied

Member
Jan 13, 2015
867
616
San Mateo, CA
curl -i -X POST -d "{"username":"","password":"Sxxxxxxxxx","force_sm_off":false}" "http://xxx.xxx.x.xxx/api/login/Basic"
or many variations the best I can get is

It looks like you have issues with your quoting. The inside double quotes need to be sent to the powerwall, so you need to either escape them or use different outer quotes.

The token needs to be passed in a header field, not in the body. The header field is "Authorization" and should be set to the value "Bearer XXXXXX" - XXXXXX is the token. So, something like:
curl --header "Authorization: Bearer XXX" -X POST -d '{"mode":"self_consumption","backup_reserve_percent":100}' 'http://xxx/api/operation'
 

pv135

Member
Mar 13, 2018
14
0
Australia
It looks like you have issues with your quoting. The inside double quotes need to be sent to the powerwall, so you need to either escape them or use different outer quotes.

Thanks alot for the reply, yes i figured it's something like that but I had also tried escaping
curl -i -X POST -d "{/"username/":/"/",/"password/":/"SXXXXXXXXXXX/",/"force_sm_off/":false}" "http://xxx.xxx.x.xxx/api/login/Basic"
or and outer overall single quotes, i'll have another look....
 

pv135

Member
Mar 13, 2018
14
0
Australia
duh! OK yes have the token now been along time since I cURL'ed silly stuff with the wrong escape, the following works for me

curl -i -X POST -H "Content-Type: application/json" -d "{\"username\":\"\",\"password\":\"Sxxxxxxxxxxx\",\"force_sm_off\":false}" "http://xxx.xxx.x.xxx/api/login/Basic"

thanks, now trouble getting passing the token to set the level but probably the same sort of mistakes, tbc
 

cwied

Member
Jan 13, 2015
867
616
San Mateo, CA
One tip: after sending the command to set the level, you have to do a get of "/api/config/done" to complete the operation. The Powerwall will be turned off after you set the level, and the config/done applies the changes and starts it again. Note that you'll have to pass the token to this command the same way as with the other calls.
 

pv135

Member
Mar 13, 2018
14
0
Australia
One tip: after sending the command to set the level, you have to do a get of "/api/config/done" to complete the operation. The Powerwall will be turned off after you set the level, and the config/done applies the changes and starts it again. Note that you'll have to pass the token to this command the same way as with the other calls.

Thanks again, I think i'm close but a few points

When I retrieve the token it stops the powerwall, neither a get of "/api/config/done" with the token or even "api/sitemaster/start" (which doesn't need authentication you mentioned on the Tesla forum) will restart the powerwall, I all get in both cases is "404 page not found". I can however stop the powerwall using "/api/sitemaster/stop"

If i manually restart the powerwall I can assign the token sucessfully in the /api/operation POST, it does in fact change the reserve (according to the app) and it doesn't stop the powerwall (its magnificent, it's instant!!)

How exactly do the tokens work? Should they expire? it now actually seems so long as I use any of the previously generated tokens I can adjust the level fine and the PW doesn't stop. if so I guess that's all I need but it would be nice to retrieve a new one and be able to restart it.
 

pv135

Member
Mar 13, 2018
14
0
Australia
Thanks again, I think i'm close but a few points

When I retrieve the token it stops the powerwall, neither a get of "/api/config/done" with the token or even "api/sitemaster/start" (which doesn't need authentication you mentioned on the Tesla forum) will restart the powerwall, I all get in both cases is "404 page not found". I can however stop the powerwall using "/api/sitemaster/stop"

If i manually restart the powerwall I can assign the token sucessfully in the /api/operation POST, it does in fact change the reserve (according to the app) and it doesn't stop the powerwall (its magnificent, it's instant!!)

How exactly do the tokens work? Should they expire? it now actually seems so long as I use any of the previously generated tokens I can adjust the level fine and the PW doesn't stop. if so I guess that's all I need but it would be nice to retrieve a new one and be able to restart it.

by the way i'm on 1.15.0 firmware
 

About Us

Formed in 2006, Tesla Motors Club (TMC) was the first independent online Tesla community. Today it remains the largest and most dynamic community of Tesla enthusiasts. Learn more.

Do you value your experience at TMC? Consider becoming a Supporting Member of Tesla Motors Club. As a thank you for your contribution, you'll get nearly no ads in the Community and Groups sections. Additional perks are available depending on the level of contribution. Please visit the Account Upgrades page for more details.


SUPPORT TMC
Top