LyraT 4.3 - need three PWM GPIOs, but they behave weirdly
Posted: Tue May 16, 2023 8:01 pm
Esteemed Quorum,
a small question: for an application, we would like to generate PWM output from a ADF pipeline object. Our hardware is a LyraT 4.3, we use IDF version 4.4. All jumper settings are set to enable JTAG on the JTAG connector.
The initialization is done like so:
Inside the pipeline, we write the new values in like so:
Sadly, the program behaves weirdly. The PWM output works for like three to six seconds and tracks changes, but then stops for three to six seconds.
Could it be that the JTAG engine somehow "blocks" the GPIO pins? If yes, can you maybe suggest a setting in the menuconfig?
If not, are there three "free" GPIO pins on the LyraT which I could use for PWM? I, sadly, do need the I2C bus...
a small question: for an application, we would like to generate PWM output from a ADF pipeline object. Our hardware is a LyraT 4.3, we use IDF version 4.4. All jumper settings are set to enable JTAG on the JTAG connector.
The initialization is done like so:
Code: Select all
#define LEDC_GPIO 14
ledc_channel_config_t ledc_channel;
static void init_wefz(void)
{
ledc_timer_config_t ledc_timer = {
.duty_resolution = 8, // was LEDC_TIMER_10_BIT
.freq_hz = 8000,
.speed_mode = LEDC_HIGH_SPEED_MODE,
.timer_num = LEDC_TIMER_0,
.clk_cfg = LEDC_AUTO_CLK,
};
ledc_timer_config(&ledc_timer);
ledc_channel.channel = LEDC_CHANNEL_0;
ledc_channel.duty = 0;
ledc_channel.gpio_num = LEDC_GPIO;
ledc_channel.speed_mode = LEDC_HIGH_SPEED_MODE;
ledc_channel.hpoint = 0;
ledc_channel.timer_sel = LEDC_TIMER_0;
ledc_channel_config(&ledc_channel);
}
Code: Select all
ledc_set_duty(ledc_channel.speed_mode, ledc_channel.channel, setB);
ledc_update_duty(ledc_channel.speed_mode, ledc_channel.channel);
Could it be that the JTAG engine somehow "blocks" the GPIO pins? If yes, can you maybe suggest a setting in the menuconfig?
If not, are there three "free" GPIO pins on the LyraT which I could use for PWM? I, sadly, do need the I2C bus...