| | |
| | | { |
| | | try |
| | | { |
| | | |
| | | return trait_swting.value; |
| | | } |
| | | catch (Exception ex) |
| | |
| | | if (command == CommandType_A.write) |
| | | { |
| | | sendJob = new JObject { { "Namespace", vendor_code }, { "Command", command.ToString() }, { "Type", "device" } }; |
| | | JObject data = new JObject {{ "sid", sid } }; |
| | | JObject data = new JObject { { "sid", sid } }; |
| | | sendJob.Add("objects", data); |
| | | List<ControlData> controlData = new List<ControlData>(); |
| | | controlData.Add(new ControlData() |
| | | { |
| | | name = "on_off", |
| | | data_type = "Bool", |
| | | value = on_off |
| | | }); |
| | | |
| | | |
| | | } |
| | | else if (command == CommandType_A.read) |
| | | { |