Dear Community User! We have started the migration process.
This community is now in READ ONLY mode.
Read more: Important information on the platform change.

howto-howto-1444x512

Connect UA.TestClient to ctrlX UA Server

marcusX
Established Member

This is about how you can connect the Bosch Rexroth UA.TestClient to a ctrlX embedded UA Server.

Prerequisites

Install UA Server snap on your ctrlX if not already installed.
Download latest UA.TestClient here.

Create UA.TestClient Certificate

On first startup of the application you were asked to create a new application instance certificate for the UA.TestClient.
Ensure the Key Size Rsa2048 and Hash Algorithm Sha256 using extended options revealed by button <Advanced>. 

Press <Create> to create the certificate pair.

Initial Connection

Start UA.TestClient and connect

Example URL's

Device  URL
ctrlX CORE
e.g. opc.tcp://192.168.1.1:4840
ctrlX COREvirtual with Network Adapter opc.tcp://192.168.1.1:4840
ctrlX COREvirtual with Port Forwarding (with Bosch VPN in Mobile Office)

opc.tcp://127.0.0.1:4840

If you use Port Forwarding, please change 8840:4840 to 4840:4840 in crlX WORKS before starting your ctrlX COREvirtual.

 

Check permission UA Server access  of your current user. The default user boschrexroth should have admin rights.

2020-03-26_07h55_34.png

Enter your ctrlX IP and credentials like shown below and press <Find>.

Choose one of your preferred endpoint by policy (recommended: SignAndEncrypt Basic256Sha256. Not supported yet: Aes256_Sha256_RsaPss)

Enter your username/password credentials and press <OK>.

2020-03-25_11h23_33.png

Now you have to trust the server's certificate manually.

Press <Trust> and check <Save Certificate in TrustList>

2020-03-25_11h23_47.png

You should get an <BadSecurityChecksFailed>  error from server, because the server is not trusting your certificate by default.

So we have to do same on server side.

 

2020-03-25_11h20_03.png

Login into your ctrlX website, navigate to Settings → Certificates & Keys and press the <Check> Button on the right pane to trust your client certificate.

2020-03-25_11h20_19.pngReconnect: Done, your connection should be established!

2020-03-25_11h21_49.png

Have fun using the UA.TestClient !

smueller
smueller
Hi, I am Sebastian and I work as Senior Software Developer and Product Owner of the ctrlX OPC UA Software Team. We develop for you our popular ctrlX OPC UA Apps Server, Client and Pub/Sub. Please contact me if you have questions regarding our Apps and Solutions.
10 Comments
DmitryKremnev
New Poster

Nice instructions. Really works with acess to info abot server status, but how can I acess to variables from Data Layer?

I can see It's structre, but not Values for the fvariables from  motion or PLC app, Any additional parametrization of OPC UA Server App or Data Layer Itself are necessary ?

Anonymous
Not applicable

The application is throwing an exception when I want to create a certificate. Can it be that a reference is missing?



EXCEPTION (TypeLoadException)
Could not load type 'UnifiedAutomation.UaBase.CertificateFactory' from assembly 'UnifiedAutomation.UaBase, Version=3.0.9.0, Culture=neutral, PublicKeyToken=90c158e6f23d82c1'.
STACK TRACE
at UnifiedAutomation.UaBase.WindowsCertificateFactory.CreateCertificate(String storePath, CreateCertificateSettings settings)
at Rexroth.UA.TestClient.UI.CreateCertificateDialog.OkButton_Click(Object sender, EventArgs e) in D:\Jenkins\workspace\app.opcua.testclient\UA.TestClient\UI\Dialogs\CreateCertificateDialog.cs:line 217

D:\Jenkins\workspace\ is not my file location. I don't have a D:\ partition.

%CommonApplicationData%\Rexroth\PKI\own should be %ProgramData%\Rexroth\PKI\own?

(Yet I've got it working with the OPC Foundation UA Sample Client)

@DmitryKremnev

Right click and read, or make a subscription?

Or drag and drop in the DataAccess window?

DmitryKremnev
New Poster

@ Leon

I've made double click on needed variable from DataLayer folder in UA.Test Client. In thins case in DataAcess window I can see name of variable and nodeID, but there is no value and timestamp. Same thing when I tried to add this variable to IoT Gateway via OPC UA channel - no value returns. in addition when I tried ton connect with UA Expert test client There is also data type = Null. I guess problem is that there is no Data from DataLOayer on OPC UA Server on CtrlX or I should make additional parametrization of CtrlX OPC UA server or CtrlX Data layer to have this access?

Anonymous
Not applicable

@DmitryKremnev

You're already connected, so the user access should be good and the certificate also. No additional changes where needed. For the PLC I've added the symbols to the 'Symbol Configuration' in the PLC Engineering app, didn't check if it's needed with CtrlX.

LocalTime (i=17634) gave me a null value. CurrentTime (i=2258) was updating well in UTC time.

DmitryKremnev
New Poster

 

I will try separately with PLC's variables, but for motion variables (examle actual position of virtual axis) I did not have Value, only nodeID

smueller
Established Member

You can access normally data from datalayer without any special configuration. But if you use subscription please be aware to use for all apps (opc ua server, plc, motion, automationcore) the same version (e.g. 1.8.X or 1.6.X). You can normally still read the value with UA.TestClient by using right click on variable to read and choose "Read...". This is independent of the using app versions.

smueller_0-1617723113358.png

 

marcusX
Established Member

Please update the UA.TestClient to Version 1.0.1 which fixes the create instance certficate issue on first application startup 

UA.TestClient (boschrexroth.com)

Anonymous
Not applicable

@marcusX

Problem solved. Thanks.

aFouraker
Occasional Contributor

I have downloaded a new instance of the UA test client from the above links. When I open client I am not prompted to create a certificate and can therefore not retrieve the end-points. Is there a way to force the creation of the certificate? 

marcusX
Established Member

Hi aFouraker,

there are known issues with old certificates using not a key size of 2048 bit . You have to delete your old PKI store (C:\ProgramData\Rexroth\PKI) and restart UA.TestClient again to force the creation of a new self-signed key pair.

Must Read
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