ESPHome DSMR not avalable for ESP-IDF?

I’m trying to compile a config with ESPHome Builder 25.10.1 using DSMR, but I’m getting this error: “This feature is only available with framework(s) arduino.” I checked the DSMR Component docs but couldn’t find anything about it.

Is this a bug in the ESPHome Builder?

They forgot to mention it
Have a look at the first and last line of component.
https://api-docs.esphome.io/dsmr_8h_source

1 Like

Thanks, how can I suggest they add this to the documentation?

P.S.
I don’t know much about the ESP-IDF or Arduino frameworks, but would it be possible to make DSMR work with ESP-IDF without any major modifications? I’m asking because I read on a blog that ESP-IDF is the recommended framework.

It’s open source, so you can create a PR with your suggested changes

1 Like

I’m pretty sure they are working on it.

Just keep it on arduino if you don’t need idf for some other reason.
And there’s no reason to update perfectly working setups.

2 Likes

Thanks a lot for the feedback!

You’re right, it’s usually best not to mess with a working setup, but this is actually my first DSMR project with a WT32-ETH01. I saw a blog recommending ESP-IDF because of the big improvements in code size and performance, so I figured it would be a good place to start. I honestly didn’t realize there were so many differences between the frameworks and thought all ESPHome components worked the same no matter which one you used.

Anyway, really appreciate the link to PolarGoose’s PR on GitHub that adds DSMR support for ESP-IDF. Looks like it’s close to being merged once the CI tests are sorted out.

If anyone wants to try it already, you can test it with:

external_components:
  - source: github://pr#11036
    components: [dsmr]
    refresh: 1h

I’ve now tested PR#11036 for ESP-IDF, and at first glance, it seems to work. I’ll start a long-term test and see how it goes.

Unfortunately, I don’t know how to compare performance between the frameworks, but here’s at least the difference in code size between Arduino and ESP-IDF:

-rw-r–r–@ 1 espdev staff 540064 Oct 20 13:31 landisgyr360-p1-g4-dsmr-esp-idf.bin
-rw-r–r–@ 1 espdev staff 1019856 Oct 20 13:33 landisgyr360-p1-g4-dsmr-arduiono.bin