Microprocessor 2 Labs v2.0
Microprocessor 2 Lab Documenation
Loading...
Searching...
No Matches
led.h
Go to the documentation of this file.
1
12#ifndef _LED_H_
13#define _LED_H_
14
15#include "driver/gpio.h"
16
17
21typedef enum {
22 OFF = 0,
23 ON = 1,
24} state_t;
25
26
38typedef struct {
39 gpio_num_t pin;
41} led_t;
42
43void led_enable(led_t * const led);
44
45void led_on(led_t * const led);
46
47void led_off(led_t * const led);
48
49void led_toggle(led_t * const led);
50
51#endif
void led_off(led_t *const led)
Turn off LED object pin.
Definition led.c:63
void led_enable(led_t *const led)
LED enable.
Definition led.c:27
void led_on(led_t *const led)
Turn on LED object pin.
Definition led.c:50
state_t
lcd.h
Definition led.h:21
@ ON
Definition led.h:23
@ OFF
Definition led.h:22
void led_toggle(led_t *const led)
Toggle LED object pin.
Definition led.c:76
LED object.
Definition led.h:38
state_t state
Definition led.h:40
gpio_num_t pin
Definition led.h:39