]>
Commit | Line | Data |
---|---|---|
ec1bef8e | 1 | /* vim:ts=4 sts=4 et tw=80 |
2 | * | |
3 | * fnordlicht firmware | |
4 | * | |
5 | * for additional information please | |
6 | * see http://lochraster.org/fnordlichtmini | |
7 | * | |
8 | * (c) by Alexander Neumann <alexander@bumpern.de> | |
9 | * Lars Noschinski <lars@public.noschinski.de> | |
10 | * | |
11 | * This program is free software: you can redistribute it and/or modify it | |
12 | * under the terms of the GNU General Public License version 3 as published by | |
13 | * the Free Software Foundation. | |
14 | * | |
15 | * This program is distributed in the hope that it will be useful, but WITHOUT | |
16 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
17 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | |
18 | * more details. | |
19 | * | |
20 | * You should have received a copy of the GNU General Public License along with | |
21 | * this program. If not, see <http://www.gnu.org/licenses/>. | |
22 | */ | |
23 | ||
24 | #ifndef _FNORDLICHT_GLOBALS_H | |
25 | #define _FNORDLICHT_GLOBALS_H | |
26 | ||
27 | #include <avr/version.h> | |
28 | #include "config.h" | |
29 | #include "../common/common.h" | |
30 | ||
31 | /* check for avr-libc version */ | |
32 | #if __AVR_LIBC_VERSION__ < 10600UL | |
33 | #error "newer libc version (>= 1.6.0) needed!" | |
34 | #endif | |
35 | ||
36 | /* check if cpu speed is defined */ | |
37 | #ifndef F_CPU | |
38 | #error "please define F_CPU! (see Makefile)" | |
39 | #endif | |
40 | ||
41 | /* check if this cpu is supported */ | |
42 | #if !(defined(__AVR_ATmega8__) || defined(__AVR_ATmega88__) || defined(__AVR_ATmega168__)) | |
43 | #error "this cpu is not supported yet!" | |
44 | #endif | |
45 | ||
46 | /* fifo size should be a power of 2 and below 128 */ | |
47 | #define CONFIG_FIFO_SIZE 64 | |
48 | ||
49 | /* configure primary pwm pins (MUST be three successive pins in a port) */ | |
50 | #define PWM_PORT B | |
51 | #define PWM_CHANNELS 3 | |
52 | #define PWM_CHANNEL_MASK (_BV(PB0) | _BV(PB1) | _BV(PB2)) | |
53 | #define PWM_SHIFT 0 | |
54 | ||
55 | /* configure secondary pwm pins (MUST be three successive pins in a port) */ | |
56 | #define PWM2_PORT D | |
57 | #define PWM2_CHANNEL_MASK (_BV(PD5) | _BV(PD6) | _BV(PD7)) | |
58 | #define PWM2_SHIFT 5 | |
59 | ||
60 | /* min brightness level */ | |
61 | #define PWM_MIN_BRIGHTNESS 10 | |
62 | ||
63 | /* configure maximal static program parameter size */ | |
64 | #define PROGRAM_PARAMETER_SIZE 10 | |
65 | ||
66 | /* number of color-configurations stored in EEPROM */ | |
67 | #define CONFIG_EEPROM_COLORS 60 | |
68 | ||
69 | /* define default supported number of tasks */ | |
70 | #define CONFIG_SCRIPT_TASKS 1 | |
71 | ||
72 | /* configure INT line for remote */ | |
73 | #define REMOTE_INT_PORT D | |
74 | #define REMOTE_INT_PIN PD2 | |
75 | ||
ec1bef8e | 76 | /* configure storage bufer size */ |
77 | #define STORAGE_BUFFER_SIZE 13 | |
78 | ||
79 | #endif /* _FNORDLICHT_CONFIG_H */ |