#include "RGB_Sensor.h"


typedef enum{
    RGB_Status_Data_Request  = 0x01,
    RGB_ControllerID_SET     = 0x02,
    RGB_SensorID_SET         = 0x03,
    RGB_SensorID_SET_Success = 0x04,      
}RGB_CMT_T;
#define     RGB_ControllerID_SET_Length 10 
#define     RGB_SensorID_SET_Length     10 
#define     RGB_SensorDataRequest_Length 7
#define     RGB_SensorIDAutoSetRequest_Length 7

uint8_t My_RGB_ID = 0;
uint8_t* RGB_Sensor_Func(uint8_t* data){
	RGB_CMT_T type = data[Bluecell_Type];
    switch(type){
        case RGB_Status_Data_Request:                
            Uart2_Data_Send(&RGB_Data[0],15);
            break;
        case RGB_ControllerID_SET:                             break;
        case RGB_SensorID_SET:    
            data[blucell_type] = RGB_SensorID_SET_Success;
            My_RGB_ID = data[blucell_length + 2];
            data[5]   = STH30_CreateCrc(&data[blucell_type],data[blucell_length]);
            printf("My ID SET Success %02x \r\n",My_RGB_ID);
            Uart2_Data_Send(&data[blucell_stx],RGB_SensorIDAutoSetRequest_Length);
            break;
        default:break;
    }
    return data;
}
void RGB_Value_Func(void){
    
}
