>
/ / USART1 Transmitter interrupt service routine [USART1_TXC] void usart1_tx_isr (void)
{(tx_counter1)
{
-tx_counter1;=tx_buffer1 [tx_rd_index1]; (+ + tx_rd_index1 == TX_BUFFER_SIZE1) tx_rd_index1=0;
};
}
/ / Write a character to the USART1 Transmitter buffer
# pragma used + putchar1 (char c)
{(tx_counter1 == TX_BUFFER_SIZE1);
# asm («cli») (tx_counter1 | | ((UCSR1A & DATA_REGISTER_EMPTY) == 0))
{_buffer1 [tx_wr_index1]=c; (+ + tx_wr_index1 == TX_BUFFER_SIZE1) tx_wr_index1=0;
+ + tx_counter1;
}=c;
# asm («sei»)
}
# pragma used-
/ / =====================================
/ / Timer1 output compare A interrupt service routine [TIM1_COMPA] void timer1_compa_isr (void)
{H=0x00; L=0x00; _t1=1;
} [TIM0_COMP] void timer0_comp_isr (void)
{int count=0;=0x00; + +; (time_t0 == count)
{_t0=1;=0;
}
}
/ / =====================================
/ / =====================================
# ifndef _MESSAGE_PC_INCLUDED_
# define _MESSAGE_PC_INCLUDED_
# include
# include
# include
# include
/ / ===================================== int N1; int N2; int N3;
/ / ===================================== iter_Processing_massage_PC1 () ;
/ / ===================================== iter_Processing_massage_PC1 ()
{code_command=getchar1 (); (code_command == 0)
{(25); _us (40);
}
/ / ============================ if (code_command == 1) / /
{DSH1, DSH2, DSH3, DSH4; fD; unsigned int iD; int n, t;=getchar1 ();=getchar1 ();=getchar1 ();=getchar1 ();=getchar1 (); +=getchar1 () * 256;=getchar1 (); +=getchar1 () * 256;
/ / ------------------------- V4s (); (DSH1); (DSH2); (DSH3) ; (DSH4);
/ / ------------------------- _ms (t);
/ / ------------------------- V (1);=mens_adc_U5V4s (n, 1); p>
/ / -------------------------=fD;
/ / ------------------------- (iD); (iD/256); (iD/65536) ; (iD/16777216); V (1); (1);
}
/ / ============================ if (code_command == 2)
{DSH1, DSH2; unsigned int D;=getchar1 ();=getchar1 ();
/ / ------------------------- V2s (); (DSH1 <200)
{(); (DSH1);
}
{(); (DSH1% 200);
} (DSH2 <200)
{(); (DSH2);