Awesome
Polestar SoC iOS Lockscreen Widget
An iOS lockscreen widget to display the current state of charge (SoC) of your Polestar.
<img src="./images/polestar_lockscreen_widget.jpeg" width="300" alt="Polestar Lockscreen Widget"/>Background
Since the official Polestar App does not support any kind of widgets for iOS, I developed my own with the help of Scriptable. It uses the official Polestar API which is also used to display the battery status in your profile at https://www.polestar.com.
This widget is a hobby project and the developed code is not affiliated with Polestar AB or any Volvo company or any subsidiary or affiliate of any of the aforementioned companies.
Prerequisites
- Polestar Account login credentials which should work at https://polestarid.eu.polestar.com/PolestarLogin/ and VIN of your car.
- Install Scriptable on your iPhone
- [Optional but recommended] Follow the ScriptDude installation steps
Installation
-
Make sure you have followed all mandatory steps described in Prerequisites.
-
There are two options to install the widget:
-
[Recommended] Click on the following button to install via
ScriptDude
(make sure that you have followed step 3 of Prerequisites). ScriptDude will automatically receive updates of new versions of this widget -
Copy the content of polestar-lockscreen-widget.js, create a new script in
Scriptable
, paste the content and rename it toPolestar Lockscreen SoC Widget
.
-
-
Replace the placeholder values for
EMAIL_ADDRESS
andPASSWORD
with your Polestar login credentials and provide yourVIN
.// Config const POLESTAR_EMAIL = "EMAIL_ADDRESS"; const POLESTAR_PASSWORD = "PASSWORD"; const VIN = "VIN";
-
Add the smallest
Scriptable
widget to your lockscreen. See Apple How-To guide. -
Tab on the widget to configure the widget. Select
Polestar Lockscreen SoC Widget
as script, leave everything else blank and save your lockscreen. -
You should now be able to see the :battery: SoC of your Polestar on you lockscreen. By clicking on the widget you will be navigated to the Polestar App.
Additional comments
There might be a minor lag or difference of the SoC compared to value displayed in the Polestar App because of the following reason:
- The refresh interval of the widget is determined by iOS itself.
The icon has 4 different states.
-
Charging cable not connected. The polestar icon will be displayed.
-
Charging cable is connected, but car is currently not charging e.g. charging has not yet started or charging has been interrupted.
<img src="./images/polestar_lockscreen_widget_connected.jpeg" width="200" alt="Polestar Lockscreen Widget Connected"/> -
Charging cable is connected, car is currently charging.
<img src="./images/polestar_lockscreen_widget_charging.jpeg" width="200" alt="Polestar Lockscreen Widget Charging"/> -
Charging cable is connected, charging is done.
<img src="./images/polestar_lockscreen_widget_done.jpeg" width="200" alt="Polestar Lockscreen Widget Done"/>
Appreciation
- Thanks @simonbs for the awesome Scriptable app.
- Thanks @Sillium for the ProgressCircleService.js which I am reusing.