Change hal function names to avoid clash with esphome. #908
msteenhuiz
started this conversation in
Ideas
Replies: 1 comment
-
I don't think this is a good idea. Broadly, the HAL follows Arduino API conventions, which worked for all platforms currently supported, both Arduino and non-Arduino ones. But I don't understand why RadioLib HAL should conform to the fact that esphome decided to globally undef some function names if I understood correctly. In itself that is a very strange design decision in esphome, why should yield, delay etc. be undefed? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This is a request to change some hal function names.
Some names have a clash with esphome.
I see workarounds for that.
How open are you to change some hal names to ease integration?
For instance I see in integrations with esp home for home assistant that this can be done only by undefing defines that are used by esphome. It concerns the following:
#undef yield
#undef millis
#undef micros
#undef delay
#undef delayMicroseconds
So I assume that if these names are changed in the hal layer the conflict is gone.
Something like hal_delay or os_delay?
Is that an option?
e you to change some hal names to ease integration?
For instance I see in integrations with esp home for home assistant that this can be done only by undefing defines that are used by esphome. It concerns the following:
#undef yield
#undef millis
#undef micros
#undef delay
#undef delayMicroseconds
So I assume that if these names are changed in the hal layer the conflict is gone.
Something like hal_delay or os_delay?
Is that an option?
Beta Was this translation helpful? Give feedback.
All reactions