2023-01-27 08:03:57 +00:00
|
|
|
// Copyright 2022 Jay Greco
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
|
|
#include "v1.h"
|
|
|
|
|
|
|
|
void set_scramble_LED(uint8_t mode) {
|
|
|
|
switch(mode) {
|
|
|
|
case LED_ON:
|
2024-05-03 05:21:29 +00:00
|
|
|
gpio_set_pin_output(PIN_LED);
|
|
|
|
gpio_write_pin(PIN_LED, GPIO_STATE_HIGH);
|
2023-01-27 08:03:57 +00:00
|
|
|
break;
|
|
|
|
|
|
|
|
case LED_DIM:
|
2024-05-03 05:21:29 +00:00
|
|
|
gpio_set_pin_input(PIN_LED);
|
2023-01-27 08:03:57 +00:00
|
|
|
break;
|
|
|
|
|
|
|
|
case LED_OFF:
|
2024-05-03 05:21:29 +00:00
|
|
|
gpio_set_pin_output(PIN_LED);
|
|
|
|
gpio_write_pin(PIN_LED, GPIO_STATE_LOW);
|
2023-01-27 08:03:57 +00:00
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|