-
Notifications
You must be signed in to change notification settings - Fork 7.6k
esp32-snippets #176
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
Comments
all of it is available. Everything in IDF is available here. Most of the things I saw as peripherals and network are already implemented in Arduino language. Exception still are PWM, RMT, PCNT and I2S, but again, those are available through the included idf libs. |
Thanks, closing this as it was more about where to find ESP32 snippets in the Arduino IDE and just realized the URL I pasted was from another repo 🤦♂️ |
I am trying to use PCNT in this program. I am not getting any counts when i read the counter value. The program compiles and i get back ESP_OK for the configuration and the read counter value lines. I am using a pulse generator to input pulses on pins 27 and 14. Any thoughts? I tried using interrupts to count pulses on a pin, but interrupts can only handle 3 to 4 pulses/second and inputs 27 and 14 work with interrupts. void initPcnt(){ //initialize counter for flow0 pcnt_set_filter_value(PCNT_UNIT_0, 1); pcnt_config_t pcnt_config2 = { pcnt_set_filter_value(PCNT_UNIT_1, 1); } void readPcntCounter_0(){ if(pcnt_get_counter_value(PCNT_UNIT_0, &flow0Counter) == ESP_OK) } void readPcntCounter_1(){ if(pcnt_get_counter_value(PCNT_UNIT_1, &flow1Counter) == ESP_OK) } |
rdheiliger: Any solution of problem with Pulse Counter? I have the same result.... No reaction for pulses.... |
Same problem here !. Anyone got PCNT working with Arduino IDE ? |
PCNT in Arduino IDE (PlatformIO) is working for me. I'm using it as Frequency Counter. |
Thanks.. And how did you solve the code above? |
Honestly, I played with the code very long time and read a lot of on the internet discussions. Now, the code is part of huge project, I can't remove it form it, don't know, what exactly must be preset or whatever. Here is my code. Timer counts 1s, during this time are counted pulses comming to pin. /* Ověřeno - funguje */ /* LED pin / /* pro timer (dobu), během kterého se budou měřit pulsy */ volatile byte state = LOW; #define PCNT_TEST_UNIT PCNT_UNIT_0 void setup() { void loop() { /* obluha alarmu timeru */
} //initialize counter for flow0 pcnt_config_t pcnt_config = { if(pcnt_unit_config(&pcnt_config) == ESP_OK) //init unit /* nastavení hodnoty pro filtrování / /* Nastavíme všechny eventy */ /Pause counter/ } void readPcntCounter_0() { |
Thanks for your time :-) |
Update README.md
* Adds full support to ULP Adds ULP FSM Macro Defs "ulp.h" file * Adds Full ULP support to S3 Adds ULP FSM Macro Defs "ulp.h" file * Fix ULP defconfig.esp32s2 Fix the Setting option for S2 * Update ULP for IDF 4.x and 5.x * Update ULP for IDF 4.x and 5.x * Enables C6 ULP * Full ULP support for C6 * Pick FSM instead of RISKV ULP * Pick FSM instead of RISCV ULP * Disable C6 RV LP - No way to use it in Arduino * Pick FSM ULP for Arduino. * Pick FSM ULP for Arduino
Found this repo : https://github.com/nkolban/esp32-snippets
How far is it from being usable in the Arduino IDE ?
The text was updated successfully, but these errors were encountered: