Example #1
0
        public string CtlGetErrMsg(uint errorCode)
        {
            if (0 == errorCode)
            {
                return("");
            }
            uint cumulativeErrCode = RTC6Wrap.n_get_error(this.Index + 1);

            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 0)))
            {
                return("no rtc board founded via init_rtc_dll");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 1)))
            {
                return("access denied via init_rtc_dll, select, acquire_rtc");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 2)))
            {
                return("command not forwarded. PCI or driver error");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 3)))
            {
                return("rtc timed out. no response from board");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 4)))
            {
                return("invalid parameter");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 5)))
            {
                return("List processing is (not) active");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 6)))
            {
                return("list command rejected, illegal input pointer");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 7)))
            {
                return("list command wad converted to a List_mop");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 8)))
            {
                return("dll, rtc or hex version error");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 9)))
            {
                return("download verification error. load_program_file ?");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 10)))
            {
                return("DSP version is too old");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 11)))
            {
                return("out of memeory. dll internal windows memory request failed");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 12)))
            {
                return("EEPROM read or write error");
            }
            if (Convert.ToBoolean(cumulativeErrCode & (0x01 << 16)))
            {
                return("error reading PCI configuration reqister druing init_rtc_dll");
            }
            return($"unknown error code : {errorCode}");
        }