LLExec Ubuntu x64

From Axel Public Wiki
Jump to navigation Jump to search

LLExec for Ubuntu x64 usage instructions

Prerequisites

  • Configure an Ubuntu x64 machine

Tested on:

  Ubuntu x64 16.04 LTS (4.15.0-66-generic)
  Ubuntu x64 18.04 LTS (5.0.0-23-generic)
  • If ethercat is needed, an ethercat capable ethernet card is required in addition to the normal network device used for TCP/IP communication.

This is tipically done by using the integrated LAN device on your PC motherboard for Ethercat and other network cards (eg. external Pci-X network card device) for TCP/IP network connection (needed by LogicLab GDB connection).

  • "net-tools" package should be installed (use "sudo apt-get install net-tools")

Installation

  • Download the LLExec_x.y.z_x64_Ubuntu.tar.gz and extract it to /data/plc on the Ubuntu machine.

Execution

  • Launch "sudo ./LLExec" from /data/plc folder to start LLExec with root privileges. (Without license it will start in DEMO mode).

By default LLExec loads the configuration stored in "LLExecLinux.conf". If you need to load a different configuration file use "LLExec -f <filename.conf>"

LogicLab usage

  • Execute LogicLab from a Windows machine connected to the same network of the LLExec Ubuntu machine.
  • Create a new project using the LLExec PLC runtime (x64_Ubuntu) target
  • Configure the GDB connection using the IP address of the Ubuntu machine (eg. 192.168.1.10), port 5000.
  • Connect to target with the upper left button

Ethercat Configuration

  • The network interface that will be used with ethercat needs to be clean from every protocols. Tipically this is done disabling every checkbox from "Edit Connections" in Ubuntu (thus disabling DCHP/IPv6/WoL etc..)
  • To let LLExec know which eth interface to use for Ethercat, file "LLExecLinux.conf" needs to be edited:
<plugin filename="./LLXPlugin_EtherCAT.so">
     <EtherCAT port=[eth device name]|[port number]
</plugin></nowiki>

If you use [port number] you can specify eth interface number. (Eg: port="0" will use eth0 device for ethercat)

If you use [eth device name] you can specify eth interface name following the new naming convention of recent Ubuntu distributions. (Eg: port="enp0s31f6" will use enp0s31f6 device for ethercat)

  • use common "ifconfig" command to know the current names of your network interfaces you can just

Ethercat Master example

  • Import an .esi file with the command "Tools->Import ESI".
  • Click on resources tab of LogicLab, then select the "Ethercat" node and enable it with the checkbox.
  • Right click on the "main network" ethercat node and select "add" to add your imported ethercat device.
  • A new node for the ethercat device will appear, configure it as you like.
  • Save, compile and download the project to the target.