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

Using in Arduino Espressif32 framework #31

Open
ttlappalainen opened this issue Mar 31, 2023 · 1 comment
Open

Using in Arduino Espressif32 framework #31

ttlappalainen opened this issue Mar 31, 2023 · 1 comment

Comments

@ttlappalainen
Copy link

I have been using your library successfully several months - maybe over year in Espressif32 framework. Most I have been using Espressif32 version 3.5, but now I am going to 6.1. You could have mention that it works also on that framework.

Some succestions:

  • Could ESP_LOGE be ESP_LOGD instead? I do not see why e.g., "rx_items == 0" would be an error. It is normal that 1-wire line can be empty.
  • In library.json you could have "frameworks": ["espidf","arduino"],
  • There is not much changed from version 3 -> 5 or 6. Could there be conditional compiling to keep same source still for older version? e.g.,
    #if ESP_IDF_VERSION_MAJOR>3
    rmt_set_gpio(info->rx_channel, RMT_MODE_RX, gpio_num,false);
    rmt_set_gpio(info->tx_channel, RMT_MODE_TX, gpio_num,false);
    #else
    rmt_set_pin(info->rx_channel, RMT_MODE_RX, gpio_num);
    rmt_set_pin(info->tx_channel, RMT_MODE_TX, gpio_num);
    #endif

I can also make PR, if you agree my improvements.

@DavidAntliff
Copy link
Owner

Hi @ttlappalainen, thanks for your issue.

Yes, I'd be happy to consider a PR. Your three points seem OK to me, although I don't really want to support IDF v3.x actively. But if you think it would be useful to keep it working for 3.x, then your third point would be OK, if you're able to test it. There may be other things that break with 3.x however, especially as we're moving to the new RMT interface soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants