geraldoramos / nikola

⚡Unofficial cross-platform desktop app to monitor and control Tesla vehicles, powered by Electron & React
https://nikola.site
MIT License
149 stars 43 forks source link

Event notifications #29

Closed traviscollins closed 5 years ago

traviscollins commented 5 years ago

I'd like to know when the car starts driving. But you could add a bunch of other events for notification as well. Would be awesome if it showed notifications in the OSX notifications area.

geraldoramos commented 5 years ago

@traviscollins There is a problem with this solution and I've been debating it in other threads. If we set up a notification system like this, we need to keep pinging the car all the time, this will prevent the car from sleeping and will degrade battery life whenever the app is running. The way it is setup today, it will stop pinging when the window is not active (not visible) and will get back to normal 10s pings as soon as the window is opened. If you open the app and the car is sleeping, it will attempt to wake the car then start the pinging again. This way, we don't prevent the car from sleeping.

We can still think about notifications, but it will come with this price, maybe could be an optional feature, that user can enable but will be warned about the non-sleeping issue.

What do you think?

traviscollins commented 5 years ago

TeslaFi has a well documented solution to this.

https://support.teslafi.com/knowledge-bases/2/articles/640-enabling-sleep-settings-to-limit-vampire-loss

I think you should make a SaaS offering. Make it open source for everyone that wants to host it themselves, but offer it as a paid premium service for those not tech savvy enough to host it themselves. The paid service would include all the advanced polling and tracking services.

geraldoramos commented 5 years ago

Thanks for the information!

The initial goal for this app was to not have any server-side functionality and act as a simple, local solution for people looking to monitor their Tesla without the need for trusting a third party with their access token. If I implement a notification/logging mechanism that runs in a server (separated from the desktop app), this will change. Another option is to make the desktop app the notification/logging server itself and the limitation will be that it must be running in order to these services to work.

Having a service/server is a great solution to provide cool features and be able to monitor/log data 24/7 and looks like we can work with the sleeping issue and make it in a way it will not affect battery life (according to your article).

I just need to figure out if this is something I will be able to support if I create a server (it could be open source) but I still need to provide our hosted solution so people can use without the need to configure/run a server somewhere. This means I need different standards in terms of support and need to dedicate a lot more time. My goal was never to make it a commercial thing, but it can change.

I will think about it as I develop more features, fix bugs, get feedback from users and hopefully find some contributors. Let's see where this can go.

Thanks for all your input.

traviscollins commented 5 years ago

I happen to run a Google Cloud consulting company. Happy to walk you through what it takes to run a service like this at minimal cost and time. Done right, it’s easier to do that you might think.

bigarmor.com

On Jun 19, 2019, at 4:47 PM, Geraldo Ramos notifications@github.com wrote:

Thanks for the information!

The initial goal for this app was to not have any server-side functionality and act as a simple, local solution for people looking to monitor their Tesla without the need for trusting a third party with their access token. If I implement a notification/logging mechanism that runs in a server (separated from the desktop app), this will change. Another option is to make the desktop app the notification/logging server itself and the limitation will be that it must be running in order to these services to work.

Having a service/server is a great solution to provide cool features and be able to monitor/log data 24/7 and looks like we can work with the sleeping issue and make it in a way it will not affect battery life (according to your article).

I just need to figure out if this is something I will be able to support if I create a server (it could be open source) but I still need to provide our hosted solution so people can use without the need to configure/run a server somewhere. This means I need different standards in terms of support and need to dedicate a lot more time. My goal was never to make it a commercial thing, but it can change.

I will think about it as I develop more features, fix bugs, get feedback from users and hopefully find some contributors. Let's see where this can go.

Thanks for all your input.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

geraldoramos commented 5 years ago

Thanks! I'm not scared about running the service, it will just unavoidably lead to more work and maintenance.

I have good experience with AWS cloud (ECS, EC2, Lambda, etc), Google Cloud, Heroku and tools like docker, kubernetes and so on. It won't be a problem to get this running very fast. It's just a matter of setting up support channels for customers, billing management (most likely using Stripe) and a bunch of other things that will definitely require more dedication if I want to make a small/tiny business out of this.

Thanks again.