8000 DSMR fails to compile on Arduino 2.0.3 + platform 4.4.0: missing hwcrypto/aes.h · Issue #3392 · esphome/issues · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

DSMR fails to compile on Arduino 2.0.3 + platform 4.4.0: missing hwcrypto/aes.h #3392

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
sybrenstuvel opened this issue Jun 22, 2022 · 1 comment · Fixed by esphome/esphome#3593

Comments

@sybrenstuvel
Copy link
sybrenstuvel commented Jun 22, 2022

The problem

Using ESPHome with Arduino @ 2.0.3 and platform-espressif32 @ 4.4.0 breaks compilation of the DSMR component. I try to build the project with esphome run thefile.yaml, but it fails because it cannot find hwcrypto/aes.h.

I installed the development version of ESPHome via pip install git+https://github.com/esphome/esphome.git@dev to see if this was recently fixed.

I get the same error with ESPHome 2022.6.1 and any 4.x.x platform. Deleting the .esphome and $HOME/.platformio/.cache directories doesn't help to fix this.

Which version of ESPHome has the issue?

2022.7.0-dev

What type of installation are you using?

pip

Which version of Home Assistant has the issue?

n/a

What platform are you using?

ESP32

Board

frogboard

Component causing the issue

DSMR

Example YAML snippet

esp32:
  board: frogboard
  framework:
    type: arduino
    version: 2.0.3
    platform_version: 4.4.0

# ... snip common config, like device name, wifi parameters, etc.

dsmr:
  uart_id: uart_dsmr
  request_interval: 5s

uart:
  id: uart_dsmr
  baud_rate: 115200
  rx_pin:
    number: GPIO21
    inverted: true
  rx_buffer_size: 1700

Anything in the logs that might be useful for us?

In file included from src/esphome/components/dsmr/dsmr.cpp:6:
.piolibdeps/dsmr/Crypto/AES.h:200:10: fatal error: hwcrypto/aes.h: No such file or directory
 #include "hwcrypto/aes.h"
          ^~~~~~~~~~~~~~~~
compilation terminated.
*** [.pioenvs\dsmr\src\esphome\components\dsmr\dsmr.cpp.o] Error 1

Additional information

The entire build log: bugreport-build-log.txt

@sybrenstuvel
Copy link
Author

kind3r/esp32-ble-gateway#3 (comment) mentions that this might be due to a change in the staging version of the Arduino framework that moves hwcrypto/* to esp32/*. Not sure how to apply that knowledge yet, though; that particular thread "solves" the issue by downgrading platform-espressif32 to 3.x, and I don't think that's a proper solution.

rweather/arduinolibs#66 (comment) has some more info. Apparently including "aes/esp_aes.h" instead solves the issue.

This hints that it's maybe as simple as upgrading the Crypto requirement of DSMR from 0.2.0 to 0.4.0. I'm going to test this.

sybrenstuvel added a commit to sybrenstuvel/esphome that referenced this issue Jun 22, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Dec 1, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant
0