Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched. Close

Raspberry PI - update aplication on SD Card without Codesys connection

lingvo
2020-09-28
2020-09-28
  • lingvo - 2020-09-28

    Hello all
    I have deployed Codesys application on Raspberry Pi and it runs there automatically when RPi starts. All is OK so far.

    Now I have added some feature to the project and want to update it on RPi, but the problem is that I have physically no possibility to connect to Rpi with Codesys and install this update.

    So I need to export the app from Codesys and manually copy it to RPi SD Card. Can someone help me with that?
    I need following info:
    - Which file(s) in the project is a compiled execution app for RPi?
    - Where to copy it on SD Card?
    - Is it possible to do it by taking the SD Card out of RPi and opening it on Windows PC, or I need to copy over Network SMB?

    Thanks. Would be glad to see this way of update in the documentation, as I haven't found it there.

    Regards

     
  • eschwellinger

    eschwellinger - 2020-09-28

    Hi,
    from my point of view to use CODESYS Automation Server for this task is the
    best and easiest solution.
    The only precondition is to have on PI side network a device with Internet access.

    I would give this a try.
    https://www.youtube.com/watch?v=iiPKyyO4M00

    remote Login with CODESYS to your PI:
    https://www.youtube.com/watch?v=8KLywg51Xyk

    Webvisu via Server:
    https://www.youtube.com/watch?v=Kyf9bCpPa6s

    Sure if you need the harder way ( in case you have no retains and no additional application generated files:

    1. You need to the Application.app and Application.crc ( in case this is the name in your device tree)
      to the PI
      These files are located in:
      /var/opt/codesys/PlcLogic/Application/
    2. you need to give the name of the Application in the section CmpApp

    [CmpApp]
    .
    .
    Application.1=Application
    .
    .
    You could not access this path (/var/opt/codesys/PlcLogic/Application) by access the SD card under Windows,
    if you want to do this:
    you need to copy the files later from /boot/ ( this is what you see when you plug the SD card to your Windows pc -> /var/opt/codesys/PlcLogic/Application

    Hope this helps.

    Best Regards
    Edwin

     
  • lingvo - 2020-09-28

    Thanks Edwin. Harder way seems the right to go for me. Just question about persistent variables. Will they be lost?

     
  • lingvo - 2020-09-28

    But actually if CODESYS Automation Server is going to stay free - I will try it. Do I just need Internet connection on my Codesys RPi?

     
  • eschwellinger

    eschwellinger - 2020-09-28

    Hi,
    a) if you have retains - Application.ret needed to be copied too.

    b) Either a internet connection on the PI (you need to install the EdgeGateway arm hf on the PI), or if there is any other device in the network with internet connection - install the Edgegateway there.

     

Log in to post a comment.