医美代码重构
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

37 lines
901 B

#include "esp_log.h"
#include "esp_system.h"
#include "freertos/FreeRTOS.h"
#include "freertos/event_groups.h"
#include "freertos/task.h"
#include "nvs_flash.h"
#include "string.h"
#include "driver/gpio.h"
//
#include "ble_spp_server_demo.h"
#define Electric_relay1 25
#define Electric_relay2 26
#define GPIO_OUTPUT_PIN_SEL ((1ULL << Electric_relay1) | (1ULL << Electric_relay2))
void gpio_rgb_init() {
gpio_config_t gpio_grb_led_structer;
gpio_grb_led_structer.intr_type = GPIO_INTR_DISABLE;
gpio_grb_led_structer.mode = GPIO_MODE_OUTPUT;
gpio_grb_led_structer.pin_bit_mask = GPIO_OUTPUT_PIN_SEL;
gpio_grb_led_structer.pull_down_en = 0;
gpio_grb_led_structer.pull_up_en = 0;
gpio_config(&gpio_grb_led_structer);
}
void app_main(void) {
// ble_spp_server_demo_app_main();
gpio_rgb_init();
gpio_set_level(Electric_relay1,0);
gpio_set_level(Electric_relay2,0);
return;
}