public bool GetConfig() { byte[] command = { 0xA9, 0x9A, 0x02, CONST.CMD.GET_CONFIG, 0, 0xED }; if (!V2_SendCommand(command, true)) return false; if (receiveBuffer[2] != CONST.CMD.RETURN_LEN.GET_CONFIG) { return false; } config.ReadFromArray(receiveBuffer.ToArray()); return true; }
public bool GetConfig() { byte[] command = { 0xA9, 0x9A, 0x02, CONST.CMD.GET_CONFIG, 0, 0xED }; // if (!V2_SendCommand(command, true)) return false; if (!SendRobotCommand(command, CONST.CB.GETCONFIG)) { return(false); } if (receiveBuffer[2] != CONST.CB.GETCONFIG.dataLen) { return(false); } config.ReadFromArray(receiveBuffer.ToArray()); return(true); }