public bool Change(Status_List_t msg) { int index = Find(msg.cmdType, msg.id); if (index == -1) return false; test[index] = msg; return true; }
public bool Add(Status_List_t CAN_Massege) { test[currentPtr] = CAN_Massege; currentPtr++; currentPtr %= SEQ_NUM; return true; }
public Status_List_t Get(byte cmdType, ushort id) { Status_List_t temp = new Status_List_t(); for (int i = 0; i < test.Length; i++) { if ((cmdType == test[i].cmdType) &&(id == test[i].id)) return test[i]; } return temp; }