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

namespace RCUHost.Protocols
{
    /// <summary>
    /// RCU与服务器交互命令
    /// </summary>
    public enum CommandType : byte
    {
        /// <summary>
        /// 定时上报
        /// </summary>
        TimerReport=0x34,

        /// <summary>
        /// 搜索主机
        /// </summary>
        SearchHost = 0x01,
        /// <summary>
        /// 心跳包
        /// </summary>
        Heart = 0x02,
        /// <summary>
        /// 插卡取电
        /// </summary>
        InsertCard = 0x03,
        /// <summary>
        /// 服务请求
        /// </summary>
        ServiceRequest = 0x04,
        /// <summary>
        /// 报警状态
        /// </summary>
        AlarmStatus = 0x05,
        /// <summary>
        /// 空调状态
        /// </summary>
        AirConditionStatus = 0x06,
        /// <summary>
        /// 节能模式下发
        /// </summary>
        EnergySavingMode = 0x07,
        /// <summary>
        /// 同步时间
        /// </summary>
        SyncTime = 0x08,
        /// <summary>
        /// 设置命令，客房控制
        /// </summary>
        RoomControl = 0x10,
        /// <summary>
        /// 升级主机固件（局域网使用）
        /// </summary>
        UpdateHost = 0x0A,
        /// <summary>
        /// 升级配置文件（局域网使用）
        /// </summary>
        UpdateConfig = 0xA2,

        /// <summary>
        /// 升级进度
        /// </summary>
        UpdateProgressBar = 0xB6,
        /// <summary>
        /// 上传RCU软件当前版本号 RCU -> 服务器
        /// </summary>
        UploadCurrentVersion = 0x0B,
        /// <summary>
        /// 房态变化 服务器 -> RCU
        /// </summary>
        RoomStatusChanged = 0x0C,
        /// <summary>
        /// 灯光模式 服务器 -> RCU
        /// </summary>
        LightScene = 0x0D,
        /// <summary>
        /// 客房状态同步 RCU->服务器
        /// </summary>
        RoomStatus = 0x0E,

        /// <summary>
        /// 新版本的 设备状态
        /// </summary>
        NewRoomStatus=0x36,
        /// <summary>
        /// 设备控制 服务器 -> RCU
        /// </summary>
        DeviceControl = 0xF,
        /// <summary>
        /// 设置/取消连通房 服务器 -> RCU
        /// </summary>
        ConnectingRoom = 0x10,
        /// <summary>
        /// 设置主机网络参数 服务器 -> RCU
        /// </summary>
        NetworkSetting = 0x11,
        /// <summary>
        /// 服务状态上报及控制
        /// </summary>
        Service = 0x12,
        /// <summary>
        /// 空调单属性控制
        /// </summary>
        AirProperty = 0x13,
        /// <summary>
        /// 文字上报：RCU -> 服务器
        /// </summary>
        WordsReport = 0x14,
        /// <summary>
        /// 电视控制 服务器 -> RCU
        /// </summary>
        TvControl = 0x21,
        /// <summary>
        /// 主机授权 服务器 -> RCU
        /// </summary>
        HostAuthorization = 0x22,
        /// <summary>
        /// 窗帘控制 服务器 -> RCU
        /// </summary>
        CurtainControl = 0x23,
        /// <summary>
        /// 电源控制 服务器 -> RCU
        /// </summary>
        PowerSupplyControl = 0x24,
        /// <summary>
        /// 开锁 服务器 -> RCU
        /// </summary>
        UnlockControl = 0x25,
        /// <summary>
        /// 音乐控制 服务器 -> RCU
        /// </summary>
        MusicControl = 0x26,
        /// <summary>
        /// 设置MAC地址 服务器 -> RCU
        /// </summary>
        SetMAC = 0x27,
        /// <summary>
        /// 设置设备密钥 服务器 -> RCU
        /// </summary>
        SetDeviceSecret = 0x28,
        /// <summary>
        /// 获取主机密钥 服务器 <-> RCU
        /// </summary>
        GetHostSecret = 0x29,
        /// <summary>
        /// tftp升级
        /// </summary>
        TFTPUpdate = 0x68,
        /// <summary>
        /// ftp升级
        /// </summary>
        FTPUpdate = 0x69,
        /// <summary>
        /// 读取寄存器信息
        /// </summary>
        GetRegister = 0x30,
        /// <summary>
        /// 设置寄存器信息
        /// </summary>
        SetRegister = 0x31,

        /// <summary>
        /// 询问房态
        /// </summary>
        AskRoomStatus = 0x32,
        /// <summary>
        /// 读取主机信息
        /// </summary>
        RCUInfo = 0xB1,
        /// <summary>
        /// 主机获取指定域名解释的IP
        /// </summary>
        ExplainDomainIP = 0xD6,
        /// <summary>
        /// 日志服务器域名设置
        /// </summary>
        SetRCULog = 0xD9,
        /// <summary>
        /// 日志服务信息查询
        /// </summary>
        ReceiveRCULog = 0xDA,
        /// <summary>
        /// 白天起止时间同步
        /// </summary>
        HotelTime = 0xDB,

        /// <summary>
        /// TFTP_Log
        /// </summary>
        TFTPLog  = 0xDA,
        TFTPLog_Setting  = 0xD9

    }
}
