More code cleanup. Broke support for the Launchpad.
[goodfet] / firmware / lib / msp430.c
index 1684f59..19bca37 100644 (file)
@@ -17,6 +17,7 @@ void led_init()
 {
        PLEDDIR |= PLEDPIN;
 }
+
 void led_on()
 {
        PLEDOUT |= PLEDPIN;
@@ -24,10 +25,10 @@ void led_on()
 void led_off()
 {
   PLEDOUT&=~PLEDPIN;
-
 }
 void led_toggle()
 {
+       PLEDOUT ^= PLEDPIN;
 }
 
 //! Initialize MSP430 registers and all that jazz.
@@ -79,13 +80,13 @@ void msp430_init(){
 #endif
 
        /** FIXME
-         
+
          This part is really ugly.  GSEL (P5.7) must be high to select
          normal voltage, but a lot of applications light to swing it low
          to be a nuissance.  To get around this, we assume that anyone
          with a glitching FET will also have a DAC, then we set that DAC
          to a high voltage.
-         
+
          At some point, each target must be sanitized to show that it
          doesn't clear P5OUT or P5DIR.
        */