From: R. Steve McKown Date: Sat, 17 Dec 2011 17:46:13 +0000 (-0700) Subject: Auto: 5 hrs on, 19 hrs off X-Git-Tag: 1.0~3 X-Git-Url: https://oss.titaniummirror.com/gitweb?p=rgblamp.git;a=commitdiff_plain;h=7716131e4924c8bdfed9792e6425353fa69ea8b4 Auto: 5 hrs on, 19 hrs off The 32 kHz clock is running about 7.3 seconds slow per hour. Not great. Perhaps the board just needs a capacitance tweak or adjustment. Currently using 22 pF load caps with a 12.5 pF crystal, using Vss pin 8 on the micro as ground. --- diff --git a/main.c b/main.c index f9d45cf..8d1792b 100644 --- a/main.c +++ b/main.c @@ -45,16 +45,16 @@ #include "task.h" #include "adc_random.h" -#define AUTO_OFF_COUNT 150 /* 5 mins on*/ -#define AUTO_ON_COUNT 300 /* 10 mins off */ +//#define AUTO_OFF_COUNT 150 /* 5 mins on*/ +//#define AUTO_ON_COUNT 300 /* 10 mins off */ //#define AUTO_OFF_COUNT 450 /* 15 mins on*/ //#define AUTO_ON_COUNT 1350 /* 45 mins off */ //#define AUTO_OFF_COUNT 600 /* 20 mins on*/ //#define AUTO_ON_COUNT 1200 /* 40 mins off */ //#define AUTO_OFF_COUNT 450 /* 2 hours on*/ //#define AUTO_ON_COUNT 1350 /* 22 hours off */ -//#define AUTO_OFF_COUNT 9000U /* 5 hrs in 2 sec units */ -//#define AUTO_ON_COUNT 34200U /* 19 hrs in 2 sec units */ +#define AUTO_OFF_COUNT 9000U /* 5 hrs in 2 sec units */ +#define AUTO_ON_COUNT 34200U /* 19 hrs in 2 sec units */ #define dbgpin_init() do { \ /* Set RA2 as output low */ \ RA2 = 0; \