2014年5月1日木曜日

UDP Ver3.4

ああ、PSIとKpa間違えた。



圧力も1バイトありゃ足りるんか。

温度の後ろに4バイト詰めとくか。

ついでにLR反転。なんとなく。

typedef struct udpdata_t{
    Byte sid[8];                 
    //----------------------------
    unsigned short rpm;         
    unsigned short speed;        
    Byte eg_status;              
    Byte volt;                    
    Byte eg_load;    /
    Byte timingadvance;          
    //----------------------------
    Byte vacpress; // RESERVED
    Byte vactemp;                
    Byte watertemp;            
    Byte fuel; // RESERVED
    short innertemp;
    short outertemp;
    //-----------------------------
    short MAGNET_X;     
    short MAGNET_Y;     
    Byte sw_c;
    Byte sw_c_lp; 
    short MAGNET_Z;
    //----------------------------
    Byte lati_dd;                
    Byte lati_mm;                
    unsigned short lati_mmmm;    
    Byte longi_dd;               
    Byte longi_mm;               
    unsigned short longi_mmmm;   
    //----------------------------
    unsigned int pluse;          
    //----------------------------
    Byte Tire_press_FL;  // NEW      1LSB=0.29PSI (0=0psi  255=73.95psi)
    Byte Tire_press_FR;  // NEW      
    Byte Tire_press_RL; // NEW
    Byte Tire_press_RR; // NEW
    Byte Tire_temp_FL;  // NEW       1LSB=1℃ (0=-50℃  255=205℃)
    Byte Tire_temp_FR;  // NEW
    Byte Tire_temp_RL;  // NEW
    Byte Tire_temp_RR;  // NEW
    //----------------------------
    Byte   // RESERVED
    Byte   // RESERVED
    Byte   // RESERVED
    Byte   // RESERVED
    Byte TPMS_Batt_FR;  // RESERVED
    Byte TPMS_Batt_FL;  // RESERVED
    Byte TPMS_Batt_RR;  // RESERVED
    Byte TPMS_Batt_RL;  // RESERVED
    //----------------------------
    Byte flag;                   
    Byte gps;                    
    Byte sw_a;                   
    Byte sw_a_lp;                
    Byte sw_b;                   
    Byte sw_b_lp;                
    Byte sw_ab;                  
    Byte sw_ab_lp;               
    //----------------------------
    unsigned short oilpress;     
    unsigned short oiltemp;      
    


}udpdata;

0 件のコメント:

コメントを投稿