This commit is contained in:
2025-10-14 18:45:15 +03:00
parent 10b44f512a
commit f60bbba769
3 changed files with 24 additions and 31 deletions

View File

@@ -9,11 +9,8 @@
#include "esp_log.h"
#include "driver/gpio.h"
// #define ZH_TRIAC_TIME 1 // Triac turn-on time (in microseconds). Depends on the type of triac. Tested on BTA16-600.
#define ZH_AC_DIMMER_INIT_CONFIG_DEFAULT() \
{ \
.ac_dimmer_frequency = ZH_50HZ, \
.zero_cross_gpio = GPIO_NUM_MAX, \
.triac_gpio = GPIO_NUM_MAX, \
.triac_time = 1}
@@ -24,13 +21,6 @@ extern "C"
{
#endif
typedef enum
{
ZH_50HZ = 1,
ZH_60HZ = 2,
ZH_400HZ = 3
} zh_ac_dimmer_frequency_t;
typedef struct // Structure for initial initialization of AC dimmer.
{
uint8_t ac_dimmer_frequency; // AC frequency.