Skip to content

How to add template for new brand

tmjo edited this page Jul 24, 2023 · 6 revisions

I am receiving a lot of request to add different chargers, which is nice, because that is really the intention! However, since I have an Easee-charger and the card was initially developed to support this type, I am depending on help to add support for other chargers. The card itself is (almost) 100% customizable, so you can basically adapt it to any need by changing the YAML-code yourself.

For most common needs, there is really no need for me to adapt the code - however, not everyone is loving (read: understand how to do) custom adaptions to YAML-code. This is why I came up with the brand-idea. If you're happy with YAML-code, the solution is already there waiting for you to excel your skills and adapt the card. Please take a look at the advanced example in readme and adopt it to your needs. Since you already know some level of "coding", consider using your skills to propose a template for your brand so that other users can benefit from it too (read below how)!

By selecting a brand in the UI-configurator, the idea is that a template in the background does all the magic and configures the card according to your charger (or other stuff). This is what I've called a template. When you change brand the code will adapt to the brand template chosen. However, it is not possible for me to to spend several hours to read the API of each charger and adapt it, also I have no way to test if it is working or not.

Best practice to add a brand template:

  • Take a look at the original template for Easee-charger. This one I know is working and I'm using it myself.
  • If you understand the content of the Easee-template referenced above, all you need to do is modify the content to fit your charger, rename the file to your charger name and to a pull request to have this implemented. To assist this work, there is (of course) a template for templates which you can use to get you started.
  • It will take some time and dedication to do it, which is also why it is impossible for me to do it.
  • Even if you, in your final setup, want a lot of super custom data which does not belong to the charger (or whatever device) integration, please do NOT include this in the template. The template is supposed to work for everyone which has the integration installed, so your own customizations stays as yours.
Clone this wiki locally