Same program to more than one PLC

2019-09-24
2023-08-25
  • hence.persson - 2019-09-24

    Hello.

    I have a two PLCs that should have the exact same program and only want one PLC project saved to go online in both these PLCs but we are experience some issues..

    The PLCs are raspberry PI based with codesys runtime.

    If I take the project download to PLC 1 then connect to PLC 2 and download it I cannot longer go online on PLC 2 without downloading..
    I guess that the compileinfo file is updated as the bootproject is created when i download to PLC 2..?

    Later after downloading the project back and forth everything starts to work as expected..
    But I dont know why and soon we will have 3 PLCs with the same program and I dont want this trouble again..

    What is the procedure if I want the same program in several PLCs with only one project saved?

     
  • lassepc - 2019-10-14

    Hi

    If you use the "Generate Code" and save the project as "released" in Project Information ( read-only mode) does this make a difference?

     
  • Reinier Geers - 2019-10-16

    Multiple download

    or create offline a bootapp and copy to controller

     
  • hence.persson - 2019-11-05

    Reinier Geers hat geschrieben:
    Multiple download
    or create offline a bootapp and copy to controller

    Ok create offline bootapp seems fine..
    But what when I start upgrading the systems that are live around the world with an for example small online change..
    Will I be able to use the same project just doing the online change with update of bootproject or do I have to create an offline bootproject and copy that to the controller after every change to keep the PLC project intact?

     
  • hence.persson - 2019-11-07

    Now I have done some more extensive tests..

    Either I am doing something wrong or Codesys doesn't work for my type of application..

    If I have 100s of systems around the world that must be up and running and I have one standard program I want to be able to only save one project and go Online och each of those PLCs and do an online update.

    But when I do the compileinfo file gets updated and I only can do online changes on the most recent PLC all the others need a full download. This isn't working for me.. I have found one workaround that is saving the compileinfo file after download to each controller and when I want to go online in that replace the compileinfo file in the project folder with that one.. But when approaching 100s of controllers this isn't sustainable..

    Is there a way to work with several PLCs (Read hundreds) and keep just one project and be able to login to each of those PLCs after an online change..?

     
  • eschwellinger

    eschwellinger - 2019-11-16

    Hi,
    I think this is a typical use case for the CODESYS Automation server.
    You upload one application to the server, deploy it to your 100 plc's.

    For doing online change - ( this need to be checked). I think it may work
    if you untag then 'synchronize application' then you could login by CODESYS to the plc and do the online change.
    Sure later then you need to deploy the full application to your devices by the server again.

    At the moment login-via-automation server to your plc is under development ( not available) but if this will available
    I think this will meet your requirement. But i think you could test already if this works if your plc's are local acceisible
    to verify if your online change use case already is how you expect to have it.

    BR
    Edwin

    IMG: synchronizeApp.png

     
  • i-campbell

    i-campbell - 2019-11-17

    For online edits, CODESYS generates a new .compileinfo, so you are right that at the moment to do repeated online changes you need to have a sperate .compileinfo stored for each controller.
    One way is to store the .compileinfo in the controller using "Download Source To Controller".

    Your change procedure is now:
    Make offline changes and test in office. (Vn+1)
    Connect to site controller, upload source. (Vn)
    Open Vn+1 project with the Vn compile info.
    Online change.
    Make sure "include compileinfo" is ticked in Project Settings > Source Download.
    Download Source to Controller.

    If you are worried about source protection, you can encrypt or password protect your project. You could also just save the .compileinfo to the controller from Device > Files.

    I may be wrong but I think online change is not yet available in the Automation Server. It does a full Download. If this is OK that it does a full download though (as you have persistent variables, and your machine is always stopped for a download) then current version will save you a lot of man hours. If not, wait for the online changes feature. It will be worth having a look at it anyway and getting used to it.

     
  • eschwellinger

    eschwellinger - 2019-11-17

    Hi,

    sure the CODESYS Automation Server does not support (direct) online change at the moment
    but with the help of CODESYS this works like charm.

    How does it work?
    1. push the application/project to the CODESYS Automation server
    2. deploy it to the plc's
    .
    you want to change/online change the application:
    a) remove the sync tag in the server(see screenshot from the last answer)
    b) open the project from server apply the change in CODESYS - and login to the plc you want to change -> online change
    now you have the changed application in the plc up and running- next step is to puh/sychrnoize the project to the server.
    Then if you have the next chance to restart/update the plc - update the application by the server and enable sync again
    until that it works with your online changed project.

    Hope this is a bit more clear how this could work.

    To source download to the plc is the other way it works, but doing this on 100plc's is a huge effort and you have not really one source,
    so i would prefer solution 1 with the CODESYS Automation server.

    BR
    Edwin

     
  • eschwellinger

    eschwellinger - 2019-11-19

    Hi,
    I have to correct myself.
    For the online change case - would recommend to wait til the server could do the compile on the server.

    So the only way is to write the source( if needed encrypted) to the plc.
    BR
    Edwin

     
  • hence.persson - 2019-11-23

    Thanks for your answers.. Will investigate the possible solutions.

     
  • kreisfilho - 2023-08-23

    Hi,
    How can I assign a monitor (non touch) connected to a Raspberry pi (via HDMI) as visualization output?

     
  • eschwellinger

    eschwellinger - 2023-08-24

    just open http://localhost:8080
    in Chromium then it will show the webvisu ( sure you need to this in your CODESYS Application)

     
  • jegerjon - 2023-08-25

    I guess you could archive the project, open the archive and go online. Is that suffiecient for your use case?

     

Log in to post a comment.