optical/SEW-EXA1/Users/Base/inout.c

83 lines
1.9 KiB
C
Raw Permalink Normal View History

2025-09-04 01:45:08 +00:00
//-------------------------------------------------------------------------------
// File Name: inout.c
// Brief:
// Version: 1.0.0
// Create Date: 2021/07/21
// Create by: Marshal Lee
// Copyright:
// Copyright (c) 2021, Richpeace Co., LTD.
// All rights reserved.
//
// Modify by: Marshal Lee
// Modify Date: 2021/07/21
//-------------------------------------------------------------------------------
#include "inout.h"
#include "funcs.h"
//-------------ͨѶ<CDA8><D1B6><EFBFBD><EFBFBD>-------------------------
OUTPUT_FUNCS(En485Out, RS485_EN); // 485<38><35><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
OUTPUT_FUNCS(En485_2_Out, RS485_2_EN); // 485<38><35><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//-----------------<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ź<EFBFBD>---------------------
// Moto1
OUTPUT_FUNCS(Moto1Step, MT_STEP);
OUTPUT_FUNCS(Moto1Dir, MT_DIR);
OUTPUT_FUNCS(Moto1En, MT_SON);
//-----------------------------------------
INPUT_FUNCS(InputAP,AP);
INPUT_FUNCS(InputBP,BP);
INPUT_FUNCS(InputZP,ZP);
//-----------------<2D><><EFBFBD><EFBFBD><EFBFBD>ź<EFBFBD>---------------------
OUTPUT_FUNCS(SysLed, SYS_LED);
OUTPUT_FUNCS(ErrLed, ERR_LED);
OUTPUT_FUNCS(OutputPWM1, OUTPWM1);
OUTPUT_FUNCS(OutputPWM2, OUTPWM2);
OUTPUT_FUNCS(Output1, OUTPUT1);
OUTPUT_FUNCS(Output2, OUTPUT2);
OUTPUT_FUNCS(Output3, OUTPUT3);
OUTPUT_FUNCS(Output4, OUTPUT4);
OUTPUT_FUNCS(Output5, OUTPUT5);
OUTPUT_FUNCS(Output6, OUTPUT6);
OUTPUT_FUNCS(Output7, OUTPUT7);
OUTPUT_FUNCS(Output8, OUTPUT8);
//-----------------<2D><><EFBFBD><EFBFBD><EFBFBD>ź<EFBFBD>---------------------
INPUT_FUNCS(Input1,INPUT1);
INPUT_FUNCS(Input2,INPUT2);
INPUT_FUNCS(Input3,INPUT3);
INPUT_FUNCS(Input4,INPUT4);
INPUT_FUNCS(Input5,INPUT5);
INPUT_FUNCS(Input6,INPUT6);
INPUT_FUNCS(Input7,INPUT7);
INPUT_FUNCS(Input8,INPUT8);
//-----------------<2D><><EFBFBD><EFBFBD><EBBFAA>---------------------
INPUT_FUNCS(Switch1,SW1);
INPUT_FUNCS(Switch2,SW2);
INPUT_FUNCS(Switch3,SW3);
INPUT_FUNCS(Switch4,SW4);
void SetOutputNull(void)
{
//<2F><><EFBFBD><EFBFBD><EFBFBD>ղ<EFBFBD><D5B2><EFBFBD>
}
u8 GetInputNullOn(void)
{
//<2F><><EFBFBD><EFBFBD><EFBFBD>ղ<EFBFBD><D5B2><EFBFBD>
return Bit_RESET;
}
u8 GetInputNullOff(void)
{
//<2F><><EFBFBD><EFBFBD><EFBFBD>ղ<EFBFBD><D5B2><EFBFBD>
return Bit_SET;
}