#include "Can_App.h"


void Can_Set_Buff_500(canlib_uint8_t CopyData[])
{
    CANMsg500Union *p500;
    uint8_t i = 0;
    for (i = 0; i < 8; i++)
    {
        CopyData[i] = 0xFFU;
    }
    p500 = (CANMsg500Union *)CopyData;
    if (p500 != (void *)0)
    {
        p500->Sig.Key_ISTOP = 1;
        p500->Msg[1] = 0x00;
        p500->Msg[2] = 0x00;
        p500->Msg[3] = 0x00;
        p500->Msg[4] = 0x00;
        p500->Msg[5] = 0x00;
        p500->Msg[6] = 0x00;
        p500->Msg[7] = 0x00;
    }
}
void Can_Set_Buff_3A2(canlib_uint8_t CopyData[])
{
    CANMsg3A2Union *p3A2;
    uint8_t i = 0;
    for (i = 0; i < 8; i++)
    {
        CopyData[i] = 0xFFU;
    }
    p3A2 = (CANMsg3A2Union *)CopyData;
    if (p3A2 != (void *)0)
    {
        p3A2->Sig.ICU_POWERStateFB = 1;
        p3A2->Sig.ICU_KL15State = 1;
        p3A2->Sig.ICU_LEDLightState = 1;
        p3A2->Sig.ICU_BuzzerState = 1;
        p3A2->Sig.ICU_IndicatorLightState = 1;
        p3A2->Sig.ICU_IndicatorLightPowerState = 1;
        p3A2->Sig.ICU_GrassFullState = 1;
        p3A2->Sig.ICU_kEY_AState = 1;
        p3A2->Sig.ICU_kEY_BState = 1;
        p3A2->Sig.ICU_kEY_CState = 1;
        p3A2->Sig.ICU_kEY_DState = 1;
        p3A2->Sig.ICU_kEY_EState = 1;
        p3A2->Sig.ICU_BluetoothConnectState = 1;
        p3A2->Msg[4] = 0x00;
        p3A2->Msg[5] = 0x00;
        p3A2->Msg[6] = 0x00;
        p3A2->Msg[7] = 0x00;
    }
}
void Can_Set_Buff_3A7(canlib_uint8_t CopyData[])
{
    CANMsg3A7Union *p3A7;
    uint8_t i = 0;
    for (i = 0; i < 8; i++)
    {
        CopyData[i] = 0xFFU;
    }
    p3A7 = (CANMsg3A7Union *)CopyData;
    if (p3A7 != (void *)0)
    {
        p3A7->Sig.ICU_MasterBMSCommunicatlost = 1;
        p3A7->Sig.ICU_SlaveBMSCommunicatlost = 1;
        p3A7->Sig.ICU_MCUCommunicatlost = 1;
        p3A7->Sig.ICU_VCUCommunicatlost = 1;
        p3A7->Msg[1] = 0x00;
        p3A7->Msg[2] = 0x00;
        p3A7->Msg[3] = 0x00;
        p3A7->Msg[4] = 0x00;
        p3A7->Msg[5] = 0x00;
        p3A7->Msg[6] = 0x00;
        p3A7->Msg[7] = 0x00;
    }
}
