stm32+can

所属分类:嵌入式/单片机/硬件编程
开发工具:C/C++
文件大小:3531KB
下载次数:22
上传日期:2017-09-28 11:09:20
上 传 者kaitou
说明:  STM32之can通讯,包含初始化,can中断,发送报文,可以进行报文解析
(STM32 can communication, including initialization, can interrupt, send message, you can parse the message)

文件列表:
stm32 can (0, 2015-11-22)
stm32 can\CAN(主机l) (0, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal).Uv2.bak (3205, 2010-09-16)
stm32 can\CAN(主机l)\CAN(Normal).opt.bak (2502, 2011-03-21)
stm32 can\CAN(主机l)\CAN(Normal).uvgui.Administrator (73357, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal).uvgui_Administrator.bak (72722, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal).uvopt (15356, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal).uvproj (17734, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal)_Opt.Bak (2502, 2011-03-21)
stm32 can\CAN(主机l)\CAN(Normal)_STM32-USART1.dep (9384, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal)_Uv2.Bak (3144, 2010-08-04)
stm32 can\CAN(主机l)\CAN(Normal)_uvopt.bak (13709, 2015-11-22)
stm32 can\CAN(主机l)\CAN(Normal)_uvproj.bak (17907, 2015-11-16)
stm32 can\CAN(主机l)\FWlib (0, 2015-11-22)
stm32 can\CAN(主机l)\FWlib\SRC (0, 2015-11-22)
stm32 can\CAN(主机l)\FWlib\SRC\misc.c (6874, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_adc.c (46634, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_bkp.c (8248, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_can.c (30961, 2015-11-16)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_crc.c (3340, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_dac.c (13723, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_dbgmcu.c (4310, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_dma.c (27362, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_exti.c (6801, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_flash.c (26352, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_fsmc.c (34932, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_gpio.c (17965, 2009-09-04)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_i2c.c (37326, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_iwdg.c (4813, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_pwr.c (8929, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_rcc.c (33782, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_rtc.c (8580, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_sdio.c (28483, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_spi.c (27737, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_tim.c (101890, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_usart.c (34930, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\stm32f10x_wwdg.c (5619, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\SRC\system_stm32f10x.c (24166, 2009-04-06)
stm32 can\CAN(主机l)\FWlib\inc (0, 2015-11-22)
stm32 can\CAN(主机l)\FWlib\inc\misc.h (4951, 2009-04-06)
... ...

/** @page CAN_LoopBack CAN_LoopBack @verbatim ******************** (C) COPYRIGHT 2009 STMicroelectronics ******************* * @file CAN/LoopBack/readme.txt * @author MCD Application Team * @version V3.0.0 * @date 04/06/2009 * @brief Description of the CAN example. ****************************************************************************** * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS. ****************************************************************************** @endverbatim @par Example Description This example provides a description of how to set a communication with the bxCAN in loopback mode. The CAN cell first performs a transmission and a reception of a standard data frame by polling at 100 Kbits/s. The received frame is checked and some LEDs light up to indicate whether the communication was successful. Then, an extended data frame is transmitted at 500 Kbits/s. Reception is done in the interrupt handler when the message becomes pending in the FIFO. Finally, the LEDs indicate if both transmission and reception have been successful. @par Directory contents - CAN/LoopBack/platform_config.h Hardware configuration header file - CAN/LoopBack/stm32f10x_conf.h Library Configuration file - CAN/LoopBack/stm32f10x_it.c Interrupt handlers - CAN/LoopBack/stm32f10x_it.h Interrupt handlers header file - CAN/LoopBack/main.c Main program @par Hardware and Software environment - This example runs on STM32F10x High-Density, STM32F10x Medium-Density and STM32F10x Low-Density Devices. - This example has been tested with STMicroelectronics STM3210E-EVAL (STM32F10x High-Density) and STM3210B-EVAL (STM32F10x Medium-Density) evaluation boards and can be easily tailored to any other supported device and development board. To select the STMicroelectronics evaluation board used to run the example, uncomment the corresponding line in platform_config.h file. - STM3210E-EVAL Set-up - Use LD1, LD2, LD3 and LD4 leds connected respectively to PF.06, PF0.7, PF.08 and PF.09 pins - STM3210B-EVAL Set-up - Use LD1, LD2, LD3 and LD4 leds connected respectively to PC.06, PC.07, PC.08 and PC.09 pins @par How to use it ? In order to make the program work, you must do the following : - Create a project and setup all project configuration - Add the required Library files : - stm32f10x_can.c - stm32f10x_rcc.c - stm32f10x_gpio.c - misc.c - system_stm32f10x.c - Edit stm32f10x.h file to select the device you are working on. @b Tip: You can tailor the provided project template to run this example, for more details please refer to "stm32f10x_stdperiph_lib_um.chm" user manual; select "Peripheral Examples" then follow the instructions provided in "How to proceed" section. - Link all compiled files and load your image into target memory - Run the example @note - Low-density devices are STM32F101xx and STM32F103xx microcontrollers where the Flash memory density ranges between 16 and 32 Kbytes. - Medium-density devices are STM32F101xx and STM32F103xx microcontrollers where the Flash memory density ranges between 32 and 128 Kbytes. - High-density devices are STM32F101xx and STM32F103xx microcontrollers where the Flash memory density ranges between 256 and 512 Kbytes. *

© COPYRIGHT 2009 STMicroelectronics

*/

近期下载者

相关文件


收藏者