Welcome to Tesla Motors Club
Discuss Tesla's Model S, Model 3, Model X, Model Y, Cybertruck, Roadster and More.
Register

Web Based Model S Interface

This site may earn commission on affiliate links.
A few weeks ago folks expressed interest in my PHP/MySQL based web app for the Model S. I created it mostly because I was tired of Tesla's refusal to cache data and make it available when the car sleeps. Thus, you only need to wake the car from the iOS app when you need real time feedback (climate control, unlocking doors, etc).

I released the source code on GitHub a couple days ago. More info below, but please have at least a basic idea of how to deal with MySQL dbs and have a basic understanding of some programming language before installing this on your webserver. I myself am an amateur programmer with zero formal training. The code is messy, yet functional. Cleaning it up has not been one of my priorities so I am releasing it as is.

From github:

This is a web accessable package written in PHP/MYSQL used to retrieve data and set parameters on a compatible Model S (remote access enabled).


Features:
- Track SOC data over time and monitor vampire losses (logger.php)
- View offline range without having to wake the car
- Set the desired charger % without having to wake the car
- Calculates corresponding rated miles for given SOC % using real data!
- View the car's last known location without having to wake the car
- Track a supercharge or any other charge session
- View streaming data in real-time


The beauty is that all of these features output to the browser instead of having to launch a program on your desktop.


Setup:
- Configure an appropriate MYSQL db
- logger.php will need to be executed by cron or task scheduler in 30 min increments


Note:
- Graphing features will require a PHP graphing library (i.e. PHPGraphLib)
- I am an amateur programmer with ZERO formal training. Use at your own risk!

apach3guy/Tesla-Mobile-Web-App · GitHub

Screens:

image.jpg

image.jpg
 
Have you looked at teslams (also on github)? It is a node.js implmentation. I do fully understand the interest in exploring the car with your own code, but I hope we will get a lot of cooperation between these various projects, so we can get the best of all worlds.
That said, this looks great, and I am myself more familiar with php and mysql than with nodejs and mongodb (which teslams uses).
All I want is to keep some kind of datalogger runing locally on my own server, and a nice GUI to view trips, charge speeds, compare data from different periods and so on.
 
@Olen - I was aware of TeslaMS, but was looking for something that would more easily integrate with my existing server (I don't have a nodejs). Also, AFAIK it is command line based and I wanted better cross platform integration and easy access. I use my app on my iPhone, desktop, as well as the Model S touchscreen itself.
 
@apacheguy I know what you mean, and have been looking to create something myself, but now I will probably look a bit more closely at what you have done and see if it fits. The only thing I want to be cli-based (or rather actually a deamon) is a logger.
But if I can integrate teslams logger with this app, that would be really great.
 
@Olen - I was aware of TeslaMS, but was looking for something that would more easily integrate with my existing server (I don't have a nodejs). Also, AFAIK it is command line based and I wanted better cross platform integration and easy access. I use my app on my iPhone, desktop, as well as the Model S touchscreen itself.
The "visualize" gui in teslams is all HTML and works on iOS, Android, desktop browsers, and the tesla console.

Node.js is a simple download from nodejs.org and runs on windows, mac, linux, and even raspberry pi.
 
The "visualize" gui in teslams is all HTML and works on iOS, Android, desktop browsers, and the tesla console.

Huh, I not aware of that implementation. Good to know.

Personally I still prefer my app. The visualize function would be good for the streaming component of my app, but it does much more than just that. I have the ability to work with a sleeping car and set parameters without waking it. I also have the ability to monitor vampire losses. Also, you would still need to build a php script to execute visualize.js from the command line. It is not a native web sever app.