cancel
Showing results for 
Search instead for 
Did you mean: 

Connect application in WSL to DL in virtual CORE

Connect application in WSL to DL in virtual CORE

K-Zanaty
Member

Hello,

when I am trying to follow the descriptions within the python and goLang example projects on how to connect to the DL of a virtual CORE, it is not working for me.

First of all, I disabled the check on "SNAP" environment, as in WSL is was always true and returned "ipc://". The string address is not working with any IP I enter. Did anybody of you faced the same issue? It would speed up my development if I could run the code manually first instead of building and deploying the app every time.

Thanks and best,

Karim

6 REPLIES 6

nickH
Community Moderator
Community Moderator

Hi Karim, 

I never worked in a WSL, so I'm not sure if it can be a networking issue in the WSL environment. In a qemu-base environment the connection to a ctrlX CORE virtual works like this: 

  1. For a ctrlX CORE virtual in Network Adapter mode:
    tcp://<user>:<pw>@<ip-adress-of-ctrlX-CORE>

    example: tcp://boschrexroth:boschrexroth@192.168.1.1

  2. For a ctrlX CORE virtual in port forwarding mode: 
    tcp://<user>:<pw>@10.0.2.2?sslport=8443

    Remarks:
    * 10.0.2.2 is the IP address of the host (windows) from the point of view of the QEMU VM. (This is propably different to your WSL)
    * 8443 is the host port which is forwarded to the SSL port (=433) of the ctrlX CORE virtual

Best regards, 

Nick

nickH
Community Moderator
Community Moderator

To add one remark: 

I would recommend to use the ctrlX App Build Environment as a build environment. It is integrated in ctrlX WORKS and works similar like the ctrlX CORE virtual. It is a Ubuntu Server machine emulated with QEMU. 

Learn how to set it up: here

@nickH Thanks a lot! I used the ctrlX App Build Environment before. Unfortunately, it is failing to build (especially) the goLang examples when datalayer is involved. So I wanted to check if the same is happening on WSL and there it is working - at least the build process.

nickH
Community Moderator
Community Moderator

Hi @K-Zanaty 

I just tried to reproduce your error. I set up a fresh app build environment with ctrlX WORKS V2.4 ran the following scripts (from the folder scripts): "install-sdk.sh", "install-go.sh" and "install-cpp-aarch64-libs.sh". And I'm able to build the go-samples for amd64 and also arm64. 

@nickH I can only find V1.20 to download, where do I get V2.4? Is it a pre-release I need to get access to?

In this setup it fails with the messages I post below. I also need to edit the build-*.sh files to execute the snap commands as root. I tried setting up new Build environments multiple times, also reinstalling everything. I am using V1.20.8

2024-01-26 09:49:48.684 executed go version with output go version go1.21.6 linux/amd64
2024-01-26 09:49:48.687 :: + case x86_64-linux-gnu in
2024-01-26 09:49:48.687 :: + go build -buildvcs=false -o ../install/bin/ ./...
2024-01-26 09:49:48.748 :: go: downloading github.com/boschrexroth/ctrlx-datalayer-golang v1.3.0
2024-01-26 09:49:49.384 :: go: downloading github.com/google/flatbuffers v23.5.26+incompatible
2024-01-26 09:50:16.615 :: # datalayer.client/cmd/client
2024-01-26 09:50:16.616 :: /snap/go/10489/pkg/tool/linux_amd64/link: running gcc failed: exit status 1
2024-01-26 09:50:16.616 :: /usr/bin/ld: warning: libcrypto.so.3, needed by /home/boschrexroth/scripts/ctrlx-automation-sdk/samples-go/datalayer.client.simple/parts/client/install/usr/lib/x86_64-linux-gnu/libcomm_datalayer.so, not found (try using -rpath or -rpath-link)
2024-01-26 09:50:16.617 :: /usr/bin/ld: warning: libssl.so.3, needed by /home/boschrexroth/scripts/ctrlx-automation-sdk/samples-go/datalayer.client.simple/parts/client/install/usr/lib/x86_64-linux-gnu/libcomm_datalayer.so, not found (try using -rpath or -rpath-link)

 

nickH
Community Moderator
Community Moderator

Hi @K-Zanaty
V1.20 is the latest LTS (long term support) release, these versions are published once a year end of July. In between LTS versions we got early adopter releases, that are published every 4 months. See more information about our release cycle in: Release cycle of ctrlX OS, apps and engineering software

If you want to get access to the early adopter releases, see here how to do that: FAQ for ctrlX Store

You can still use V1.20 SDK and App Build Environment if you like, but there is one issue, when you want to use the App Build Environment and SDK V1.20. See my post in the forum.

Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist