Line 1... |
Line 1... |
1 |
/**** IR Mrakomer3 ****/ |
1 |
/**** IR Mrakomer3 ****/ |
2 |
#define VERSION "3.1" |
2 |
#define VERSION "3.1" |
3 |
#define ID "$Id: irmrak3.c 1084 2008-02-23 18:35:46Z kakl $" |
3 |
#define ID "$Id: irmrak3.c 1138 2008-05-19 14:50:14Z kakl $" |
4 |
#include "irmrak3.h" |
4 |
#include "irmrak3.h" |
5 |
|
5 |
|
6 |
#define SA 0x00 // Slave Address (0 for single slave / 0x5A<<1 default) |
6 |
#define SA 0x00 // Slave Address (0 for single slave / 0x5A<<1 default) |
7 |
#define RAM_Access 0x00 // RAM access command |
7 |
#define RAM_Access 0x00 // RAM access command |
8 |
#define RAM_Tobj1 0x07 // To1 address in the eeprom |
8 |
#define RAM_Tobj1 0x07 // To1 address in the eeprom |
Line 145... |
Line 145... |
145 |
setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1); |
145 |
setup_timer_0(RTCC_INTERNAL|RTCC_DIV_1); |
146 |
setup_timer_1(T1_DISABLED); |
146 |
setup_timer_1(T1_DISABLED); |
147 |
setup_timer_2(T2_DISABLED,0,1); |
147 |
setup_timer_2(T2_DISABLED,0,1); |
148 |
setup_comparator(NC_NC_NC_NC); |
148 |
setup_comparator(NC_NC_NC_NC); |
149 |
setup_vref(FALSE); |
149 |
setup_vref(FALSE); |
- |
|
150 |
// setup_oscillator(OSC_4MHZ|OSC_INTRC,+2); // Pokud je nutna kalibrace RCosc |
150 |
setup_oscillator(OSC_4MHZ|OSC_INTRC,+2); |
151 |
setup_oscillator(OSC_4MHZ|OSC_INTRC); |
151 |
|
152 |
|
152 |
delay_ms(1000); |
153 |
delay_ms(1000); |
153 |
printf("\n\r* Mrakomer %s (C) 2007 KAKL *\n\r",VER); // Welcome message |
154 |
printf("\n\r* Mrakomer %s (C) 2007 KAKL *\n\r",VER); // Welcome message |
154 |
printf("* %s *\n\r",REV); |
155 |
printf("* %s *\n\r",REV); |
155 |
printf("<#seq.> <ambient temp.> <space temp.> <status>\n\r\n\r"); |
156 |
printf("<#seq.> <ambient temp.> <space temp.> <status>\n\r\n\r"); |