增加定时器中断,提高定时精度

This commit is contained in:
2024-01-15 20:30:02 +08:00
parent a46186cd18
commit 6094aff6c1
4 changed files with 68 additions and 26 deletions

12
include/time0.h Normal file
View File

@ -0,0 +1,12 @@
#ifndef _time0_H
#define _time0_H
#include "public.h"
//定义LED1管脚
#define LED1 P2_0
//函数声明
void time0_init(void);
#endif

View File

@ -17,6 +17,6 @@ extern __bit busy;
void uart_init(u8 baud);
void send_string(char *s);
void send_data(u8 dat);
int putchar(char c);
int putchar(char c);
#endif