BTool.SendCmds.SendHCIOther C# (CSharp) Method

SendHCIOther() public method

public SendHCIOther ( HCICmds cmd ) : bool
cmd HCICmds
return bool
        public bool SendHCIOther(HCICmds.HCIOtherCmds.HCIOther_ReadRSSI cmd)
        {
            bool success = true;
            try
            {
                byte dataLength = cmd.dataLength;
                byte[] data = new byte[dataLength + 4];
                int index = 0;
                bool dataErr = false;
                if (m_deviceFormUtils.LoadMsgHeader(ref data, ref index, 1, cmd.opCodeValue, dataLength)
                && !m_dataUtils.Load16Bits(ref data, ref index, cmd.connHandle, ref dataErr, false))
                    TransmitCmd(cmd.cmdName, cmd.opCodeValue, data);
                if (dataErr)
                    success = HandleDataError(cmd.cmdName);
            }
            catch (Exception ex)
            {
                success = HandleException(cmd.cmdName, ex.Message);
            }
            return success;
        }