123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207 |
- /*
- * File: BCU.h
- *
- * Code generated for Simulink model 'BCU'.
- *
- * Model version : 1.13
- * Simulink Coder version : 9.4 (R2020b) 29-Jul-2020
- * C/C++ source code generated on : Thu Aug 12 17:54:42 2021
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
- #ifndef RTW_HEADER_BCU_h_
- #define RTW_HEADER_BCU_h_
- #ifndef BCU_COMMON_INCLUDES_
- #define BCU_COMMON_INCLUDES_
- #include "rtwtypes.h"
- #include "commontypedef.h"
- #include "AppSignal.h"
- #endif /* BCU_COMMON_INCLUDES_ */
- #include "BCU_types.h"
- #define PROC_BCU_TASK_STACK_SIZE (2048)
- typedef enum
- {
- PROCESS_STATE_INIT = 0,
- PROCESS_STATE_IDLE,
- PROCESS_STATE_WORK,
- PROCESS_STATE_SLEEP
- }process_Bcu;
- /* Child system includes */
- #include "SOH.h"
- #include "SOC.h"
- #include "BLC.h"
- /* Macros for accessing real-time model data structure */
- #ifndef rtmGetErrorStatus
- #define rtmGetErrorStatus(rtm) ((rtm)->errorStatus)
- #endif
- #ifndef rtmSetErrorStatus
- #define rtmSetErrorStatus(rtm, val) ((rtm)->errorStatus = (val))
- #endif
- #ifndef rtmGetErrorStatusPointer
- #define rtmGetErrorStatusPointer(rtm) ((const char_T **)(&((rtm)->errorStatus)))
- #endif
- /* Block states (default storage) for system '<Root>' */
- typedef struct {
- MdlrefDW_SOH_T SOH_InstanceData; /* '<Root>/SOH' */
- MdlrefDW_SOC_T SOC_InstanceData; /* '<Root>/SOC' */
- MdlrefDW_BLC_T BLC_InstanceData; /* '<Root>/BLC' */
- } DW_BCU_T;
- /* Real-time Model Data Structure */
- struct tag_RTM_BCU_T {
- const char_T *errorStatus;
- };
- /* Block states (default storage) */
- extern DW_BCU_T BCU_DW;
- /* Model entry point functions */
- extern void BCU_initialize(void);
- extern void BCU_step(void);
- extern void BCU_terminate(void);
- /* Exported data declaration */
- /* Declaration for custom storage class: ExportToFile */
- extern uint16_T blcv_Q_reqCpEi[28]; /* '<Root>/blcv_Q_reqCpEi' */
- /* ������������ ��ȡ�������飩�� */
- extern uint16_T blcv_Q_reqCpEo[28]; /* '<Root>/BLC' */
- /* ������������ д���������飩�� */
- extern uint32_T blcv_Q_totalCpEi[28]; /* '<Root>/blcv_Q_totalCpEi' */
- /* �ۼƾ������� ��ȡ�������飩�� */
- extern uint32_T blcv_Q_totalCpEo[28]; /* '<Root>/BLC' */
- /* �ۼƾ������� д���������飩�� */
- extern boolean_T blcv_flg_excute[28]; /* '<Root>/BLC' */
- /* ����ִ�������־λ �����飩 */
- extern int16_T ihd_I_curr; /* '<Root>/ihd_I_curr' */
- /* ��ذ������� */
- extern int16_T ihd_T_bdtemp; /* '<Root>/Constant' */
- extern int16_T ihd_T_modTMax; /* '<Root>/ihd_T_modTMax' */
- /* ģ���¶���� */
- extern int16_T ihd_T_modTMin; /* '<Root>/ihd_T_modTMin' */
- /* ģ���¶���С */
- extern uint16_T ihd_V_cellUAvrg; /* '<Root>/ihd_V_cellUAvrg' */
- /* ��ص����ѹƽ���� */
- extern uint16_T ihd_V_cellUMax; /* '<Root>/ihd_V_cellUMax' */
- /* ��ص����ѹ��� */
- extern uint16_T ihd_V_cellUMin; /* '<Root>/ihd_V_cellUMin' */
- /* ��ص����ѹ��С�� */
- extern uint8_T ihd_st_fault; /* '<Root>/ihd_st_fault' */
- /* ���ϵȼ� */
- extern uint8_T ihd_st_workStat; /* '<Root>/ihd_st_workStat' */
- /* ��ع���״̬�� */
- extern uint32_T ihd_tm_parkTime; /* '<Root>/ihd_tm_packTime' */
- /* פ��ʱ�䣻 */
- extern int16_T ihv_T_modT[6]; /* '<Root>/ihv_T_modT' */
- /* ģ���¶ȣ����飩 */
- extern uint16_T ihv_V_cellU[28]; /* '<Root>/ihv_V_cellU' */
- /* ��ص����ѹ�����飩�� */
- extern uint16_T socd_pct_ahSoc; /* '<Root>/SOC' */
- /* ��ʱSOC�� */
- extern uint16_T socd_pct_battSoc; /* '<Root>/SOC' */
- /* �����ʵSOC�� */
- extern uint16_T socd_pct_battSocEi; /* '<Root>/socd_pct_battSocEi' */
- /* �����ʵSOC ��ȡ���� */
- extern uint16_T socd_pct_battSocEo; /* '<Root>/SOC' */
- /* �����ʵSOC д������ */
- extern uint16_T socd_pct_bcuSoc; /* '<Root>/SOC' */
- /* �����ʾSOC�� */
- extern uint16_T socd_pct_bcuSocEi; /* '<Root>/socd_pct_bcuSocEi' */
- /* �����ʾSOC��ȡ���� */
- extern uint16_T socd_pct_bcuSocEo; /* '<Root>/SOC' */
- /* �����ʾSOCд������ */
- extern uint16_T sohd_Q_chrgEi; /* '<Root>/sohd_Q_chrgEi ' */
- /* ����������ȡ���� */
- extern uint16_T sohd_Q_chrgEo; /* '<Root>/SOH' */
- /* ������������� */
- extern boolean_T sohd_flg_chrgEndEi; /* '<Root>/sohd_flg_chrgEndEi ' */
- /* ��������־λ��ȡ���� */
- extern boolean_T sohd_flg_chrgEndEo; /* '<Root>/SOH' */
- /* ��������־λд������ */
- extern uint16_T sohd_pct_bcuSoh; /* '<Root>/SOH' */
- /* ���SOH�� */
- extern uint16_T sohd_tm_chrgStartStatEi;/* '<Root>/sohd_tm_chrgStartStatEi ' */
- /* ���ǰ����ʱ���ȡ���� */
- extern uint16_T sohd_tm_chrgStartStatEo;/* '<Root>/SOH' */
- /* ���ǰ����ʱ��д������ */
- extern uint16_T sohv_Q_cellCap[28]; /* '<Root>/SOH' */
- /* ������������� */
- extern uint16_T sohv_Q_packCapArrEi[10];/* '<Root>/sohv_Q_packCapArrEi ' */
- /* 10���������������飩��ȡ���� */
- extern uint16_T sohv_Q_packCapArrEo[10];/* '<Root>/SOH' */
- /* 10���������������飩д������ */
- extern uint16_T sohv_V_chrgStartStatEi[28];/* '<Root>/sohv_V_chrgStartStatEi ' */
- /* ��翪ʼʱ�̵ĵ����ѹ�����飩��ȡ���� */
- extern uint16_T sohv_V_chrgStartStatEo[28];/* '<Root>/SOH' */
- /* ��翪ʼʱ�̵ĵ����ѹ�����飩д������ */
- /* Real-time Model object */
- extern RT_MODEL_BCU_T *const BCU_M;
- /*-
- * The generated code includes comments that allow you to trace directly
- * back to the appropriate location in the model. The basic format
- * is <system>/block_name, where system is the system number (uniquely
- * assigned by Simulink) and block_name is the name of the block.
- *
- * Use the MATLAB hilite_system command to trace the generated code back
- * to the model. For example,
- *
- * hilite_system('<S3>') - opens system 3
- * hilite_system('<S3>/Kp') - opens and selects block Kp which resides in S3
- *
- * Here is the system hierarchy for this model
- *
- * '<Root>' : 'BCU'
- */
- #endif /* RTW_HEADER_BCU_h_ */
- /*
- * File trailer for generated code.
- *
- * [EOF]
- */
|