pwm_params.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2021 Otto-von-Guericke-Universität Magdeburg
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
9 #pragma once
10 
21 #include "board.h"
22 #include "saul/periph.h"
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
28 #define SAUL_PWM_NO_RGB
34 {
35 #ifdef LED0_PIN
36  {
37  .name = "LED 1",
38  .channel = { PWM_DEV(0), 0, SAUL_PWM_INVERTED },
39  },
40 #endif
41 #ifdef LED1_PIN
42  {
43  .name = "LED 2",
44  .channel = { PWM_DEV(0), 1, SAUL_PWM_INVERTED },
45  },
46 #endif
47 #ifdef LED2_PIN
48  {
49  .name = "LED 3",
50  .channel = { PWM_DEV(0), 2, SAUL_PWM_INVERTED },
51  },
52 #endif
53 #ifdef LED3_PIN
54  {
55  .name = "LED 4",
56  .channel = { PWM_DEV(0), 3, SAUL_PWM_INVERTED },
57  },
58 #endif
59 };
60 
61 #ifdef __cplusplus
62 }
63 #endif
64 
static const saul_pwm_dimmer_params_t saul_pwm_dimmer_params[]
LED configuration.
Definition: pwm_params.h:33
#define PWM_DEV(x)
Default PWM access macro.
Definition: pwm.h:77
Parameter definitions for mapping peripherals directly to SAUL.
@ SAUL_PWM_INVERTED
Physical values are inverted from average voltage levels (ie.
Definition: periph.h:82
PWM channels mapped to dimmer-style registration entries.
Definition: periph.h:140
const char * name
Name of the device connected to this channel.
Definition: periph.h:141