VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Error -307652 when call VeriStand 2010 Get Parameters List.vi

Hi I am trying to write into model parameters.

 

As first step I am trying to recover a list of parameter using Get Parameters List.vi but I am receiving the error -307652 with the following message:

NI_VeriStand ModelManager ExecutionAPI.lvlib:NI VeriStand - Get Parameters List.vi
<append>=========================
NI VeriStand:  The server did not provide a meaningful reply; this might be caused by a contract mismatch, a premature session shutdown or an internal server error.

 

What I may be the problem?

 

Cheers.

 

GetParameter.png

CHCastro
0 Kudos
Message 1 of 12
(7,291 Views)

Hi Claudio,

 

I was able to pull paramters like this:

 

VeristandSnippet.png

 

I used a included System Definition file that ships with Veristand.  Could you give this a try and let me know how it goes?  I'm looking into the parameter "target" that I removed and will provide an update when I find out how that is supposed to be used.

 

Thanks,

Dustin D

0 Kudos
Message 2 of 12
(7,241 Views)

Hi Dustin,

 

I tryed with C:\Documents and Settings\All Users\Documents\National Instruments\NI VeriStand 2010\Projects\Example\Sinewave Delay.nivssdf and it worked also but not with my model.

 

I will try a simple model and try again to check what happens.

 

Tomorrow I will post the result.

 

Cheers.

CHCastro
0 Kudos
Message 3 of 12
(7,240 Views)

Hi Claudio,

 

I found out that argument provided to the Get Parameters.vi.

 

 VeristandSnippet.png

 

Needs to match the target defined in the SDF:

 

SS-2011-03-22_15.48.51.png

 

I hope this extra detail helps!


Regards,

Dustin D

0 Kudos
Message 4 of 12
(7,234 Views)

Hello Claudio H,

 

I am unable to reproduce this error with the Sinewave Delay shipping example and the following code snippet.

 

Snippet1.png

 

Repeated deploying and undeploying a System Definition using the API causes the VeriStand Gateway to crash with error -307652.  Your code snippet forces the system definition to deploy and undeploy each time you run it.  This issue is documented in Corrective Action Request 244847 and has been fixed in the NI VeriStand 2010 f3 Patch.  If you have not already done so, I recommend that you install the patch.

 

If you still experience the error after installing the patch, and you cannot reproduce the error with the shipping example, please post a simple model DLL and its source file that reproduces the issue.  If your model is protected intellectual property, you may message me privately and we can exchange files off of the public forum.

 

Regards,

 

Steve K

0 Kudos
Message 5 of 12
(7,228 Views)

Hi Pie56694,

 

I have only the f1 patch installed. Is there f2 patch?

 

I tried with sinewave and worked too. So I tried with a medium size model that we work I did not receive the error message.

 

However, when I tried with the medium model plus our huge aircraft model I received the error with new message:

 

GetPar_Error.vi >> NI_VS ModelManager ExecutionAPI.lvlib:NI VeriStand - Get Parameters List.vi
<append>=========================
NI VeriStand:  The communication object, System.ServiceModel.Channels.ServiceChannel, cannot be used for communication because it is in the Faulted state.

 

I removed aircraft model, updated VeriStand to f3 and added the sinewave and got the no error.

 

It seems that the SDF file was corrupted by our aircraft model. It has 9535 parameters and 12335 signals. May these numbers be a issue?

 

I am importing only the parameters.

 

Tomorrow I will be at NI Day Brazil.

 

Cheers.

 

 

CHCastro
0 Kudos
Message 6 of 12
(7,212 Views)

Hello CHCastro,

 

What modeling environment created the model?  I may be able to configure a test at NI depending on the environment.  I tried with a LabVIEW model and imported and ran 400 parameters without an error.

 

Would you please try only the huge aircraft model in a new system definition?

 

Is it possible to break this model into several models?  That will allow you to take advantage of multi-core model assignment.

 

Have you ever tried to integrate this model before?

 

Do you need to import all of these parameters (it sounds like you're not importing signals at all)?  If not, then is it possible to preface the parameter names you do need with a unique string, such as "Import Me"?  Then you can use the Regular Expression Filter on the Parameters and Signals tab of the Add Simulation Model dialog box in System Explorer to import only the parameters you need; just filter on "Import Me".

 

Regards,

 

Steve K

0 Kudos
Message 7 of 12
(7,206 Views)

Hi Steve,

 

We are using Simulink model (Carl visited us last year and know our model) and its size is a problem since VS 2009. It is big but is light; an Pentium III 2 GHz is able to run it at 100 Hz smoothly.

 

I tried to include the model in a new SDF without parameters and signals and download it with VS 2009 and 2010 without problems.

 

This is a standard model used along all company and want to avoid change it for our use. As I said, it is big but light. With 2009 Alisson Kokot did a VI that added the parameters to VS 2009 in4 after download it to the target without parameters and signals.

 

No, we are importing the model without signals and parameters and adding only the parameters that we need. This is the point that we are facing problems.

 

Our working around was exactly this. We use the filter to select the parameters of desired subsystem and worked (we could download without error) but after we face another problem: we can read the parameter using the API but not write on it.

 

I can show the code in EMBRAER discussion forum if you prefer to see the code.

 

Cheers,

CHCastro
0 Kudos
Message 8 of 12
(7,187 Views)

Hi Dustin,

 

I was thinking that is the point and used "Model Host" as input.

 

Do you believe that may be a problem to have spaces in the names?

 

Cheers,

CHCastro
0 Kudos
Message 9 of 12
(7,185 Views)

Hello CHCastro,

 

It sounds like you're using the System Definition .NET API to add Parameters and Signals by name to work-around an apparent problem with the System Explorer.  Is this correct?  If so, please try the following technique in NI VeriStand 2010.

 

After working with a larger model (6000 parameters), I think System Explorer is using a different algorithm to import model parameters depending on the options enabled during import.  I was able to import 6000 parameters by enabling the "Import all parameters" from the "Parameters and Signals" page of the Add Simulation Model dialog box when I first add the model.  If I leave this option disabled (default) then the parameters appear in the system definition, but they cannot be accessed by the Execution API, and they seem not to be deployed to the execution host.  I am still investigating this behavior and I think it will be a bug.  I recommend after you import all parameters that you do not click the Parameters icon in the configuration tree (it takes a long time to populate the list box).

 

Please let me know the result of this experiment.  If this is not at all what you're doing, I'd like to look at some code to help me understand.

 

Regards,

 

Steve K

 

 

0 Kudos
Message 10 of 12
(7,180 Views)