#include "GUI_VC66_Time.h"
#include "RTE_TIME.h"
/*ZH:*/

/*时间显示*/
static const uint16_t GUI_DISP_Hours[2]   =  {370, 349};
static const uint16_t GUI_DISP_Minutes[2] =  {428, 406};


void Gui_Display_Time(void)
{
    uint8_t Hours   = 0u;
    uint8_t Minutes = 0u;
    //uint8_t Month = 0u;
    //uint8_t Date  = 0u;
    //uint8_t Year  = 0u;
    
    Hours = Get_RTC_HOUR();
    Minutes = Get_RTC_MINUTE();

    if ((Hours <= 24u) && (Minutes < 60u))
    {
        GUI_Translate_Display(Time_Sprite, Nb_21_maohao, 396u, 45u, GUI_BLENDMODE_SRC_OVER); /*显示冒号*/
        GUI_General_Digit_Display(Time_Sprite, Hours  , Nb_21_0, 2u, 1u, GUI_DISP_Hours  , 37, GUI_BLENDMODE_SRC_OVER);/*显示小时*/
        GUI_General_Digit_Display(Time_Sprite, Minutes, Nb_21_0, 2u, 0u, GUI_DISP_Minutes, 37, GUI_BLENDMODE_SRC_OVER);/*显示分钟*/
    }
    else
    {
        GUI_Translate_Display(Time_Sprite, SpriteSize, 396u, 45u, GUI_BLENDMODE_SRC_OVER);/*不显示*/
    }
}

/*:ZH*/