DeviceDriverSettingsChildItem.PTZChildItem

Environment - SDK 2023R2 on 2023R2 XProtect Corporate

Architecture - Non-Federated Site with 2 Recording servers

When we try to add a camera (same camera/model) and copy all the settings from the primary recording server to the second recording server using SDK, the below block of code shows that the settings are saved on the secondary server, but the settings are never copied.

DeviceDriverSettings primdds = primarycamera.DeviceDriverSettingsFolder.DeviceDriverSettings;
DeviceDriverSettings secdds = secondarycamera.DeviceDriverSettingsFolder.DeviceDriverSettings;
if (primdds != null)
{
	if (primdds.PTZChildItem != null)
	{
    		if (secdds.PTZChildItem != null)
    		{
       
     			secdds.PTZChildItem.Name = primdds.PTZChildItem.Name;
     			secdds.PTZChildItem.Description = primdds.PTZChildItem.Description;
     			ConfigurationApiProperties cap1 = primdds.PTZChildItem.Properties;
     			foreach (string prop in cap1.KeysFullName)
     			{
         			secdds.PTZChildItem.SetProperty(prop, primdds.PTZChildItem.GetProperty(prop));
     			}
 		}
		secdds.Save();            
        }
}

When the PTZProtocol is Absolute, all the settings get copied.

But when the PTZProtocol is Relative, the settings are never copied, and there are no errors.

The settings are below and are not getting saved.

CHECK deviceptz:0.0/pan/a7c77dac-a453-49b9-8b5b-f62032f68889

PRIMARY–

      <control>

        <absolutesupport>false</absolutesupport>

        <relativesupport>true</relativesupport>

        <stopsupport>true</stopsupport>

        <startsupport>true</startsupport>

        <automaticsupport>false</automaticsupport>

        <speedsupport>true</speedsupport>

      </control>

SECONDARY–

      <control>

        <absolutesupport>true</absolutesupport>

        <relativesupport>true</relativesupport>

        <stopsupport>true</stopsupport>

        <startsupport>true</startsupport>

        <automaticsupport>false</automaticsupport>

        <speedsupport>true</speedsupport>

      </control>

To my knowledge you cannot set these settings. These settings are dictated by the camera in the process of adding the camera to the XProtect VMS / Recording Server. If you look at the Management Client there is no way you can modify the settings.

It is a mistake that the Configuration API doesn’t protest but instead seems to accept even if the settings change is not carried through.

From the way I understand the scenario it is a mystery to me how these values are not the same in the two servers. I think adding the same camera twice should give the same settings values twice.