using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace iq2dev.com.IQCommLib
{
    public static class IOLinkErrorCodes
    {
        public static Dictionary<ushort, string> description = new Dictionary<ushort, string>();

        static IOLinkErrorCodes()
        {
            description.Add(0x1000, "io-link communication error");
            description.Add(0x1100, "io-link ISDU error / timeout");
            description.Add(0x5600, "master – ISDU checksum error");
            description.Add(0x5700, "master – ISDU illegal service primitive");

            description.Add(0x7E00, "index and/or subindex discrepancy in start and get ISDU services response");
            description.Add(0x7F00, "on-request data write access in process");
            description.Add(0x7F01, "on-request data read access in process");

            description.Add(0x8000, "device application error – no details");
            description.Add(0x8011, "index not available");
            description.Add(0x8012, "subindex not available");
            description.Add(0x8020, "service temporarily not available");
            description.Add(0x8021, "service temporarily not available - local control");
            description.Add(0x8022, "service temporarily not available – Device control");
            description.Add(0x8023, "access denied");
            description.Add(0x8030, "parameter value out of range");
            description.Add(0x8031, "parameter value above limit");
            description.Add(0x8032, "parameter value below limit");
            description.Add(0x8033, "parameter length overrun");
            description.Add(0x8034, "parameter length underrun");
            description.Add(0x8035, "function not available");
            description.Add(0x8036, "function temporarily unavailable");
            description.Add(0x8040, "invalid parameter set");
            description.Add(0x8041, "inconsistent parameter set");
            description.Add(0x8082, "application not ready");
            description.Add(0x8100, "vendor specific no details");
            //description.Add( 0x, "");
        }
    }
}
