📄 pid_reg3.h
字号:
/* =================================================================================
File name: PID_REG3.H (IQ version)
Description:
Header file containing constants, data type definitions, and
function prototypes for the PIDREG3.
=====================================================================================
History:
-------------------------------------------------------------------------------------
05-15-2007 Version 3.20
------------------------------------------------------------------------------*/
#ifndef __PIDREG3_H__
#define __PIDREG3_H__
typedef struct { int Ref; // Input: Reference input
int Fdb; // Input: Feedback input
int Err; // Variable: Error
int Kp; // Parameter: Proportional gain
int Up; // Variable: Proportional output
int Ui; // Variable: Integral output
int Ud; // Variable: Derivative output
int OutPreSat; // Variable: Pre-saturated output
int OutMax; // Parameter: Maximum output
int OutMin; // Parameter: Minimum output
int Out; // Output: PID output
int SatErr; // Variable: Saturated difference
int Ki; // Parameter: Integral gain
int Kc; // Parameter: Integral correction gain
int Kd; // Parameter: Derivative gain
int Up1; // History: Previous proportional output
void (*calc)(); // Pointer to calculation function
} PIDREG3;
typedef PIDREG3 *PIDREG3_handle;
/*-----------------------------------------------------------------------------
Default initalizer for the PIDREG3 object.
-----------------------------------------------------------------------------*/
#define PIDREG3_DEFAULTS { 0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
0, \
(void (*)(int))pid_reg3_calc }
/*------------------------------------------------------------------------------
Prototypes for the functions in PIDREG3.C
------------------------------------------------------------------------------*/
void pid_reg3_calc(PIDREG3_handle);
#endif // __PIDREG3_H__
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -