Trouble changing the value of a member of a class in Matlab

4 ビュー (過去 30 日間)
Raha
Raha 2023 年 3 月 14 日
コメント済み: chrisw23 2023 年 3 月 15 日
What does the + sign here means?
  • I am trying to assign a new value to a member of a .NET object in Matlab:
  • The type of variable is not clear to me, I have used class and there is a '+' sign in the class type returned by Matlab
K>> device.MotorDeviceSettings.TriggerConfigSettings
ans =
KCubeTriggerConfigSettings with properties:
TriggerPolarity2Str: [1×1 System.String]
Trigger2Polarity: TriggerHigh
TriggerPolarity1Str: [1×1 System.String]
Trigger1Polarity: TriggerHigh
TriggerMode2Str: [1×1 System.String]
Trigger2Mode: TrigOUT_GPO
TriggerMode1Str: [1×1 System.String]
Trigger1Mode: TrigIN_GPI
UseType: UseEitherSettings
K>> device.MotorDeviceSettings.TriggerConfigSettings.Trigger2Mode
ans =
TrigOUT_GPO
K>> class(device.MotorDeviceSettings.TriggerConfigSettings.Trigger2Mode)
ans =
'Thorlabs.MotionControl.GenericMotorCLI.Settings.KCubeTriggerConfigSettings+TriggerPortMode'

回答 (1 件)

Walter Roberson
Walter Roberson 2023 年 3 月 14 日
Java objects and .NET objects and similar objects are not restricted by MATLAB's naming rules. MATLAB
It looks like you are using Thorlabs Kinesis with an API description at https://www.thorlabs.com/Software/Motion%20Control/APT_Communications_Protocol.pdf . KCubeTriggerConfigSettigns+TriggerPortMode appears to be an enumerated type. The specific values are listed on page 246 of that document.

カテゴリ

Help Center および File ExchangeCall Web Services from MATLAB Using HTTP についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by