Mercurial > ~darius > hgwebdir.cgi > stm32temp
comparison libs/STM32F10x_StdPeriph_Lib_V3.5.0/Project/STM32F10x_StdPeriph_Examples/CAN/DualCAN/readme.txt @ 0:c59513fd84fb
Initial commit of STM32 test code.
author | Daniel O'Connor <darius@dons.net.au> |
---|---|
date | Mon, 03 Oct 2011 21:19:15 +1030 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:c59513fd84fb |
---|---|
1 /** | |
2 @page CAN_DualCAN Dual CAN example | |
3 | |
4 @verbatim | |
5 ******************** (C) COPYRIGHT 2011 STMicroelectronics ******************* | |
6 * @file CAN/DualCAN/readme.txt | |
7 * @author MCD Application Team | |
8 * @version V3.5.0 | |
9 * @date 08-April-2011 | |
10 * @brief Description of the Dual CAN example. | |
11 ****************************************************************************** | |
12 * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS | |
13 * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE | |
14 * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY | |
15 * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING | |
16 * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE | |
17 * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS. | |
18 ****************************************************************************** | |
19 @endverbatim | |
20 | |
21 @par Example Description | |
22 | |
23 This example shows how to configure the CAN1 and CAN2 peripherals to send and | |
24 receive CAN frames in normal mode. The sent frames are used to control Leds by | |
25 pressing KEY or TAMPER push buttons: | |
26 - When KEY button is pressed, LED1 is turned ON and CAN1 sends a message to CAN2, | |
27 when CAN2 receives correctly this message LED4 is turned ON. | |
28 - When TAMPER button is pressed, LED2 is turned ON and CAN2 sends a message to CAN1, | |
29 when CAN1 receives correctly this message LED3 is turned ON. | |
30 | |
31 The CAN1 and CAN2 are configured as follow: | |
32 - Bit Rate = 1 Mbit/s | |
33 - CAN Clock = external clock (HSE) | |
34 - ID Filter = All identifiers are allowed | |
35 - RTR = Data | |
36 - DLC = 1 byte | |
37 - Data: Led number that should be turned ON | |
38 @note | |
39 user can select one from the preconfigured CAN baud rates from the private | |
40 defines in main.c by uncommenting the desired define: | |
41 | |
42 @code | |
43 #define CAN_BAUDRATE 1000 /* CAN baudrate = 1MBps */ | |
44 /* #define CAN_BAUDRATE 500*/ /* CAN baudrate = 500kBps */ | |
45 /* #define CAN_BAUDRATE 250*/ /* CAN baudrate = 250kBps */ | |
46 /* #define CAN_BAUDRATE 125*/ /* CAN baudrate = 125kBps */ | |
47 /* #define CAN_BAUDRATE 100*/ /* CAN baudrate = 100kBps */ | |
48 /* #define CAN_BAUDRATE 50*/ /* CAN baudrate = 50kBps */ | |
49 /* #define CAN_BAUDRATE 20*/ /* CAN baudrate = 20kBps */ | |
50 /* #define CAN_BAUDRATE 10*/ /* CAN baudrate = 10kBps */ | |
51 @endcode | |
52 | |
53 @par Directory contents | |
54 | |
55 - CAN/DualCAN/stm32f10x_conf.h Library Configuration file | |
56 - CAN/DualCAN/stm32f10x_it.c Interrupt handlers | |
57 - CAN/DualCAN/stm32f10x_it.h Interrupt handlers header file | |
58 - CAN/DualCAN/main.c Main program | |
59 - CAN/DualCAN/system_stm32f10x.c STM32F10x system source file | |
60 | |
61 @par Hardware and Software environment | |
62 | |
63 - This example runs on STM32F10x Connectivity line Devices. | |
64 | |
65 - This example has been tested with STMicroelectronics STM3210C-EVAL (STM32F10x | |
66 Connectivity line) evaluation board and can be easily tailored to any other | |
67 supported device and development board. | |
68 To select the STMicroelectronics evaluation board used to run the example, | |
69 uncomment the corresponding line in stm32_eval.h file | |
70 | |
71 - STM3210C-EVAL Set-up | |
72 - Use LED1, LED2, LED3 and LED4 connected respectively to PD.07, PD.13, PF.03 | |
73 and PD.04 pins | |
74 - Use Key Push Button connected to PB9 | |
75 - Use Tamper Push Button connected to PC13 | |
76 - Connect a female/female CAN cable between the CAN connectors | |
77 (CN4 and CN3 on STM3210C-EVAL boards) | |
78 - Connector 1 DB9_PIN2 to Connector 2 DB9_PIN2 (CAN_L) | |
79 - Connector 1 DB9_PIN5 to Connector 2 DB9_PIN5 ( GND ) | |
80 - Connector 1 DB9_PIN7 to Connector 2 DB9_PIN7 (CAN_H) | |
81 - JP6 or JP5 must be fitted. | |
82 | |
83 @par How to use it ? | |
84 | |
85 In order to make the program work, you must do the following : | |
86 - Copy all source files from this example folder to the template folder under | |
87 Project\STM32F10x_StdPeriph_Template | |
88 - Open your preferred toolchain | |
89 - Rebuild all files and load your image into target memory | |
90 - Run the example | |
91 | |
92 @note | |
93 - Low-density Value line devices are STM32F100xx microcontrollers where the | |
94 Flash memory density ranges between 16 and 32 Kbytes. | |
95 - Low-density devices are STM32F101xx, STM32F102xx and STM32F103xx | |
96 microcontrollers where the Flash memory density ranges between 16 and 32 Kbytes. | |
97 - Medium-density Value line devices are STM32F100xx microcontrollers where | |
98 the Flash memory density ranges between 64 and 128 Kbytes. | |
99 - Medium-density devices are STM32F101xx, STM32F102xx and STM32F103xx | |
100 microcontrollers where the Flash memory density ranges between 64 and 128 Kbytes. | |
101 - High-density Value line devices are STM32F100xx microcontrollers where | |
102 the Flash memory density ranges between 256 and 512 Kbytes. | |
103 - High-density devices are STM32F101xx and STM32F103xx microcontrollers where | |
104 the Flash memory density ranges between 256 and 512 Kbytes. | |
105 - XL-density devices are STM32F101xx and STM32F103xx microcontrollers where | |
106 the Flash memory density ranges between 512 and 1024 Kbytes. | |
107 - Connectivity line devices are STM32F105xx and STM32F107xx microcontrollers. | |
108 | |
109 * <h3><center>© COPYRIGHT 2011 STMicroelectronics</center></h3> | |
110 */ |