6 /* Clueboard 2.0 LED locations:
8 * Capslock: B4, pull high to turn on
9 * LCtrl: Shared with Capslock, DO NOT INSTALL LED'S IN BOTH
10 * Page Up: B7, pull high to turn on
11 * Escape: D6, pull high to turn on
12 * Arrows: D4, pull high to turn on
15 void init_backlight_pin(void) {
16 print("init_backlight_pin()\n");
17 // Set our LED pins as output
18 DDRD |= (1<<6); // Esc
19 DDRB |= (1<<7); // Page Up
20 DDRD |= (1<<4); // Arrows
22 // Set our LED pins low
23 PORTD &= ~(1<<6); // Esc
24 PORTB &= ~(1<<7); // Page Up
25 PORTD &= ~(1<<4); // Arrows
28 void backlight_set(uint8_t level) {
31 PORTD |= (1<<6); // Esc
32 PORTB |= (1<<7); // Page Up
33 PORTD |= (1<<4); // Arrows
36 PORTD &= ~(1<<6); // Esc
37 PORTB &= ~(1<<7); // Page Up
38 PORTD &= ~(1<<4); // Arrows