Hi all,
I'm trying to alter AWE input variables via MATLAB, and am having trouble getting the GSYS to update.
I can load the GSYS from AWE, check a value (in this case starting value 5700), but when I try to write a new value to the same place in the struct it doesn't seem to work.
I get the same result whether AWE is running or not.
The help section on this makes it seem straightforward. Any ideas/tips?
MATLAB commands I'm using as follows:
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value
ans =
5700
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value(1, 1)=4567;
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value
ans =
5700
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value=4567;
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value
ans =
5700
>> set_gsys(GSYS, 'Virt_Trans_04.awj');
>> GSYS.SYS.module{1, 17}.variable{1, 1}.value
ans =
5700
4:22pm
Hello emiddlet,
Have you tried using the class and variable names of the module you're trying to control? e.g. "GSYS.SYS.Scaler1.gain = -12" rather than using "module{1,17}.variable{1,1} = 4567"
3:51am
Yes! Thanks.
I was using the syntax for a typical MATLAB structure, where the value I was looking to update was buried under gsys>sys>module>variable>value.
Using GSYS.SYS.SpeedIN.value finds the correct value and allows me to update it in AWE.
I take it because the gsys is actually an awe_gsys rather than a 'normal' MATLAB struct?
11:50am
Glad it worked. Yes, I believe the case you stated is the reason it was not working before.