当前位置:网站首页>STM32 personal notes - program run and fly
STM32 personal notes - program run and fly
2022-08-01 09:48:00 【Couvrir wild beast】
Part of the notes are from the public account of "STM32 Embedded Development".
Program running score
Number out of bounds/overflow
Phenomena: When the microcontroller program runs in a function, it always runs to the end of the function, and when it wants to jump out of the function, the program runs away.
Cause: Array out of range (array overflow).such as
uint8_t ucDataBuff[10]={0};ucDataBuff[10]=0x1;Solution: When debugging the program, if you find that the program always runs away when the function is executed, in most cases an array out-of-bounds (array overflow) error has occurred. Carefully check whether the array called in the function is out-of-bounds (overflow).)Case.
Interrupt service function is missing
Phenomena: The program always runs away during the running process.
Cause: An interrupt is enabled in the program, but there is no corresponding interrupt service routine, so that after the interrupt occurs, the entry of the interrupt service routine cannot be found, resulting in the program running away.
Solution: Check whether there is an interrupt turned on in the program, but there is no corresponding interrupt service routine.
Watchdog reset
Phenomena: When executing a relatively time-consuming program, the program runs away and always jumps to the reset position.
Reason: The watchdog is used in the program, but the dog is not fed in time, which causes the watchdog to reset and the program jumps directly to the reset position.
Solution: According to the running time of the program, especially the running time of the most time-consuming part of the program must be calculated, and then accurately set the reset time of the watchdog, and feed the dog regularly.Especially if there is an infinite loop, be sure to remember to feed the dog in the infinite loop.
边栏推荐
- sqlserver怎么查询一张表中同人员的交叉日期
- JVM 运行时数据区与JMM 内存模型详解
- Parsing MySQL Databases: "SQL Optimization" vs. "Index Optimization"
- net stop/start mysql80 access denied
- Change Servlet project to SSM project
- What are the common API security flaws?
- [Interview: Concurrency 39: Multithreading: Thread Pool] ThreadPoolExecutor Class - Submit, Stop
- 如何保证数据库与缓存数据一致性?
- Prime Ring Problem(素数环问题)
- 【面试:并发篇39:多线程:线程池】ThreadPoolExecutor类-提交、停止
猜你喜欢

Message queue interview latest finishing (2022)

Redis learning

What's up with VS "Cannot find or open PDB file"?How to solve

【数据集】各类绝缘子、鸟巢及防震锤数据集汇总

Detailed explanation of JVM runtime data area and JMM memory model

已解决(pip安装库报错)Consider using the-- user option or check the permissions.

WLAN networking experiment of AC and thin AP

Visualization - Superset installation and deployment

Comprehensive experiment BGP

AC与瘦AP的WLAN组网实验
随机推荐
URL.createObjectURL、URL.revokeObjectURL、Uint8Array、Blob使用详解
experiment....
ACmix 论文精读,并解析其模型结构
报告:想学AI的学生数量已涨200%,老师都不够用了
TiDB的真实数据库数据是存在kv和还是pd上?
Quantify daily work metrics
Get the Token from the revised version of Qubutu Bed
Introduction to ADAS
MySQL query advanced - from the use of functions to table joins, do you remember?
堆内存的介绍及应用(含例子)
ASP.NET Core 6框架揭秘实例演示[30]:利用路由开发REST API
How to query database configuration parameters in GBase 8c, such as datestyle
AI篮球裁判火了,走步算得特别准,就问哈登慌不慌
编码解码(btoa、encodeURIComponent、encodeURI、escape)
阿里腾讯面试一二
HoloView——实时数据
scrapy爬虫框架的使用
Shell:条件测试操作
How to get page data
Node's traditional and advanced practices for formatting time (moment)