Лампы синхронизированы с внешним управлением
This commit is contained in:
@@ -58,7 +58,7 @@ interrupt void cpu_timer1_isr_SENS()
|
||||
blink_over, blink_alarm, work_lamp, heat_lamp;
|
||||
|
||||
int TST;
|
||||
static int preTest;
|
||||
static int preTest,preLite1,preLite2;
|
||||
|
||||
EALLOW;
|
||||
CpuTimer1.InterruptCount++;
|
||||
@@ -96,12 +96,14 @@ interrupt void cpu_timer1_isr_SENS()
|
||||
if(count_bright == Bright[1]) clear_LED_OUT_2();
|
||||
}
|
||||
|
||||
if(TST & !preTest)
|
||||
{
|
||||
count_blink = BLINK_TIME;
|
||||
count_mode = 0;
|
||||
}
|
||||
preTest = TST;
|
||||
if(TST!=preTest||preLite1!=Light[0]||preLite2!=Light[1])
|
||||
{
|
||||
count_blink = BLINK_TIME;
|
||||
count_mode = 0;
|
||||
}
|
||||
preTest = TST;
|
||||
preLite1 = Light[0];
|
||||
preLite2 = Light[1];
|
||||
|
||||
if(++count_blink >= BLINK_TIME)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user