Unable to open Raspberry Pi projects - IoDrvGPIO library

nlsri
2022-02-05
2022-02-09
  • nlsri - 2022-02-05

    I am just trying to get started with the Codesys 3.5 SP17 Patch 3 software and the Raspberry Pi 4.2.0.0 package, and while I am able to communicate with the Pi, download the package and start the runtime application, I am not able to open any projects. All of them give multiple errors related to this one particular library. I have installed all the libraries in the "CODESYS Control for Raspberry PI > 4.2.0.0 > Libraries" folder, which includes IoDrvGPIO. Does that path have to be included somewhere? If I try to add that in "Edit Repository Locations", it gives an error message about the folder "not appearing to be the root of a repository". Oddly enough, the default "System" repository is shown as being at C:/ProgramData/CODESYS/ManagedLibraries, and that does not even exist. Am I supposed to create that and move the libraries there? Any help would be greatly appreciated.

    [ERROR] GPIO: Library Manager [CODESYS_Control_for_Raspberry_Pi: Plc Logic: Application]: Could not open library '#CmpTraceMgr'. (Reason: The placeholder library 'CmpTraceMgr' could not be resolved.)
    [ERROR] GPIO: Library Manager [CODESYS_Control_for_Raspberry_Pi: Plc Logic: Application]: Could not open library 'IoDrvGPIO, 1.0.1.10 (3S - Smart Software Solutions GmbH)'. (Reason: The library 'IoDrvGPIO, 1.0.1.10 (3S - Smart Software Solutions GmbH)' has not been installed to the system.)

     
  • eschwellinger

    eschwellinger - 2022-02-05

    you need to update the devices - this means:
    1. rightlick in the device tree to the Raspberry Pi-> Update device to 4.x.x.x version
    2. righclick on the GPIO's -> update device to 4.x.x.x version
    3. update compilerversion and update visuprofile to newest
    thats it!

     
    • nlsri - 2022-02-05

      I think that I have crossed this hurdle, but am running into a new one. The Scan Network in Communication Settings does not seem to show the Pi, even though Tools -> Update Raspberry Pi shows it. The Gateway-1 shown there seems to be a local host with port 1217. Am I supposed to add another gateway with the IP address of the laptop Ethernet port with a specific port number and protocol?

       

      Last edit: nlsri 2022-02-05
  • eschwellinger

    eschwellinger - 2022-02-06

    If you are using current version of Bullseye - there is a problem that the runtime stops after a few seconds of running, working on a fix for this.
    The only change is to use an older version - then current released on 28.1

     
  • nlsri - 2022-02-06

    Yes, the latest release from Jan 28th was what I had flashed on the SDHC card. Is there a recommended release, perhaps Nov 8th, and is the Legacy version better? Will Codesys work with the Lite versions?

     

    Last edit: nlsri 2022-02-06
  • eschwellinger

    eschwellinger - 2022-02-06

    yes, works usually with all versions..except at the moment with this bullseye release from 28.1

     

    Last edit: eschwellinger 2022-02-06
  • nlsri - 2022-02-08

    I installed the earlier version of Bullseye and while things went better, I am still unable to log on to the device. The Pi shows up in the Scan Network, and when selected, it asks for a user name and password. Are they the default pi and raspberry, or something else? The other issue is that the active path cannot be set, it keeps coming back with the "No device is responding to the scan request" error message, even though the right IP address is selected in the device selection pull-down. If I can install the package, query the system info, reboot the target, and see the Pi in the network scan, why are there so many issues with setting the active path? I looked at https://help.codesys.com/api-content/2/codesys/3.5.13.0/en/cdshandlingusermanagementonplc/, and tried to follow the steps there. But I get a "Gateway not configured properly" message if I try to go to the "Users and Groups" tab and do a refresh.

     

    Last edit: nlsri 2022-02-08
  • nlsri - 2022-02-08

    I tried uncommenting that line in the cfg file, and it still asks for a device user name and password. This doesn't seem to be an intuitive system to navigate and manage, way too many stumbling blocks just to open a demo project and get it to run, let alone create new projects and get them working!

     
  • wollvieh

    wollvieh - 2022-02-08

    i agree. These security changes in the new release of Codesys are not userfriendly...

     
  • eschwellinger

    eschwellinger - 2022-02-09

    hm you'll be asked on first login to specify a username and a password.
    From my experience most of the time the users don't know the password they created themselves the second time they login - try pi - etc to login instead of their own pw.
    That's maybe the whole story.

     
  • nlsri - 2022-02-09

    I recall one screen where it asked for them, and entered the same pi/raspberry. I am just trying to get the demo projects going, that is all. How can this be reset or disabled? More importantly, how to resolve the gateway configuration messages or device not responding messages even when there is communication? I do not understand the logic here.

     
  • nlsri - 2022-02-09

    I think that the entry for the user name and password was done when I had the Pi with the latest Bullseye release, and now I am on the earlier Bullseye release. Are these user names and passwords stored on the Pi or on the host machine?

     
  • eschwellinger

    eschwellinger - 2022-02-09
    • on the pi
     
  • nlsri - 2022-02-09

    Thanks for the directives via the other email. Per the directions, I deleted the csv and csv_ files in the /var/opt/codesys folder on the Pi. The last line in the codesys config file is uncommented to disable user password management. Please see the attachments. If the device is "raspberrypi" in the network window, it keeps asking for the entry of a device user name and password even with this disabled, the popup window keeps coming up if I answer No. If I change the device from "raspberrypi" to the IP address, the error popup with the device not responding comes up.

     
  • eschwellinger

    eschwellinger - 2022-02-09

    your device in the device tree is the same than the online device type? Raspberry PI MC ? MC means Multicore versus Raspberry PI SL?

     

    Last edit: eschwellinger 2022-02-09
  • nlsri - 2022-02-09

    It is a Pi 3B, which is multicore, as opposed to the very early models or even the Pi Zero which is single.

     
  • eschwellinger

    eschwellinger - 2022-02-09

    in the project you have a Pi MC too...n the device tree?

     
  • nlsri - 2022-02-09

    Ah, that might be an issue! The example projects that I am trying to load seem to have SL in the tree. Is there a way to change them to MC? Also, why would that discrepancy not be flagged with a message? Is there also an issue with a SL project not being able to run on a MC Pi, I can understand that the opposite is not possible? Thanks.

     
  • eschwellinger

    eschwellinger - 2022-02-09

    they could not run on MC yes, rightclick in the devicetree - update device - select Raspberry PI MC.

     
  • nlsri - 2022-02-09

    Changed to MC SL in the project tree, but still getting the "No device is responding to scan request" message. The "Scan" in the Tools -> Update Raspberry Pi window works, it is able to get the IP address. The Scan Network works, it is able to find "raspberrypi" on the Gateway-1 (localhost, port 1217). Gateway icon shows green circle, but target icon has red circle, both with "raspberrypi" and with the IP address selection in the pull-down menu. I finally ended up setting the device user name and password, as otherwise that popup would keep showing up again and again, and know that they are correct.

     
  • eschwellinger

    eschwellinger - 2022-02-09

    from above screenshot I see you hav added to disable the UserManagament to your CODESYS PC for Control Win ( this is the plc on your desktop)
    you need to add this to the config file in the RasΓΌberry PI here by: (sure delete the csv files again):

    nano /etc/CODESYSControl_User.cfg

    [CmpUserMgr]
    SECURITY.UserMgmtEnforce=NO

     
  • nlsri - 2022-02-09

    That seemed to work, finally! Please see attached. Thanks for all the help, greatly appreciated. Will there be some changes so that we don't have to go through all these manual edits every time?

     
  • eschwellinger

    eschwellinger - 2022-02-09

    no never again πŸ˜‰

     

Log in to post a comment.