]> git.donarmstrong.com Git - qmk_firmware.git/blobdiff - keyboard/planck/led.c
Initial commit for Planck PCB Rev 1.
[qmk_firmware.git] / keyboard / planck / led.c
index 7c985108010c6e2deaeea7bedb6f02bef4bba830..448df2ccfb3919a904bb70de4971f3d0aac2329e 100644 (file)
@@ -22,13 +22,17 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 void led_set(uint8_t usb_led)
 {
-    if (usb_led & (1<<USB_LED_FUNCTION)) {
+       // Using PE6 Caps Lock LED
+       if (usb_led & (1<<USB_LED_CAPS_LOCK))
+    {
         // Output high.
-        DDRF |= (1<<0);
-        PORTF |= (1<<0);
-    } else {
+        DDRE |= (1<<6);
+        PORTE |= (1<<6);
+    }
+    else
+    {
         // Output low.
-        DDRF &= ~(1<<0);
-        PORTF &= ~(1<<0);
+        DDRE &= ~(1<<6);
+        PORTE &= ~(1<<6);
     }
 }