bossay_release_out/vendor/bossay/LED/demo_LED/LED.c

19 lines
376 B
C
Raw Permalink Normal View History

2025-09-24 11:16:14 +08:00
#include <stdio.h>
#include "ohos_init.h"
#include "iot_gpio_ex.h"
#include "iot_gpio.h"
#define OUT_GPIO7 7
#define OUT_GPIO11 11
static void LED(void)
{
IoTGpioInit(OUT_GPIO7);
//初始化LED灯
IoTGpioSetFunc(OUT_GPIO7,IOT_GPIO_FUNC_GPIO_7_GPIO);
IoTGpioSetDir(OUT_GPIO7,IOT_GPIO_DIR_OUT);
IoTGpioSetOutputVal(OUT_GPIO7, 1);
}
APP_FEATURE_INIT(LED);