• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

Arduino ESP32 mcpwm_capture

Q&A Forum › Category: ESP32 › Arduino ESP32 mcpwm_capture
0 Vote Up Vote Down
henri karrour asked 4 years ago

// how to define the external input pin to be measured? (GPIO pin)
#include “driver/mcpwm.h”
//====================================================================================
void setup(void)
{
Serial.begin(115200);
mcpwm_gpio_init(MCPWM_UNIT_0, MCPWM0A, GPIO_OUT);
mcpwm_capture_enable(MCPWM_UNIT_0,MCPWM_SELECT_CAP0, MCPWM_NEG_EDGE, 0);
}
//==================================================================================
void loop()
{
unsigned int nombre= mcpwm_capture_signal_get_value(MCPWM_UNIT_0,MCPWM_SELECT_CAP0);

Serial.println(nombre);

}

Question Tags: mcpwm_capture
2 Answers
0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Hi.
I’m not sure I understand your question.
Can you try to better describe your issue?
Regards,
Sara

0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Please follow this issue here: https://rntlab.com/question/how-do-i-use-the-mcpwm-module-of-the-esp32-capture-feature-to-measure-pwm-signals-within-the-arduino-ide/
 

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.