]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - board/st/stm32f429-discovery/led.c
karo: tx6: rework PMIC code to allow for different configs for same chip
[karo-tx-uboot.git] / board / st / stm32f429-discovery / led.c
1 /*
2  * (C) Copyright 2015
3  * Kamil Lulko, <rev13@wp.pl>
4  *
5  * SPDX-License-Identifier:     GPL-2.0+
6  */
7
8 #include <common.h>
9 #include <asm-generic/gpio.h>
10
11 void coloured_LED_init(void)
12 {
13         gpio_direction_output(CONFIG_RED_LED, 0);
14         gpio_direction_output(CONFIG_GREEN_LED, 0);
15 }
16
17 void red_led_off(void)
18 {
19         gpio_set_value(CONFIG_RED_LED, 0);
20 }
21
22 void green_led_off(void)
23 {
24         gpio_set_value(CONFIG_GREEN_LED, 0);
25 }
26
27 void red_led_on(void)
28 {
29         gpio_set_value(CONFIG_RED_LED, 1);
30 }
31
32 void green_led_on(void)
33 {
34         gpio_set_value(CONFIG_GREEN_LED, 1);
35 }