Skip to content
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

Fix uart to work with new enum definition in esp-idf-v5.2.1 #6487

Merged
merged 1 commit into from
Apr 17, 2024

Conversation

luar123
Copy link
Contributor

@luar123 luar123 commented Apr 5, 2024

What does this implement/fix?

In esp-idf-v5.2.1 the definition of uart_port_t changed from typedef int to enum. Therefor setting uart_num_=-1 is not valid anymore.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Other

Related issue or feature (if applicable): fixes esphome/issues#5672

Pull request in esphome-docs with documentation (if applicable):

Test Environment

  • ESP32
  • ESP32 IDF
  • ESP8266
  • RP2040
  • BK72xx
  • RTL87xx

Checklist:

  • The code change is tested and works locally.
  • Tests have been added to verify that the new code works (under tests/ folder).

If user exposed functionality or configuration variables are added/changed:

@probot-esphome
Copy link

probot-esphome bot commented Apr 5, 2024

Hey there @esphome/core, mind taking a look at this pull request as it has been labeled with an integration (logger) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)

@dragonnn
Copy link

dragonnn commented Apr 11, 2024

Hope this get merged soon. I couldn't get wifi to connect on ESP32-C6 on older idf version then v5.2.1. Using this patch from a local build of esphome works perfectly fine now but it is pretty cumbersome to have to run a separate esphome instance outside HAOS for C6

@luar123
Copy link
Contributor Author

luar123 commented Apr 11, 2024

@dragonnn
Copy link

@dragonnn https://esphome.io/components/external_components

Oh, it means that:

external_components:
    - source: github://luar123/esphome@fix_logger
      components: [ logger ]

Would allow me to use regular HA ESPHOME and have the patched logger from your fix?
Didn't find about it, sounds perfect until that gets merged. Thanks!

@jesserockz
Copy link
Member

@dragonnn

Hope this get merged soon. I couldn't get wifi to connect on ESP32-C6 on older idf version then v5.2.1. Using this patch from a local build of esphome works perfectly fine now but it is pretty cumbersome to have to run a separate esphome instance outside HAOS for C6

While we will get to this at some point. There is no rush as esp-idf 5 is not recommended or supported, and neither is the c6. We merge future focused PRs like this when we get time to validate and test them but they are lower priority than others.

@jesserockz jesserockz added this to the 2024.5.0b1 milestone Apr 16, 2024
@jesserockz jesserockz merged commit 6104e75 into esphome:dev Apr 17, 2024
58 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Apr 19, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Logger uart type changed in esp-idf 5.2
3 participants