/**
@page USART_Printf USART_Printf
@verbatim
************************ Portions COPYRIGHT 2011 STMicroelectronics **********
* @file USART_Printf/readme.txt
* @author MCD Application Team
* @version V1.0.0
* @date 30-September-2011
* @brief Description of the USART Printf 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
*/
/**
@page USART_Printf USART_Printf
@verbatim
****************** Portions COPYRIGHT 2012 Embest Tech. Co., Ltd.*************
* @file readme.txt
* @author CMP Team
* @version V1.0.0
* @date 28-December-2012
* @brief Description of the USART Printf Example.
* Modified to support the STM32F4DISCOVERY and STM32F4DIS-BB modules.
******************************************************************************
* @attention
*
* 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, Embest 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 shows how to retarget the C library printf function to the USART.
This implementation output the printf message on the Hyperterminal using USART6.
The USARTx is configured as follow:
- BaudRate = 115200 baud
- Word Length = 8 Bits
- One Stop Bit
- No parity
- Hardware flow control disabled (RTS and CTS signals)
- Receive and transmit enabled
@par Directory contents
- "inc": contains the project firmware header files
- inc/stm32f4xx_conf.h Library Configuration file
- inc/stm32f4xx_it.h Interrupt handlers header file
- "src": contains the project firmware source files
- src/system_stm32f4xx.c STM32F4xx system clock configuration file
- src/stm32f4xx_it.c Interrupt handlers
- src/main.c Main program
@note The "system_stm32f4xx.c" is generated by an automatic clock configuration
tool and can be easily customized to your own configuration.
To select different clock setup, use the "STM32F4xx_Clock_Configuration_V1.0.0.xls"
provided with the AN3988 package available on <a href="http://www.st.com/internet/mcu/family/141.jsp"> ST Microcontrollers </a>
@par Hardware and Software environment
- This example has been tested with the following environment:
- STM32F4DISCOVERY board
- STM32F4DIS-BB for the Base Board
- Hyperterminal
- Software development tools
- EWARM V6.40
- MDK-ARM V4.60
- Hardware Set-up
- Mount STM32F4DISCOVERY board onto STM32F4DIS-BB board through CON1 and CON2
- Connect a null-modem female/female RS232 cable between the DB9 connector COM1 (USART6) and PC serial port
@note Make sure that jumper
JP1: ON
JP2: ON
- Connect the STM32F4DISCOVERY board to a PC with a 'USB type A to Mini-B' cable
through USB connector CN1 to power the board.
- Hyperterminal configuration:
- Word Length = 8 Bits
- One Stop Bit
- No parity
- BaudRate = 115200 baud
- flow control: None
@par How to use it ?
In order to load the Project code, you have do the following:
- EWARM
- Open the Project.eww workspace
- Rebuild all files: Project->Rebuild all
- Load project image: Project->Debug
- Run program: Debug->Go(F5)
- MDK-ARM
- Open the Project.uvproj project
- Rebuild all files: Project->Rebuild all target files
- Load project image: Debug->Start/Stop Debug Session
- Run program: Debug->Run (F5)
/*********** Portions COPYRIGHT 2012 Embest Tech. Co., Ltd.*****END OF FILE****/
评论1