Files
TXH1.0/User/Pulse_PutOut/Pluse_Putout.c
T
2026-04-27 16:55:02 +08:00

44 lines
1.4 KiB
C
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#include "config.h"
/****************************************************
函数名:Pluse_Putout_IO_Configuration
功能 Pluse_Putout部分用到的IO初始化
参数 :无
返回值:无
****************************************************/
void Pluse_Putout_IO_Configuration(void)
{
GPIO_InitTypeDef GPIO_InitStructure; //定义GOIP配置结构体
RCC_AHB1PeriphClockCmd(RCC_AHB1Periph_GPIOA | RCC_AHB1Periph_GPIOE, ENABLE);
GPIO_InitStructure.GPIO_Pin = GPIO_Pin_2 | GPIO_Pin_14 | GPIO_Pin_15;
GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT;//普通输出模式
GPIO_InitStructure.GPIO_OType = GPIO_OType_PP;//推挽输出
GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz;//100MHz
GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP;//上拉
GPIO_Init(GPIOE, &GPIO_InitStructure);
GPIO_ResetBits(GPIOE,GPIO_Pin_2);
if(TXHData.POS_Info.NetType == POS_Net_Typ_WAN || TXHData.POS_Info.NetType == POS_Net_Typ_4G_L510)
{
GPIO_InitStructure.GPIO_Pin = GPIO_Pin_2;
GPIO_InitStructure.GPIO_Mode = GPIO_Mode_OUT;//普通输出模式
GPIO_InitStructure.GPIO_OType = GPIO_OType_PP;//推挽输出
GPIO_InitStructure.GPIO_Speed = GPIO_Speed_100MHz;//100MHz
GPIO_InitStructure.GPIO_PuPd = GPIO_PuPd_UP;//上拉
GPIO_Init(GPIOA, &GPIO_InitStructure);
GPIO_ResetBits(GPIOA,GPIO_Pin_2);
}
Valve1 = SWF_OFF;
Valve2 = SWF_OFF;
}
void Pluse_Putout_Init(void)
{
Pluse_Putout_IO_Configuration();
}
void Pluse_PutoutTast(void)
{
u8 Buff[20];
}