STM32-14-中断9_15方式的声光报警器

lemon Lv5

1.代码

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "stm32f10x.h"
#include "stm32f10x_it.h"
#include "sys.h"
#include "Delay.h"
#include "led.h"
#include "key.h"
#include "exit.h"
#include "alarm.h"

volatile u8 alarm_enabled = 0;

int main(void)
{
LED_Init();
KEY_Init();
EXTI_Config();

while(1)
{
Alarm();
}
}

2.模拟图

a


代码下载链接(123云盘):https://www.123684.com/s/wFuijv-i8Zgh

  • 标题: STM32-14-中断9_15方式的声光报警器
  • 作者: lemon
  • 创建于 : 2025-07-22 23:12:32
  • 更新于 : 2025-07-23 00:10:40
  • 链接: https://lemon2003.github.io/post/20250722231232.html
  • 版权声明: 本文章采用 CC BY-NC-SA 4.0 进行许可。
评论
目录
STM32-14-中断9_15方式的声光报警器