资源简介
STM32(神舟III号 串口1发送实验程序)
代码片段和文件信息
/**
******************************************************************************
* @file USART/Printf/main.c
* @author MCD Application Team
* @version V3.3.0
* @date 04/16/2010
* @brief Main program body
******************************************************************************
* @copy
*
* 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.
*
* © COPYRIGHT 2010 STMicroelectronics
*/
/* Includes ------------------------------------------------------------------*/
#include “stm32f10x.h“
#include “stm32_eval.h“
#include
/** @addtogroup STM32F10x_StdPeriph_Examples
* @{
*/
/** @addtogroup USART_Printf
* @{
*/
/* Private typedef -----------------------------------------------------------*/
/*神州III号LED灯相关定义*/
#define RCC_GPIO_LED RCC_APB2Periph_GPIOF /*LED使用的GPIO时钟*/
#define LEDn 4 /*神舟III号LED数量*/
#define GPIO_LED GPIOF /*神舟III号LED灯使用的GPIO组*/
#define DS1_PIN GPIO_Pin_6 /*DS1使用的GPIO管脚*/
#define DS2_PIN GPIO_Pin_7 /*DS2使用的GPIO管脚*/
#define DS3_PIN GPIO_Pin_8 /*DS3使用的GPIO管脚*/
#define DS4_PIN GPIO_Pin_9 /*DS4使用的GPIO管脚*/
/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
USART_InitTypeDef USART_InitStructure;
/* Private function prototypes -----------------------------------------------*/
#ifdef __GNUC__
/* With GCC/RAISONANCE small printf (option LD linker->Libraries->Small printf
set to ‘Yes‘) calls __io_putchar() */
#define PUTCHAR_PROTOTYPE int __io_putchar(int ch)
#else
#define PUTCHAR_PROTOTYPE int fputc(int ch FILE *f)
#endif /* __GNUC__ */
/* Private functions ---------------------------------------------------------*/
/*******************************************************************************
* Function Name : Delay
* Description : Inserts a delay time.
* Input : nCount: specifies the delay time length.
* Output : None
* Return : None
*******************************************************************************/
void Delay(vu32 nCount)
{
for(; nCount != 0; nCount--);
}
/**
* @brief Main pr
- 上一篇:STM32 模拟信号采集
- 下一篇:makefile
相关资源
- STM32 模拟信号采集
- STM32-ads1256
- STM32跑马灯实验58159
- STM32429的串口收发程序
- STM32连接EC20使用内置MQTT协议接入阿里
- ADS1256-STM32参考程序
- stm32 AD7506
- STM32F10实现照相功能照相机
- 基于STM32的嵌入式flash读写控制
- stm32f103c8t6开发板原理图+pcb
- STM32内部FLASH模拟eerom
- stm32的半导体除湿机程序
- stm32实现高精度频率测定
- stm32库函数代码自动生成器V1.2
- stm32 DMA例程
- stm32蓝牙小车
- 显示屏操作(stm32f103c8t6(SAN))
- 基于STM32f103 PWM波呼吸灯
- STM32红外检测有人开始录音,并播放录
- Proteus 8.6仿真STM32F103C6
- stm32 +w5500 裸机 远程升级 自动dns pi
- stm32双机spi通信
- STM32 PCB封装库 全系列 全网不好找
- 基于STM32F407的W5500 tcpserver(官网例程
- 串口调试助手(测试STM32串口)
- 基于STM32F407ZG的监控摄像头及FATFS文件
- tm1650+stm32f103源码(board_tm1650.c)
- stm32定时器中断
- 基于STM32的音频信号采样与FFT分析
- STM32肺活量测试仪
评论
共有 条评论