From 5d5e78629e693beb69139e41cb1209233624da1d Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Tue, 21 Oct 2025 18:17:25 -0500 Subject: [PATCH 1/2] chore: update local build version to 2.18.2-local --- src/Directory.Build.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Directory.Build.props b/src/Directory.Build.props index af743a53..545110d3 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -1,6 +1,6 @@ - 2.15.1-local + 2.18.2-local $(Version) PepperDash Technology PepperDash Technology From 7c72a0d905461e0fd7811ca1d011c0b969f4c2d5 Mon Sep 17 00:00:00 2001 From: Andrew Welker Date: Tue, 21 Oct 2025 18:19:09 -0500 Subject: [PATCH 2/2] fix: send device interface list on client join In order to avoid updating the MC Edge API to send device interfaces, one of the responses to the clientJoined message will now be a message with the type `/system/deviceInterfaces`. This has a corresponding handler in the core library to put the interfaces in the correct location. --- .../MobileControlSystemController.cs | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs b/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs index 01bf3579..273ffd9f 100644 --- a/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs +++ b/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs @@ -2185,6 +2185,8 @@ namespace PepperDash.Essentials }; SendMessageObject(message); + + SendDeviceInterfaces(clientId); return; } @@ -2196,7 +2198,10 @@ namespace PepperDash.Essentials ClientId = clientId, Content = roomKey }; + SendMessageObject(message); + + SendDeviceInterfaces(clientId); return; } @@ -2214,6 +2219,8 @@ namespace PepperDash.Essentials }; SendMessageObject(message); + + SendDeviceInterfaces(clientId); return; } @@ -2227,6 +2234,36 @@ namespace PepperDash.Essentials }; SendMessageObject(newMessage); + + SendDeviceInterfaces(clientId); + } + + private void SendDeviceInterfaces(string clientId) + { + this.LogDebug("Sending Device interfaces"); + var devices = DeviceManager.GetDevices(); + Dictionary deviceInterfaces = new Dictionary(); + + foreach (var device in devices) + { + var interfaces = device?.GetType().GetInterfaces().Select((i) => i.Name).ToList() ?? new List(); + + deviceInterfaces.Add(device.Key, new DeviceInterfaceInfo + { + Key = device.Key, + Name = (device as IKeyName)?.Name ?? "", + Interfaces = interfaces + }); + } + + var message = new MobileControlMessage + { + Type = "/system/deviceInterfaces", + ClientId = clientId, + Content = JToken.FromObject(new { deviceInterfaces }) + }; + + SendMessageObject(message); } private void HandleUserCode(JToken content, Action action = null)