实验目的:测试bxCAN能否正常进入和退出初始化模式,相应寄存器位MCR_INRQ是否正常置位与复位
实验原理:通过设置CAN_MCR寄存器的INRQ位为1,请求bxCAN进入初始化模式,观察CAN_MSR寄存器的INAK位,置1
则表示成功进入初始化模式;
清除CAN_MCR寄存器的INRQ位为0,请求bxCAN退出初始化模式,观察CAN_MSR寄存器的INAK位,清0
则表示成功退出初始化模式。
硬件环境:回环模式下的单板测试,不需要额外接线
实验步骤:1. 进入Debug模式
2.找到第104行的CAN_Init()函数,Go To Definition进入函数体
3.在函数体所在文件的第179行与第264行打入断点
4.点击全速运行,此时程序运行到第一个断点,观察现象
5.再次点击全速运行,运行到第二个断点,观察现象
6.复位并退出Debug模式,结束
实验现象:运行到第一个断点时,观察到CAN_MCR的INRQ位置1,同时CAN_MSR的INAK位硬件置1,表示成功进入初始化模式;
运行到第二个断点时,INRQ与INAK清0,证明已退出初始化模式。
没有合适的资源?快使用搜索试试~ 我知道了~
资源详情
资源评论
资源推荐
收起资源包目录
V01_CAN的初始化 (153个子文件)
RS422.axf 262KB
RS422_sct.Bak 479B
stm32f10x_tim.c 107KB
stm32f10x_flash.c 61KB
stm32f10x_rcc.c 50KB
stm32f10x_adc.c 46KB
stm32f10x_i2c.c 45KB
stm32f10x_can.c 44KB
stm32f10x_usart.c 37KB
system_stm32f10x.c 36KB
system_stm32f10x.c 36KB
stm32f10x_fsmc.c 35KB
stm32f10x_spi.c 30KB
stm32f10x_dma.c 29KB
stm32f10x_sdio.c 28KB
stm32f10x_gpio.c 23KB
stm32f10x_dac.c 19KB
core_cm3.c 17KB
stm32f10x_cec.c 11KB
stm32f10x_pwr.c 9KB
stm32f10x_rtc.c 8KB
stm32f10x_bkp.c 8KB
stm32f10x_misc.c 7KB
stm32f10x_exti.c 7KB
main.c 7KB
stm32f10x_wwdg.c 6KB
stm32f10x_dbgmcu.c 5KB
stm32f10x_iwdg.c 5KB
stm32f10x_it.c 4KB
stm32f10x_crc.c 3KB
can.c 2KB
stm32f10x_can.crf 350KB
stm32f10x_rcc.crf 348KB
stm32f10x_usart.crf 347KB
stm32f10x_gpio.crf 345KB
main.crf 343KB
system_stm32f10x.crf 343KB
stm32f10x_exti.crf 342KB
stm32f10x_misc.crf 341KB
can.crf 341KB
stm32f10x_it.crf 341KB
core_cm3.crf 4KB
stm32f10x_usart.d 3KB
stm32f10x_gpio.d 3KB
stm32f10x_exti.d 3KB
stm32f10x_misc.d 3KB
stm32f10x_can.d 3KB
stm32f10x_rcc.d 3KB
system_stm32f10x.d 3KB
stm32f10x_it.d 3KB
can.d 2KB
main.d 2KB
core_cm3.d 134B
startup_stm32f10x_hd.d 120B
RS422_STM32F103ZE.dbgconf 7KB
RS422_STM32F103ZE_1.0.0.dbgconf 2KB
RS422_MODULE_RS422.dep 26KB
License.doc 39KB
stm32f10x.h 619KB
core_cm3.h 84KB
stm32f10x_tim.h 51KB
stm32f10x_rcc.h 30KB
stm32f10x_i2c.h 29KB
stm32f10x_can.h 27KB
stm32f10x_fsmc.h 26KB
stm32f10x_flash.h 25KB
stm32f10x_sdio.h 21KB
stm32f10x_adc.h 21KB
stm32f10x_dma.h 20KB
stm32f10x_gpio.h 20KB
stm32f10x_spi.h 17KB
stm32f10x_usart.h 16KB
stm32f10x_dac.h 15KB
misc.h 9KB
stm32f10x_bkp.h 7KB
stm32f10x_exti.h 7KB
stm32f10x_cec.h 6KB
stm32f10x_pwr.h 4KB
stm32f10x_rtc.h 4KB
stm32f10x_iwdg.h 4KB
stm32f10x_dbgmcu.h 4KB
stm32f10x_conf.h 3KB
stm32f10x_wwdg.h 3KB
stm32f10x_crc.h 2KB
system_stm32f10x.h 2KB
stm32f10x_it.h 2KB
can.h 101B
RS422_MODULE.uvguix.HC 179KB
RS422.hex 8KB
RS422_MODULE.uvguix.hp 140KB
CMSIS_Core.htm 56KB
RS422.htm 34KB
CMSIS_changes.htm 12KB
CMSIS debug support.htm 9KB
RS422.build_log.htm 2KB
Release_Notes.html 29KB
Release_Notes.html 26KB
ExtDll.iex 19B
JLinkSettings.ini 671B
RS422.lnp 563B
共 153 条
- 1
- 2
A_Alinlin
- 粉丝: 0
- 资源: 5
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
评论0