Smappee integration: control charging point

The Smappee integration is doesn’t allow you to control the charging point at the moment. The API supports this, so it would be nice if the integration can support this as well.
For example when I want to pre-condition my car I would like to auto-switch the charger to normal mode or nothing will happen when there is no sun.

The GitHub request for this has been open a while:

Note that you can control/monitor your smappee charger via OCPP (I have that setup and working smoothly).

That doesn’t allow for current/power delivery to be controlled though. Just on/off at the charging power set elsewhere (e.g. via the smappee app).

Hi Brodykenrick, thanks a lot for suggestion. Which addon/integration did you use for that? I see there are multiple addons, but I’m not sure which one would suite the Smappee best.
Thanks!

That is a yet-to-be-implemented feature request on the core Smappee integration (the one that auto discovers from home assistant core).

I raised the issue on the library that sits under that integration. Minimal response from Smappee on that feature.

The OCPP integration is custom via HACS

I have coded up using the Smappee API to control the car charger current/power using an AppDaemon app.

I toyed with adding it the integration but in the end I wanted to better control the charge power to take in to account my battery (which is beyond the Smappee smart charging).

Happy to clean up my code if others want to use that option.

See over at: Smappee Charger with Postman - #4 by brodykenrick

1 Like

Hi Brodykenrick, how did you setup OCPP on the Smappee side? Did you have to register as a charging host?

Yes. I installed the OCPP integration and made that integration/port available via a static IP and a dedicated DNS (duck DNS).

I then asked Smappee support to “register” me/that address and configured the app.

It all worked rather easily and smoothly.

The component did give a few warnings on boot but worked very nicely - except for not having current/power control. It always charged at a fixed current as configured in the Smappee app.

Smappee support were interested in if this would work and a helped a bit but did remind me on a few occasions that this was not officially supported.

I used it for a about six months but changed to the API just recently to allow me control of charging current. That has been good but annoyingly the API doesn’t report back instantaneous power (which OCPP did). I have to provide a calculated estimate instead (as power for the charger is hidden from the API and MQTT and just sent to Smappee in the background).

I hope that helps. I am happy to help you set up OCPP or the API. Just let me know.

Hi Brody,

Out of curiosity, doesn’t Smappee keep the communication to the OCCP endpoint on your home assistant server on the local network? I guess the Smappee is on your local netwerk as is your HA server but seeing you mention duckdns and opening port 9000 to the outside word would indicate the data takes a round trip to the Smappee servers first and they connect to your OCPP endpoint from their datacenter?

Yes, it goes out via Smappee and then back (it is not meant for home use really).

The smappee charger is just not as accessible/local as the gateway. It doesn’t have decent MQTT the API is OK but goes out to Smappee also. The app also needs internet/cloud tomwork.

The car charger does have local fail-safe settings in case of an internet outage but it doesn’t really have a local mode.

I think it is an architectural decision – as the charger should be relatively easy to expose the same as the gateway but ehy have chosen to not do that.

Ok thanks.
Using the existing Smappee integration trough the API data only updates every 5 minutes so no realy usable to do realtime automations. Getting data trough OCPP or MQTT from the gateway is faster?

Yes, for gateway using the local integration is great. Updates every few seconds.

The charger however is not available in the integration. The API is also limited and does not have power consumption in near real-time.

OCPP was great for power in near real time for the charger (it updates every few seconds). The charger power is “hidden” and is not available via the API though. OCPP had the same number that the App presents though.

In the end for my integration for charging I estimate the EV power based on the current I am setting and as I have all other circuits and total consumption measured by CTs that is pretty accurate.

That has proven accurate enough for two done adjustments.

It is a pretty disappointing lack of detail though. I had quite a few questions to Smappee support confirming it.

I also have an ODBII dongle in the car called WiCAN that I use to close the loop on battery SoC (and other details) for level 2 charging. My car doesn’t have any internet connection itself (in Australia Hyundai doesn’t support it unlike Europe and USA).

Hi Brody,
I think I could use some help on the OCPP part :wink:
I’ve installed the integration, had Smappe accept my IP, added the OCPP in the smappee dashboard and that part seems to work
But I’m not getting any data in my HA…? I’ve installed the integration with the default ip address 0.0.0.0 or do I need to put something else there?
The only part I needed to change was the certificate part to /ssl/fullchain.pem and /ssl/privkey.pem
In the smappee dashboard I configured the ws as wss://x.x.x.x and even tried wss://x.x.x.x:8123 as that is the port HA is listening on :wink: x.x.x.x is the FQDN for my HA

Hmm, I don’t recall doing much configuration in the OCPP integration. It all seemed pretty straight-forward at the time (it is going back a while now since I used it let alone that installation).

When I configured inside the smappee dashboard the “session activation method” on these screens…

…with authorized charging and the ws / wss address you are using goes in there. I think that was what made everything conenct properly (so as lomg as you don’t have any network issues I think that is what made the OCPP integration populate and start getting heart beats).

I was only using ws (not secure) and that seemed to work no worries. I never got around to making wss work before I retired it. Perhaps test as ws only?

I was using port forwarding on my router and had it configured on port 9000 (and was using a basic duckdns setting to make my system avaialble).

ah ok, I haven’t configured port forward for port 9000 yet…
That might be the culprit…I’ll test it tonight…

Strange i’ve forwarded port 9000 to my HA port 9000, but still no luck :frowning: don’t know where to search…
Is it possible to activate and deactivate the Smappee via the API and you just miss the power consumption?

I’ve found it…
In the Smappee dashboard config you have to put the ws(s) with the port you’re connecting to…


And then on your firewall you have to forward that port to the HA to the port you’ve configured there

1 Like

I’ve asked smappee to register my address but they don’t want to do this, is there something specific that I need to ask? They refer to the api manual.

they have added my private address a few weeks ago.

What I did was sent an email to [email protected], and ask them to add my CPO on address “xxx.mydomain.com:{port}” to their platform.
A received back a question that if I’d like to do some integration tests with them on which I replied that that was not needed at this moment.
It only took them some weeks (!!!) to fulfill my request.

The only thing now is that I find the OCPP connection not having additional value to my platform when looking at the data I receive or can send to my wallbox.
So I’m still wondering if I’d like to take a deep dive into the setup … :thinking:

(for your info: my final goal was to create some kind of billing engine in my HA environment of the kWh measured by the Smappee wallbox based on the MID-energy meter, and multiply it with the dynamic electricity tariff. Based on this I could create a manual declaration for my employer…)

Thx for the info, after a second reply on the smappee case and a reference to this post they added my address as cpo and it’s working fine.

1 Like