FORUM CTRLX AUTOMATION
ctrlX World Partner Apps for ctrlX AUTOMATION
03-26-2024 08:36 AM - edited 03-26-2024 08:39 AM
Dear all,
I have successfully set up the CtrlX app build environment from within CtrlX Works, and have compiled one of the sample applications.
But I am missing the SDK / API documentation. The question is probably silly, but I just can't find it. I only have found the documentation at https://docs.automation.boschrexroth.com and the guides at https://boschrexroth.github.io/ctrlx-automation-sdk/overview.html
However, both of them do not contain a single word about the actual API (functions and data structures) the SDK itself and the various apps provide. To give one random example, I have seen the types
comm::datalayer::DlResult
comm::datalayer::IClient
in the C++ hello.plc sample, but I couldn't find documentation about them.
Where can I find descriptions for all API types, constants, classes and functions the SDK provides, including the APIs and data streams each app provides?
Thank you very much, and best regards,
Binarus
Solved! Go to Solution.
03-26-2024 12:17 PM - edited 03-27-2024 03:51 PM
Hi Binarus,
you can look directly into the headers which are included in the SDK (datalayer_system.h and datalayer.h). Or for more context you can have a look at the Data Layer chapter in the manual (link).
Best regards,
Nick
03-26-2024 04:40 PM - edited 03-26-2024 04:42 PM
Hi @nickH,
thank you very much for your reply. However, if I click the link you gave, the browser is redirected to
https://docs.automation.boschrexroth.com/doc/0/not-found/latest/iv/
and consequently the website that appears is nearly empty and does not contain something useful.
In the meantime, I have found the documentation for C# and for Python myself. The version for C# is at https://apps.boschrexroth.com/docs/ctrlx/csharp/html/. I find it nearly unusable, because there are no explanations about functions and their parameters, but at least it's a starting point where available classes are listed.
May I suggest that you place a link to it prominently on your Github site? It's the first thing developers need, but developers are generally not very delighted about having to work out class hierarchies, API functions etc. from header files or sample programs 😁 It would also be nice if you could add documentation like the one under the above link for the other available programming languages as well, especially for C++.
The lack of API documentation had nearly made us dump the CtrlX in favor of other products. I doubt that I'll be able to write a first app within a few days as required ... but let's see how it goes. In every case, your company would do itself a favor if somebody took the effort to raise the quality of the documentation to the level of typical Linux API manpages, e.g., https://man7.org/linux/man-pages/man3/printf.3.html (random example; compare it with the documentation of any arbitrary function of your SDK, e.g., ReadAsync() (https://apps.boschrexroth.com/docs/ctrlx/csharp/html/interfaceDatalayer_1_1IClient.html#aecf60d66247...)).
Apart from the catastrophic (nearly non-existent) API documentation, I find the overall approach of the CtrlX system and the development environment very good. Cross-compiling in VMs that are operated via SSH is a good idea, given that your recommended editor (VS Code) handles that without problems, and given that most developers are using VS Code anyway (at least for minor tasks, if not for their main job).
Best regards,
Binarus
03-27-2024 08:44 AM
Something seeme to wrong with the link. We will check that.
The data layer doumentation is part of our "ctrlX CORE, Runtime 02VRS, Application Manual".
03-27-2024 03:49 PM - edited 03-27-2024 03:50 PM
Thanks very much for your feedback. I will forward it.
The link I sent was to a chapter in the official docu of the ctrlX OS runtime. The link @CodeShepherd shared.
I can recommend you to look at these C++ samples to get started with the ctrlX Data Layer:
Please feel free to ask here in the forum, if you need support.
03-28-2024 11:00 AM - edited 03-28-2024 11:00 AM
Thanks for your help.
FYI, the link suddenly was working correctly yesterday; I guess that was due to actions at your side. But today it fails again (just tried, same problem as two days ago).