Fixup clueboard support and add rgb to clueboard1
This commit is contained in:
parent
073b44924c
commit
5e822417d7
9 changed files with 137 additions and 43 deletions
|
@ -20,15 +20,13 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
#include "led.h"
|
||||
|
||||
|
||||
void led_set(uint8_t usb_led)
|
||||
{
|
||||
void led_set_kb(uint8_t usb_led) {
|
||||
DDRF |= (1<<0);
|
||||
if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
|
||||
// output low
|
||||
DDRB |= (1<<2);
|
||||
PORTB &= ~(1<<2);
|
||||
// Turn capslock on
|
||||
PORTF |= (1<<0);
|
||||
} else {
|
||||
// Hi-Z
|
||||
DDRB &= ~(1<<2);
|
||||
PORTB &= ~(1<<2);
|
||||
// Turn capslock off
|
||||
PORTF &= ~(1<<0);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue