diff main.c @ 5:efa2c22266e3

PWM control LED backlight. Not sure why the AFIO clock needs to be on for this but not, say USART.
author Daniel O'Connor <darius@dons.net.au>
date Fri, 06 Jan 2012 09:46:28 +1030
parents 2c87e30c982d
children 9404b9869c27
line wrap: on
line diff
--- a/main.c	Tue Jan 03 22:37:18 2012 +1030
+++ b/main.c	Fri Jan 06 09:46:28 2012 +1030
@@ -197,6 +197,8 @@
 			fputs(" ", stdout);
 		    }
 		printf("(0x%02x)\r\n", status);
+	    } else if (!strncmp("pwm ", cmd.buf, 4)) {
+		lcd_setpwm(atoi(cmd.buf + 4));
 	    } else if (!strncmp("zz", cmd.buf, 2)) {
 		NVIC_SystemReset();
 	    } else {
@@ -226,7 +228,7 @@
      BKP_DeInit();
     */
 
-    /* Enable LSE */
+    /* Enable Low Speed External clock */
     RCC_LSEConfig(RCC_LSE_ON);
 
     /* Wait till LSE is ready */