tmp commit

Signed-off-by: liangkangnan <liangkangnan@163.com>
pull/4/head
liangkangnan 2021-08-10 11:26:46 +08:00
parent ad5adcb843
commit 79f83c1ad4
2 changed files with 3 additions and 1 deletions

View File

@ -6,7 +6,7 @@ RISCV_MCMODEL := medlow
TARGET = timer
#CFLAGS += -DSIMULATION
CFLAGS += -DSIMULATION
#CFLAGS += -Os
#ASM_SRCS +=
#LDFLAGS +=

View File

@ -17,6 +17,7 @@ int main()
timer0_clear_int_pending();
timer0_set_int_enable(1);
timer0_set_mode_auto_reload();
rvic_set_irq_prio_level(0, 1);
global_irq_enable();
rvic_irq_enable(0);
timer0_start(1);
@ -37,6 +38,7 @@ int main()
timer0_clear_int_pending();
timer0_set_int_enable(1);
timer0_set_mode_auto_reload();
rvic_set_irq_prio_level(0, 1);
global_irq_enable();
rvic_irq_enable(0);
timer0_start(1);