mirror of
https://github.com/espressif/esp-idf.git
synced 2026-04-27 19:13:21 +00:00
Merge branch 'feat/remove_sdm_set_duty_api' into 'master'
feat(sdm): remove `sdm_channel_set_duty` API Closes IDF-15132 See merge request espressif/esp-idf!45057
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileCopyrightText: 2022-2026 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
@@ -108,22 +108,6 @@ esp_err_t sdm_channel_disable(sdm_channel_handle_t chan);
|
||||
*/
|
||||
esp_err_t sdm_channel_set_pulse_density(sdm_channel_handle_t chan, int8_t density);
|
||||
|
||||
/**
|
||||
* @brief The alias function of `sdm_channel_set_pulse_density`, it decides the pulse density of the output signal
|
||||
*
|
||||
* @note `sdm_channel_set_pulse_density` has a more appropriate name compare this
|
||||
* alias function, suggest to turn to `sdm_channel_set_pulse_density` instead
|
||||
*
|
||||
* @param[in] chan SDM channel created by `sdm_new_channel`
|
||||
* @param[in] duty Actually it's the quantized pulse density of the PDM output signal
|
||||
*
|
||||
* @return
|
||||
* - ESP_OK: Set duty cycle successfully
|
||||
* - ESP_ERR_INVALID_ARG: Set duty cycle failed because of invalid argument
|
||||
* - ESP_FAIL: Set duty cycle failed because of other error
|
||||
*/
|
||||
esp_err_t sdm_channel_set_duty(sdm_channel_handle_t chan, int8_t duty);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -437,9 +437,6 @@ esp_err_t sdm_channel_set_pulse_density(sdm_channel_handle_t chan, int8_t densit
|
||||
return ESP_OK;
|
||||
}
|
||||
|
||||
esp_err_t sdm_channel_set_duty(sdm_channel_handle_t chan, int8_t duty)
|
||||
__attribute__((alias("sdm_channel_set_pulse_density")));
|
||||
|
||||
#if CONFIG_SDM_ENABLE_DEBUG_LOG
|
||||
__attribute__((constructor))
|
||||
static void sdm_override_default_log_level(void)
|
||||
|
||||
@@ -258,6 +258,8 @@ SDMMC
|
||||
|
||||
The legacy Sigma-Delta Modulator driver ``driver/sigmadelta.h`` is deprecated since version 5.0 (see :ref:`deprecate_sdm_legacy_driver`). Starting from version 6.0, the legacy driver is completely removed. The new driver is placed in the :component:`esp_driver_sdm`, and the header file path is ``driver/sdm.h``.
|
||||
|
||||
- :func:`sdm_channel_set_duty` has been removed. Use :func:`sdm_channel_set_pulse_density` instead.
|
||||
|
||||
LCD
|
||||
---
|
||||
|
||||
|
||||
@@ -258,6 +258,8 @@ SDMMC
|
||||
|
||||
旧版的 Sigma-Delta 调制器驱动 ``driver/sigmadelta.h`` 在 5.0 的版本中就已经被弃用(请参考 :ref:`deprecate_sdm_legacy_driver`)。从 6.0 版本开始,旧版驱动被完全移除。新驱动位于 :component:`esp_driver_sdm` 组件中,头文件引用路径为 ``driver/sdm.h``。
|
||||
|
||||
- :func:`sdm_channel_set_duty` 已被移除。请使用 :func:`sdm_channel_set_pulse_density` 替代。
|
||||
|
||||
LCD
|
||||
---
|
||||
|
||||
|
||||
@@ -53,6 +53,9 @@
|
||||
-
|
||||
re_variables: ['(esp_spiram_get_chip_size|esp_spiram_get_size)']
|
||||
hint_variables: ['esp_spiram_get_chip_size and esp_spiram_get_size', 'esp_psram_get_size()']
|
||||
-
|
||||
re_variables: ['sdm_channel_set_duty']
|
||||
hint_variables: ['sdm_channel_set_duty()', 'sdm_channel_set_pulse_density()']
|
||||
|
||||
-
|
||||
re: "error: implicit declaration of function '(MCPWM_GEN_TIMER_EVENT_ACTION_END|MCPWM_GEN_COMPARE_EVENT_ACTION_END|MCPWM_GEN_BRAKE_EVENT_ACTION_END)'"
|
||||
|
||||
Reference in New Issue
Block a user