comparison libs/STM32F10x_StdPeriph_Lib_V3.5.0/Project/STM32F10x_StdPeriph_Examples/USART/Synchronous/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 USART_Synchronous USART Synchronous example
3
4 @verbatim
5 ******************** (C) COPYRIGHT 2011 STMicroelectronics *******************
6 * @file USART/Synchronous/readme.txt
7 * @author MCD Application Team
8 * @version V3.5.0
9 * @date 08-April-2011
10 * @brief Description of the USART Synchronous 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 provides a basic communication between USARTy (Synchronous mode)
24 and SPIy using flags. USARTy and SPIy can be USART1 and SPI1 or USART2 and SPI3,
25 depending on the STMicroelectronics EVAL board you are using.
26
27 First, the USARTy sends data from TxBuffer1 buffer to SPIy using USARTy TXE flag.
28 Data received, using RXNE flag, by SPIy is stored in RxBuffer2 then compared with
29 the sent ones and the result of this comparison is stored in the "TransferStatus1"
30 variable.
31
32 Then, the SPIy sends data from TxBuffer2 buffer to USARTy using SPIy TXE flag.
33 Data received, using RXNE flag, by USARTy is stored in RxBuffer1 then compared with
34 the sent ones and the result of this comparison is stored in the "TransferStatus2"
35 variable.
36
37 USARTy configured as follow:
38 - BaudRate = 115200 baud
39 - Word Length = 8 Bits
40 - One Stop Bit
41 - No parity
42 - Hardware flow control disabled (RTS and CTS signals)
43 - Receive and transmit enabled
44 - USART Clock enabled
45 - USART CPOL: Clock is active high
46 - USART CPHA: Data is captured on the second edge
47 - USART LastBit: The clock pulse of the last data bit is output to the SCLK pin
48
49 SPIy configured as follow:
50 - Direction = 2 Lines FullDuplex
51 - Mode = Slave Mode
52 - DataSize = 8 Bits
53 - CPOL = Clock is active high
54 - CPHA = Data is captured on the second edge
55 - NSS = NSS Software
56 - First Bit = First Bit is the LSB
57
58
59 @par Directory contents
60
61 - USART/Synchronous/platform_config.h Evaluation board specific configuration file
62 - USART/Synchronous/stm32f10x_conf.h Library Configuration file
63 - USART/Synchronous/stm32f10x_it.h Interrupt handlers header file
64 - USART/Synchronous/stm32f10x_it.c Interrupt handlers
65 - USART/Synchronous/main.c Main program
66 - USART/Synchronous/system_stm32f10x.c STM32F10x system source file
67
68 @par Hardware and Software environment
69
70 - This example runs on STM32F10x Connectivity line, High-Density, High-Density
71 Value line, Medium-Density, XL-Density, Medium-Density Value line, Low-Density
72 and Low-Density Value line Devices.
73
74 - This example has been tested with STMicroelectronics STM32100E-EVAL (High-Density
75 Value line), STM32100B-EVAL (Medium-Density Value line), STM3210E-EVAL
76 (High-Density and XL-Density) and STM3210B-EVAL (Medium-Density) evaluation
77 boards and can be easily tailored to any other supported device and development
78 board.
79 This example can't be tested with STM3210C-EVAL (Connectivity Line) evaluation
80 board since the USART CK pins are already used by other on-board modules.
81 To select the STMicroelectronics evaluation board used to run the example,
82 uncomment the corresponding line in USART/Synchronous/platform_config.h file
83
84 - STM32100E-EVAL Set-up
85 - Connect USART1_Tx(PA.09) to SPI1_MOSI(PA.07), USART1_Rx(PA.10) to
86 SPI1_MISO(PA.06) and USART1_CK(PA.08) to SPI1_SCK(PA.05).
87
88 - STM32100B-EVAL Set-up
89 - Connect USART1_Tx(PA.09) to SPI1_MOSI(PA.07), USART1_Rx(PA.10) to
90 SPI1_MISO(PA.06) and USART1_CK(PA.08) to SPI1_SCK(PA.05).
91
92 - STM3210E-EVAL Set-up
93 - Connect USART1_Tx(PA.09) to SPI1_MOSI(PA.07), USART1_Rx(PA.10) to
94 SPI1_MISO(PA.06) and USART1_CK(PA.08) to SPI1_SCK(PA.05).
95
96 - STM3210B-EVAL Set-up
97 - Connect USART1_Tx(PA.09) to SPI1_MOSI(PA.07), USART1_Rx(PA.10) to
98 SPI1_MISO(PA.06) and USART1_CK(PA.08) to SPI1_SCK(PA.05).
99
100 @par How to use it ?
101
102 In order to make the program work, you must do the following :
103 - Copy all source files from this example folder to the template folder under
104 Project\STM32F10x_StdPeriph_Template
105 - Open your preferred toolchain
106 - Rebuild all files and load your image into target memory
107 - Run the example
108
109 @note
110 - Low-density Value line devices are STM32F100xx microcontrollers where the
111 Flash memory density ranges between 16 and 32 Kbytes.
112 - Low-density devices are STM32F101xx, STM32F102xx and STM32F103xx
113 microcontrollers where the Flash memory density ranges between 16 and 32 Kbytes.
114 - Medium-density Value line devices are STM32F100xx microcontrollers where
115 the Flash memory density ranges between 64 and 128 Kbytes.
116 - Medium-density devices are STM32F101xx, STM32F102xx and STM32F103xx
117 microcontrollers where the Flash memory density ranges between 64 and 128 Kbytes.
118 - High-density Value line devices are STM32F100xx microcontrollers where
119 the Flash memory density ranges between 256 and 512 Kbytes.
120 - High-density devices are STM32F101xx and STM32F103xx microcontrollers where
121 the Flash memory density ranges between 256 and 512 Kbytes.
122 - XL-density devices are STM32F101xx and STM32F103xx microcontrollers where
123 the Flash memory density ranges between 512 and 1024 Kbytes.
124 - Connectivity line devices are STM32F105xx and STM32F107xx microcontrollers.
125
126 * <h3><center>&copy; COPYRIGHT 2011 STMicroelectronics</center></h3>
127 */