?? main.c
字號:
#include <inavr.h>
#include "main.h"
#include "USART.h"
#include "SPI_Master.h"
#include "key.h"
#include "time.h"
unsigned char KeyMask=1;
unsigned char KeyClk=0;
int main( void )
{
USART_Init();
SPIInit();
Timer2Init();
PutChar(0xAA);
__enable_interrupt ();
while(1)
{
SampleTimeFlag=0;
if(ReadKey()==1&&KeyMask)
{
KeyMask=0;
PutChar(0x88);
SPIPutChar(0xab);
PutChar(SPIGetChar());
}
if(++KeyClk>100)
{
KeyClk=0;
KeyMask=1;
}
while(!SampleTimeFlag);
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -