Error -383202 or -383200 when Executing FMU Models Continuously in LabVIEW Model Interface Toolkit

Updated Sep 4, 2026

You can execute a Functional Mock-up Unit (FMU) continuously on an NI Linux Real-Time target using the LabVIEW Model Interface Toolkit™ while preserving model state between iterations. This architecture is intended for applications that require deterministic, high-speed real-time execution inside a Timed Loop.
To avoid initialization errors such as -383202 or -383200, you must load and initialize the FMU only once before loop execution and unload it only after execution completes. Repeated loading or unloading within the loop can reset model state and lead to execution failures.
 
Requirements
  • LabVIEW Model Interface Toolkit™
  • FMI 3.0 Functional Mock-up Unit (FMU)
  • NI Linux Real-Time target (for example, PXI controllers)
  • Timed Loop architecture

  1. Place Load Model.vi before the Timed Loop. Load the FMU a single time before entering the execution loop.
  2. Place Initialize Model.vi after Load Model.vi. Initialize the model once before starting real-time execution.
  3. Read the model inport and outport paths. Retrieve and cache the required port references before entering the Timed Loop to avoid repeated lookup operations during execution.
  4. Configure a Timed Loop on the NI Linux Real-Time target. Select the 1 MHz clock source to achieve microsecond timing resolution when required by the application.
  5. Write model input values inside the Timed Loop. Update the required FMU inports during each iteration of the loop.
  6. Execute Take Model Time Step.vi once per iteration. Advance the FMU simulation by a single time step for each Timed Loop iteration.
  7. Read model output values after the time step. Retrieve the required outport values immediately after calling Take Model Time Step.vi.
  8. Maintain a single model reference wire throughout execution. Preserve the same model reference across all iterations and avoid branching or recreating the reference.
  9. Do not place Load Model.vi or Unload Model.vi inside the Timed Loop. Loading or unloading the model during each iteration can reset internal model state and may generate initialization errors.

Note: Place Unload Model.vi after the Timed Loop terminates. Release model resources only once when execution has completed.

By following this architecture, you can:
  • Run the FMU continuously in a real-time control loop.
  • Preserve model state across iterations.
  • Avoid repeated initialization of the FMU.
  • Prevent errors such as -383202 and -383200 that can occur when model loading and unloading are performed during loop execution.
  • Achieve deterministic execution on NI Linux Real-Time targets.

Next Steps

  • Validate Timed Loop execution timing on the target system.
  • Monitor FMU outputs to confirm state is maintained across iterations.
  • Review FMU-specific timing requirements before selecting the loop period.
  • Verify that Take Model Time Step.vi executes exactly once per iteration.