Teilen Sie Ihre Erfahrunge und Wünsche mit uns und anderen Usern!

0

6.3 version problem with S7 TCPIP

Hi all! 

I am using the latest reavirtual. However, I am having problems with S7 TCPIP because the component displays "waiting to connect" and other error messages, and communication with S7-1200/1500 does not work, although it works with version 6.0.3. What could be the problem and what could be the solution? Thank you in advance for your hel

0
Fixed

realvirtualController CPU 500ms+

陈喜成 3 months ago in realvirtual.io Starter and Professional updated by Support 2 months ago 2

1.realvirtualController CPU 500ms+

private static void PreFixedUpdateCallback()
{
_fixedUpdateFrameCount++;

for (int i = 0; i < _preFixedUpdateHandlers.Count; i++)
{
if (_preFixedUpdateHandlers[i] != null)
{
try
{
_preFixedUpdateHandlers[i].PreFixedUpdate();
}
catch (System.Exception e)
{

//The performance analyzer determined that the `Object.FindFirstObjectByType()` call was taking more than 150ms++, so it was moved inside the catch block to avoid errors on every refresh.
var controllerInstance = Global.realvirtualcontroller ?? Object.FindFirstObjectByType();
Logger.Error($"Error in PreFixedUpdate: {e.Message}", controllerInstance);
}
}
}
}

//! Callback executed after FixedUpdate
private static void PostFixedUpdateCallback()
{
for (int i = 0; i < _postFixedUpdateHandlers.Count; i++)
{
if (_postFixedUpdateHandlers[i] != null)
{
try
{
_postFixedUpdateHandlers[i].PostFixedUpdate();
}
catch (System.Exception e)
{
//The performance analyzer determined that the `Object.FindFirstObjectByType()` call was taking more than 150ms++, so it was moved inside the catch block to avoid errors on every refresh.
var controllerInstance = Global.realvirtualcontroller ?? Object.FindFirstObjectByType();
Logger.Error($"Error in PostFixedUpdate: {e.Message}", controllerInstance);
}
}
}
}


2.The bug in the MQTT code has been fixed in the reply.

MQTT IN/OUTPUT ERROR [Repair] / realvirtual.io Forum / realvirtual.io (formerly game4automation)

0
Planned

HelloWindow occasionally blocks CI builds when running Unity in batchmode

Ramon Janousch 3 months ago in realvirtual.io Starter and Professional updated by Support 3 months ago 3

Hi,

when we trigger our build pipeline and run tests or build the project via script, from time to time the HelloWindow pops up and blocks the pipeline run.

Context

  • We are using realvirtual in a Unity project that we build and test via Azure DevOps.

  • Unity is started from the pipeline in batchmode (no user interaction, headless build).

  • Typical commands are like: -batchmode -projectPath <path> -runTests or -batchmode -projectPath <path> -buildWindows64Player <path> ...

Most of the time this works fine, but occasionally the HelloWindow appears during startup and seems to wait for user interaction. Since this happens on a build server without UI interaction, the process just hangs and the entire CI job times out.

Expected behavior

  • When Unity is running in batchmode (CI environment), realvirtual should not open the HelloWindow at all, or

  • There should be an option (e.g. a setting, scripting define symbol, or asset menu option) to completely disable the HelloWindow for automated builds/tests.

Actual behavior

  • Infrequently, the HelloWindow still appears during CI runs, even though Unity is started in batchmode.

  • This blocks the build/test pipeline until it times out.

Questions / requests

  • Is there a recommended way to disable the HelloWindow for CI/batchmode runs?

  • Could realvirtual internally check for Application.isBatchMode and skip showing the HelloWindow in that case?

  • If there is already a setting or flag to turn this off, could you point me to the correct configuration?

Thanks a lot in advance!

Image 1447

Answer
Support 3 months ago

RE: HelloWindow occasionally blocks CI builds when running Unity in batchmode


Hi Ramon,

Thanks for the detailed report. You're right - we check for UNITY_CLOUD_BUILD but we're missing a check for Application.isBatchMode which is why it can still appear when running Unity with -batchmode for CI pipelines.

Workarounds until the official fix:

Option 1: Add DEV define to your build command (Recommended)

Unity.exe -batchmode -projectPath C:\Project -runTests ... -defineSymbols DEV

Option 2: Set the define via script before tests run Create an editor script that runs before your tests:

[InitializeOnLoad]
public static class CISetup
{
    static CISetup()
    {
        if (Application.isBatchMode)
        {
            // Prevents HelloWindow from showing
            PlayerSettings.SetScriptingDefineSymbols(
                NamedBuildTarget.Standalone, "DEV");
        }
    }
}

Option 3: Patch locally In Assets/realvirtual/private/Editor/OnPostProcessImportAsset.cs line 142, change:

if (Game4AutomationImport && !Application.isPlaying)

to:

if (Game4AutomationImport && !Application.isPlaying && !Application.isBatchMode)

Fix: We'll include this batch mode check in the next release.

Thanks for reporting!

0
Answered

How to solve the complie error when realvirtual io package install in HDRP project

Seokhyun Lee 3 months ago in realvirtual.io Starter and Professional updated by Support 3 months ago 1

Dear,

Thanks for your support.


I have another problem when realvirtual io package install in HDRP project.


1) Unity 6 LTS Version (6000.0.62f1)

2) Create HDRP Project

3) Install Reavirtual IO Digital Twin Professional (6.0.8)

→ Compile error occurs (see image below)


4) Switch to HDRP Menu (in realvirtual menu)
※ Render Pipelines > Switch to HD render Pipeline (HDR) > Path Tracing & Ray Tracing (Both Try)

→ Compile error still occurs (see image below)


I would like to request guidance on how to resolve this issue so I can use realvirtual io in HDRP project.

Best regards,

Seokhyun Lee

Image 1444

Image 1445

Image 1446

Answer
Support 3 months ago

Hi,

usually you should not change render pipline. Some special materials for highlighting, the bottom, the fences... wont work in HDRP. If you are working with a totally new scene and taking care about the materials and rederers yourself it is ok. Also switching is a very complicated process.

I am sending you in a private message a beta of next release where the compile errors are gone away. If you are having issues when switching one project from URP to HDRP sometimes closing Unity and deleting the Library folder and restarting helps.

The private message will follow. 

Best regards
Thomas

0
Fixed

MQTT IN/OUTPUT ERROR [Repair]

陈喜成 3 months ago in realvirtual.io Starter and Professional updated by Support 2 months ago 2

0
Answered

[Not Solved] Compile Error after realvirtual AI Builder Package Installation with Unity 6 LTS Version

Seokhyun Lee 3 months ago in General Questions updated by Support 3 months ago 6

Dear,

Sorry But,

The problem is not solved.

I'm having trouble again with a compile error after installing RealVirtual AI Builder with Unity 6 LTS version.


1) Unity 6 LTS Version (6000.0.62f1)

2) Install RealVirtual IO Digital Twin Professional (6.0.8) & Simulation 6 (6.0.6) → OK

3) Install RealVirtual IO AI Builder 1.0
Compile error occurs (see image below)

I would like to request guidance on how to resolve this issue so I can use RealVirtual AI Builder.

Image 1436

Image 1437

0
Fixed

S7 connection - get_gameObject can only be called from the main thread.

efr 3 months ago in realvirtual.io Starter and Professional updated by Support 3 months ago 3

Hi, 

When trying to make an S7 connection (new empty scene) in the realvirtual.IO starter kit I have following issue.
The connection is OK and running in Scene mode, but once in Game mode, I see I have following error:

Connection failed: get_gameObject can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.
 

In the connection view of TIA portal I see a lot of connection active.

Does anyone has any advise on how to solve this?

Unity version 

Image 1433

siemens CPU 1515-2-PN

Image 1429

Image 1430

Image 1431

Connection failed: get_gameObject can only be called from the main thread.
Constructors and field initializers will be executed from the loading thread when loading a scene.
Don't use this function in the constructor or field initializers, instead move initialization code to the Awake or Start function.

Image 1432

0
Under review

How to build a gantry

Ramon Janousch 4 months ago in realvirtual.io Starter and Professional updated by Support 3 months ago 1

Hi everyone,

I’m trying to figure out the best way to model a gantry in realvirtual and I’d like to check if my approach makes sense.

Mechanical setup

  • Think of a classic gantry crane

    Image 1420

  • In my machine I have

    • Two separate X-axes at the bottom (front and back rails – green arrows).
      They can move independently in X, but in normal operation they should behave like a gantry pair.

    • On top of them sits a Y-axis stage (blue arrows) that moves sideways.

    • Image 1421
  • The Y-stage is physically connected to the X-axes via joints in Unity.

  • The CAD / Unity hierarchy is basically flat – the Y-stage is not a child of one of the X carriages, so I cannot rely on parenting to move it together with X.

Control side

  • I have separate drives / axis values for:

    • X-front

    • X-back

    • Y-stage

  • The requirement is:

    • When X moves, the whole Y-stage must move with it.

    • Y should still have its own motion relative to the gantry.

Questions

  1. What is the recommended realvirtual setup for this kind of gantry?

  2. How should I combine this with joints?

    • Should I keep the joints at all, or would you recommend a purely kinematic Axis/Drive setup for this use case?

Any hints, best practices, or “don’t do this” stories are very welcome.
Thanks in advance!

Answer
Support 3 months ago

Hi,

Thanks for reaching out!

For building hierarchical structures in your simulation, we'd recommend using parenting or Groups combined with Kinematic — you can find detailed guidance here: https://doc.realvirtual.io/components-and-scripts/motion/kinematic

One of the nice things about this approach is that it gives you flexibility regardless of how your Unity hierarchy is currently organized. Moving drives without physical joints also tends to provide better stability, which is especially helpful when you're receiving cyclic position updates from controllers.

As a tip that might simplify things: from a kinematic perspective, X-Front and X-Back effectively function as a single drive, so you may not need to model them separately — that could save you some setup work!

Let me know if you have any questions or if I can help clarify anything further.

Best regards
Thomas

0
Under review

Source a MU without rigid body component?

MarkH 4 months ago in General Questions updated by Support 3 months ago 2

I would like to simulate pick and place processes of parts by using kinematics without physics. I am struggling with my understanding of the MU, Source, Grip/Fix concepts.

What do I have to do to make a sourced MU part a subcomponent without physics?