⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sysmon.h

📁 IT projecotr reference design.
💻 H
字号:
/****************************************************************************/
/*             TEXAS INSTRUMENTS PROPRIETARY INFORMATION                    */
/*                                                                          */
/*  (c) Copyright, Texas Instruments Incorporated, 2006.                    */
/*      All Rights Reserved.                                                */
/*                                                                          */
/*  Property of Texas Instruments Incorporated. Restricted Rights -         */
/*  Use, duplication, or disclosure is subject to restrictions set          */
/*  forth in TI's program license agreement and associated documentation.   */
/****************************************************************************/

/****************************************************************************/
/* sysmon.h                                                                 */
/*                                                                          */
/* System startup initialization and runtime monitor.                       */
/****************************************************************************/

#ifndef __SYSMON_H
#define __SYSMON_H

#include "info.h"


                        /****************************************************/
                        /* RTOS Clock period (milliseconds/tick).           */
                        /****************************************************/

#define RTOS_MS_PER_TICK    10                         /* milliseconds/tick */

                        /****************************************************/
                        /* Application startup states read from app config  */
                        /* Defaults.StartUpState.                           */
                        /****************************************************/

typedef enum
{
    STARTUP_NORMAL   = 0,                     /* Normal startup (operating) */
    STARTUP_STANDBY  = 1,               /* Standby (no color wheel or lamp) */
    STARTUP_LOWPOWER = 2         /* Low power (all modules at minimum power */
    
}   STARTUP_ENUM;

                        /****************************************************/
                        /* Module reset type enumeration.                   */
                        /****************************************************/

typedef enum
{
    RESET_INIT,                                           /* power-up reset */
    RESET_LS_ASIC,                                /* lamp strike ASIC reset */
    RESET_LS_ASIC_CW              /* lamp strike ASIC and color wheel reset */
    
}   RESET_ENUM;

                        /****************************************************/
                        /* Module control function completion codes.        */
                        /****************************************************/

typedef enum
{
    EXEC_CC_FAIL,                                /* general fail indication */
    EXEC_CC_PASS,                                                   /* pass */
    EXEC_CC_FATAL,                         /* fatal error; halt application */
    EXEC_CC_RTOSERR,                                          /* RTOS error */
    EXEC_CC_API                            /* error in call to API function */
    
}   EXEC_CC_ENUM;

                        /****************************************************/
                        /* System event enumeration.                        */
                        /****************************************************/

typedef enum
{
    SYSEVENT_START,        /* start power state machine coming out of reset */
    SYSEVENT_POWERDOWN,                        /* perform normal power-down */
    SYSEVENT_POWERKEY,     /* power key pressed (system not in active mode) */
    SYSEVENT_FAULT,         /* fault detected, perform immediate power-down */
    SYSEVENT_COOL,                                  /* cooldown is complete */
    SYSEVENT_PROGMODE               /* transition to flash programming mode */
    
}   SYSEVENT_ENUM;

                        /****************************************************/
                        /* System power states.                             */
                        /****************************************************/

typedef enum 
{
    POWERSTATE_RESET,                 /* system is in the reset power state */
    POWERSTATE_STANDBY,             /* system is in the standby power state */
    POWERSTATE_ACTIVE,               /* system is in the active power state */
    POWERSTATE_COOLING                                 /* system is cooling */
    
}   POWERSTATE_ENUM;


                        /****************************************************/
                        /* System public functions.                         */
                        /****************************************************/

void sysmon_info( TASKINFO_STRUCT *info );      /* request task information */

void sysmon_powerdown( void );               /* inform system of power down */
void sysmon_powerkey( void );           /* inform system of power key press */
void sysmon_fault( void );             /* inform system of a shutdown fault */
void sysmon_cooldown( void );       /* inform system of cooldown completion */
void sysmon_progmode( void );      /* inform system to set programming mode */

POWERSTATE_ENUM sysmon_state( void );               /* return current state */

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -