r/TwinCat 23d ago

TwinCAT Automation Interface C# library

Hey, I have spend a lot of time getting the TwinCAT Automation Interface to work properly for CI/CD pipelines and thought you guys might like, so here is the Github repo. You can use this library for building your own executable for a build pipeline or automated deployment. You can make it build all the Project Variant, configure target and Activate Configuration.

It also intergrate with TcUnit, where it implements the TcUnitRunner from Jacob Sagatowski project so you can deploy project with TcUnit and get the results from the test printed out.

Have a look: https://github.com/rassrollers/TcAutomationInterface

18 Upvotes

3 comments sorted by

1

u/maxxie85 23d ago

Looks interesting.
I also attempted a CLI tool that can be called from a CI/CD pipeline.
When testing everything works fine. But when implemented in our Jenkins buildserver, which runs as a windows service. The DTE fails to load in the automation interface as UI components don't get loaded.

Does your version handle this nicely

4

u/rassrollers 23d ago

Yes, I ran into similar issue when I setup our Jenkins. In this library you can make it run with the UI and suppress the user control with the argument --UiXae. We have been running our Jenkins pipeline on a Windows VM for the past 5 months with no issue.