I try to get the password of the hardware, but the password is empty. is it correct:
var camera = new VideoOS.Platform.ConfigurationItems.Camera(cameraFQID);
var hardware = new Hardware(
EnvironmentManager.Instance.CurrentSite.ServerId,
camera.ParentItemPath
);
string password = "";
try
{
MessageBox.Show($"Attempting to read password... {hardware.Id}");
ServerTask passwordTask = hardware.ReadPasswordHardware();
while (passwordTask.State != StateEnum.Error && passwordTask.State != StateEnum.Success)
{
System.Threading.Thread.Sleep(100);
passwordTask.UpdateState();
}
password = hardware.GetProperty("PasswordHardware");
}