Line 1... |
Line 1... |
1 |
/**** IR Mrakomer 4 ****/ |
1 |
/**** IR Mrakomer 4 ****/ |
2 |
#define VERSION "4.0" |
2 |
#define VERSION "4.0" |
3 |
#define ID "$Id: irmrak4.c 1286 2009-01-08 00:34:14Z kakl $" |
3 |
#define ID "$Id: irmrak4.c 1287 2009-01-08 12:54:40Z kakl $" |
4 |
#include "irmrak4.h" |
4 |
#include "irmrak4.h" |
5 |
|
5 |
|
6 |
#define MAXHEAT 20 // Number of cycles for heating |
6 |
#define MAXHEAT 20 // Number of cycles for heating |
7 |
#define MAXOPEN 20 // Number of cycles for dome open |
7 |
#define MAXOPEN 20 // Number of cycles for dome open |
8 |
#define MEASURE_DELAY 10000 // Delay to a next measurement |
8 |
#define MEASURE_DELAY 6000 // Delay to a next measurement |
9 |
#define RESPONSE_DELAY 100 // Reaction time after receiving a command |
9 |
#define RESPONSE_DELAY 100 // Reaction time after receiving a command |
10 |
#define SAFETY_COUNT 100 // Time of one emergency cycle |
10 |
#define SAFETY_COUNT 90 // Time of one emergency cycle |
11 |
#define SEND_DELAY 50 // Time between two characters on RS232 |
11 |
#define SEND_DELAY 50 // Time between two characters on RS232 |
12 |
|
12 |
|
13 |
#define DOME PIN_B4 // Dome controll port |
13 |
#define DOME PIN_B4 // Dome controll port |
14 |
#define HEATING PIN_B3 // Heating for defrosting |
14 |
#define HEATING PIN_B3 // Heating for defrosting |
15 |
|
15 |
|
Line 179... |
Line 179... |
179 |
case 'l': |
179 |
case 'l': |
180 |
open=0; // Lock the dome |
180 |
open=0; // Lock the dome |
181 |
break; |
181 |
break; |
182 |
|
182 |
|
183 |
case 'i': |
183 |
case 'i': |
184 |
welcome(); // Information about version, etc... |
184 |
if (open==0) welcome(); // Information about version, etc... |
185 |
break; |
185 |
break; // Only when dome is closed |
186 |
} |
186 |
} |
187 |
} |
187 |
} |
188 |
|
188 |
|
189 |
seq++; // Increment the number of measurement |
189 |
seq++; // Increment the number of measurement |
190 |
|
190 |
|