Search found 5 matches

by k7ilo1
Wed Jul 20, 2022 1:52 pm
Forum: ESP32 Arduino
Topic: Best Frequency Meter ever made with ESP32 - awesome!
Replies: 100
Views: 151949

Re: Best Frequency Meter ever made with ESP32 - awesome!

Mario Eric wrote:
Mon May 23, 2022 2:09 am
Hi, sorry, I have a problem with the structure:
PCNT.int_clr.val = BIT(PCNT_COUNT_UNIT);
I get an alert: 'PCNT' was not declared in this scope
Could you help me to solve it?
Adding: #include "soc/pcnt_struct.h" fixed my issue.

Kilo
by k7ilo1
Thu May 19, 2022 8:58 pm
Forum: ESP32 Arduino
Topic: How to use "Pulse Counter" module usage under Arduino framework
Replies: 7
Views: 27564

Re: How to use "Pulse Counter" module usage under Arduino framework

Now that I have found the answer to my original issue and determined that this is the closes to what I need for my project, I need to ask a question based on specifically my projects needs. My project was originally developed using the Arduino Nano which has a 16bit timer used as a counter. The time...
by k7ilo1
Wed May 11, 2022 10:05 pm
Forum: ESP32 Arduino
Topic: How to use "Pulse Counter" module usage under Arduino framework
Replies: 7
Views: 27564

Re: How to use "Pulse Counter" module usage under Arduino framework

Never-mind everyone, if there is anyone even monitoring this. I found the answer after days on someone else's website about this counter. For those that might run across this in days or years to come with the same issue, adding #include "soc/pcnt_struct.h" did the trick for me so now it will at leas...
by k7ilo1
Wed May 11, 2022 8:30 pm
Forum: ESP32 Arduino
Topic: Best Frequency Meter ever made with ESP32 - awesome!
Replies: 100
Views: 151949

Re: Best Frequency Meter ever made with ESP32 - awesome!

Hello all. I am receiving "'PCNT' was not declared in this scope" when trying to compile this on my ESP32. It seems I have the library but if not, is this library provided by default or do i need to download it from somewhere? Thanks all Kilo Update: I found the answer on the authors website. Adding...
by k7ilo1
Tue May 10, 2022 4:07 am
Forum: ESP32 Arduino
Topic: How to use "Pulse Counter" module usage under Arduino framework
Replies: 7
Views: 27564

Re: How to use "Pulse Counter" module usage under Arduino framework

Hello all.

I am trying to use either of the codes mentioned here but continue to get a "PCNT was not declared in this scope" for the line
PCNT.int_clr.val = BIT(PCNT_FREQ_UNIT); // clean overflow flag.

Anything specific I need to look for to rectify this issue?

Thanks

Kilo