HowTo - Ledvance SMART+ Plug Wifi in Home Assistant (Solution)

Yes, but how did you implemented the LEDVANCE Plugs ?

I had put into my config.yaml
switch: !include configz_ledvance.yaml

And in the configz_ledvance.yaml I had pasted your first smart plug and it did not work out.

Then I had copied your first plug into my config.yaml and when I checked the configuration I had gotten an error message:

Error loading /config/configuration.yaml: while parsing a block mapping
in "/config/configuration.yaml", line 2, column 1
expected <block end>, but found '-'
in "/config/configuration.yaml", line 33, column 1

and my first 2 lines are here

# Loads default set of integrations. Do not remove.
default_config:
# Load frontend themes from the themes folder
frontend:
  themes: !include_dir_merge_named themes

# Text to speech
tts:
  - platform: google_translate

and my line 33 starts with ā€œ- hostā€¦ā€

# ledvance
- host: 192.168.178.25
  device_id: 01158006b8fabcdefgh
  local_key: 9c5b5cd03abcdefgh

ID and key have been changed.

Any ideas how to fix it here in the config.yaml and maybe also in the additional configz_ledvance.yaml ?

Thanks a lot

Just wanted to mention what the ā€œ2024. realityā€ is for this. As a very novice user, Iā€™ve managed to integrate 3 Ledvance SMART+ Wifi plugs and one Teckin smart plug very easily.
Iā€™ve added all of them to the Ledvance SMART+ app, then used this python script to get the keys for each device.
Then I used this Local Tuya integration and everything was added perfectly.
I didnā€™t do anything complicated after, it all worked immediately.

Hello
Sounds really great, !! does the electric metering also work?
I bought 9 if themā€¦and now I switched ti HA, ā€¦and realized they dont work ā€¦
So if this works it is fantastic :partying_face:

To be honest, never tried to set up the power consumption and those things :slight_smile:
Until 10 min ago:

  1. Checked the values that Ledvance app was giving (to have reference values to compare to, to make sure the data I get wouldnā€™t be gibberish)
  2. Found this: Function Definition-Tuya IoT Development Platform-Tuya Developer
  3. Saw in the above document that DPs 18,19 and 20 are denoting current, power and voltage now, so reconfigured the plug while explicitly mentioning DPs 18,19,20.

And everything was added immediately with correct values (been monitoring Tuya Smart App and Home Assistant for 5 min to double check if the values are similar). So I can confirm it works