From 77dda302acb0402a27565e12f98ffc56c1a86389 Mon Sep 17 00:00:00 2001 From: Dean Camera Date: Fri, 15 Jan 2010 02:42:54 +0000 Subject: Fixed invalid USB controller PLL prescaler values for the ATMEGAxxU2 controllers Fixed lack of support for the ATMEGA32U2 in the DFU and CDC class bootloaders Changed incomplete Webserver project over to using the uIP timer library. --- Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.c | 14 +++++--------- Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.h | 2 +- 2 files changed, 6 insertions(+), 10 deletions(-) (limited to 'Projects/Incomplete/Webserver/Lib/uip') diff --git a/Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.c b/Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.c index c3e281ebd..8363d96e0 100644 --- a/Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.c +++ b/Projects/Incomplete/Webserver/Lib/uip/conf/clock-arch.c @@ -12,7 +12,7 @@ volatile clock_time_t clock_datetime = 0; //Overflow interrupt -ISR(TIMER0_OVF_vect) +ISR(TIMER1_COMPA_vect) { clock_datetime += 1; } @@ -20,14 +20,10 @@ ISR(TIMER0_OVF_vect) //Initialise the clock void clock_init() { - //Activate overflow interrupt for timer0 - TIMSK0 |= (1< typedef uint16_t clock_time_t; -#define CLOCK_CONF_SECOND (F_CPU / 1024 / 255) //Freqency divided prescaler and counter register size +#define CLOCK_CONF_SECOND 100 void clock_init(void); clock_time_t clock_time(void); -- cgit v1.2.3 3e5'>diffstats
blob: dc3f0e74aa5d2452cc0a6bde4511909c92781a58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66