Adding VAServer remote control mode section in documentation

parent 6d09964d
......@@ -1458,6 +1458,26 @@ mStruct.RecordOutputBaseFolder = fullfile( 'recordings/MyReproduction', datestr(
va.set_reproduction_module_parameters( 'MyReproduction', mStruct );
</code></pre>
<blockquote>Note: this feature is available since v2018b.</blockquote>
</p>
<h5>Starting the VAServer in remote control mode (<code>Matlab</code> example)</h5>
<p>
To run several simulations in a batch system, the VAServer application can be started in a <i>remote control mode</i> that allows remote shutdown with a special client call.
Stopping VA with a <i>kill</i> command will not close VA properly and the simulated and recorded data is lost.
To enable the remote control mode, add a fourth parameter. A Matlab code snippet to launch it could look like this:
<pre><code>vaserver_path = which( 'VAServer.exe' );
va_syscall = [ '"' vaserver_path '" localhost:12340 VACore.ini remote_control_mode &' ];
system( va_syscall );
pause( 1 )
va.connect
% Run your scene ...
va.shutdown_server
va.disconnect
</code></pre>
The pause is required to give VA enough time to instantiate all modules (e.g. sound card sometimes needs a while) and reach a status where client connections can be accepted.
A pause of 1 second before a connection can be established usually suffices, but adjustments may be required in some cases.
Depending on the amount of data that must be exported, another pause after shutdown may be needed until the WAV files are accessible and, e.g., can be loaded in Matlab for further processing.
<blockquote>Note: this feature is available since v2020a.</blockquote>
</p>
</section>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment