Support : Knowledge base

Knowledge Base

Welcome to OPAL-RT’s Knowledge Base

OPAL-RT offers a repository of support information for optimal use of its technology.

Loading…

Please note that OPAL-RT knowledge base is not fully optimized for mobile platforms.

For optimal experience, use a desktop computer.

Reference Number: AA-02220 // Views: 8 // Created: 2023-08-30 10:12:44 // Last Updated: 2023-08-31 10:13:46
General Article
[EXata] How to Connect an External Device to EXata? + FAQ

[EXata] How to Connect an External Device to EXata?

As a recall, eno2 is usually by default migrated to the ns_exata namespace for the license check, however there are a few more steps required to setup an external device with EXata. This article explains how to connect an external device to EXata (with RT-LAB and HYPERSIM).




Procedure:

Step 1: When no model is running on the simulator, connect with MobaXterm and type the command:

ip addr show

This will list all the interfaces available. Write done which one you want to use. In the example below, there is no quadport, so we can only use eno2.


Step 2: Configure the ip address of the port that connects to the external device using:

opal_network_configurator

As a recall, if it is a local network, they need to be in the same network range. In this example, the external device (the Raspberry PI) has an IP address of 10.10.1.101, so we will configure eno2 to be 10.10.1.99.



NOTE: If there is no cable connected to the port, the configured IP address will not display.



NOTE: After re-running the opal_network_configurator, you might need to disable IPv6 again. Follow this KB for more information [EXata] 'EXata-CPS Configuration Failed...' Error at Load / How to Disable IPv6 on the Simulator



Step 3: Connect the external device to the port in question

NOTE: Consult the System Description Document of your simulator or the wiki to locate where the port is physically connected. In this example, it is an OP5705XG, so eno2 is located just above eno1:



IMPORTANT!: Some of the motherboards support only 1Gbps links! Therefore, once the device was connected, if there are not LED turning on, it might be a speed mismatch and a switch will need to be added between the two. The switch will do the negotiation and handle the different speeds.

Once the device is connected, type:

ip addr show

Again in MobaXterm and confirm that the IP address is properly configured (and that the interface is up). 


We should also be able to ping the external device at this point:


Step 4: configure the EXata CPS Configurator to add the ARP Entry

For this step, we need the MAC address of the port for the external device. For instance, with the Raspberry Pi, we can remote connect to it and type:

ip addr show

since it is also a Linux-based system.


Alternatively, we can also use tshark and Wireshark, to find the MAC address.

From MobaXterm, open one SSH session to the simulator and start to ping the external device (do not stop it).


Then, open a second SSH windows and type:

tsark -i eno2 -w <name_of_file>.pcap

wait, maybe 30-60 seconds before pressing CTRL-C to stop the recording.

Afterwards, you can download the file and open it with Wireshark. With a bit of luck, you captured the ARP request (or something similar) and can find the MAC address from it.



Once we have the MAC address, then we can configure it in RT-LAB or HYPERSIM in the EXata CPS Configurator.


In RT-LAB:


In HYPERSIM:


IMPORTANT: Do not forget that at least one vethX port needs to be defined (and that driver used), otherwise the RT-LAB / HYPERSIM will not configure the ns_exata namespace.

When loading the model, you should see the following line:

ip netns exec ns_exata /sbin/arp -s <ip address> <MAC Address> -i eno2

Example in RT-LAB:



Example in HYPERSIM (in the HypConsole):