Crabtree/SmartHome/UI/SimpleControl/Phone/Light/UserDeviceToSocket.cs
@@ -246,6 +246,7 @@
            });
        }
        private readonly object SendLocker = new object ();
        /// <summary>
        /// 控制所有的灯
        /// </summary>
@@ -275,7 +276,11 @@
                            byte [] returnBytes = null;
                            if (common.Type == DeviceType.LightEnergySocket) {
                                new System.Threading.Thread (() => {
                                    try {
                                        lock (SendLocker) {
                                    mSendCount++;
                                        }
                                        //mSendCount++;
                                    returnBytes = Control.ControlBytesSendHasReturn (Command.SetSingleLight, common.SubnetID, common.DeviceID, new byte [] { common.LoopID, b, 0, 0 });
                                    if (showTip) {
                                        if (returnBytes == null) {
@@ -301,7 +306,12 @@
                                            });
                                        }
                                    }
                                        //mSendCount--;
                                    } catch { } finally {
                                        lock (SendLocker) {
                                    mSendCount--;
                                        }
                                    }
                                }) { IsBackground = true}.Start();
                                //等待100ms再发送第二个设备数据