When you purchase an automation system it is important to define in your contract who will own the Application Code.
Some vendors may claim copyright over the application code that they provide. In general this is not acceptable.
The application belongs to the end user and so must the code.
There are exceptions, such as code within standard machine controllers, but that code is not written specifically for the project
So generally you, the end user will want to ensure that once the project is running, you own the application code.
That is only fair, since it is based on your process and you will need it to be able to support the system in future.
It is essential that your contract is clear about this, especially as some may claim that copyright laws mean they own the code.
This web is funded by advertising, but the advertisers have no influence on the web site. Please visit them.