(no subject)

Page 1.04 of 2.24
<< < 1 2 (Page 2 of 2)
  • alimans - 2023-09-17

    Hi Ingo,
    Thank you for your nice introduction. I have created a library successfully based on your prepared templates and now, I have following questions:
    1- How could I possibly debug my developed FB library that implementing the I/O driver interface library. This also can help me to check the data that are going back and forth between device description and the FB library to know better how things are working and which other options I have.
    2- I found out that some other device drivers have more tab pages in Codesys (comparing to default 5 tab pages in for example IoDrvFB), how could I generate and configure data in these pages?
    Thank you in advance for your kind answer.

     

    Last edit: alimans 2023-09-18
    • Ingo

      Ingo - 2023-09-21

      Hi Alimans,
      thanks for the feedback!

      1) To debug, you can easily set the compiler define "IoConfigLateInit". That will instruct our device object to execute the Init code of your driver in the first Task-Cycle. This way, you can easily set a breakpoint in your library and debug it.
      2) Which pages to you mean in detail? Most of them are just coming from specific configurator plugins. So when you see the configuration pages in EtherCAT or Profinet or s.th., those are developed specifically for this fieldbus.

      Cheers,
      Ingo

       
      • alimans - 2023-09-21

        Thank you for your kind respond, Ingo!

        1- The "IoConfigLateInit" trick got the job done! But, still for some functions like "IoDrvWriteParameter" I could not place break point.

        2- Regarding the page, as you set it correctly, I mean pages like EtherCAT and so on. A sample page for this you can find as attachment. So how could I write a plugin and use it in my IO Driver? Because my device uses several configuration and also has some diagnostic registers that would be perfect if I could show them to the user in a designed UI.

        3- In case of any problem in device or driver (for example disconnecting or cable unplug) How could I send errors to the codesys? What is the best practice to handle such a situation?

        Thank you again for your instructions!

         

        Last edit: alimans 2023-09-21
        • alimans - 2023-11-02

          Hi everybody,
          As I did not still findout a proper answer for my question no.3 above, it would be highly appreciated if anybody can answer my question. For reference I repeated my question as bellow:

          In case of any problem in device or driver (for example disconnecting or cable unplug) How could I send errors to the codesys? What is the best practice to handle such a situation?

           
  • wbj0t - 2024-01-25

    Hi, Ingo!
    Im very glad to see this page and your work. But I cant understand many of things.
    For example: in the IoDrvFb: cDriverName

    In the device description I see only libname, and Device name, what the drivername ?:) and many other fields I dont know what to set and how to start tesing them and what for my attention the first time.

    And other fields in the iodrv system libs. Where I can learn this? I need to understand every step, every field in the xml and in the Fbs. Thanks you!

    And what are u thinking about book of codesys that written by Gary Pratt? Is there information I need about system libs and drivers?

    Thank you :)

     
  • juanp - 3 days ago

    Hello,

    I am looking for a devdesc.xml for a driver, such as the Modbus driver, where the number of I/O's can be defined via a value in the parameter tab.
    In short, the array size of the I/O mapping not as predefined constant, but rather as a variable.
    Could you help me with this?

    Thank you in advance.

     
<< < 1 2 (Page 2 of 2)

Log in to post a comment.