Menu

Questions of Beginners

Help
Jimmy
2016-01-19
2016-01-23
  • Jimmy

    Jimmy - 2016-01-19

    Hey guys,

    I am totally new to openConfigurator and POWERLINK configuration and got some questions. I have established a POWERLINK network with 1 MN and 1 CN. MN is PL-IB300 PCI card from IXXAT company and CN is a pure software solution, which is demo_cn_console compiled from openPOWERLINK. The PCI card is installed on my host PC running a Windows 7 64-bit and CN is running under embedded Linux on a ZYNQ board.

    Now I have some questions regarding to general POWERLINK configurations.
    1. The cd file is only file can directly configure the network right? I mean, firstly we need to use xdd or xdc file to configure the MN and CN seperately, after that we generate cdc file and download cdc file into MN to configure the whole network? Which means we don't need to download anything on CN side?
    2. When we talking about object dictionary, are we talking about this cdc file?

    I have go through the user guide about openCONFIGURATOR on Eclipse. It's great for beginners to follow step by step but still need more information about the configurations.

    Regarding my project, a cdc file is carried along with the PCI card (MN), but it cannot work with CN. At first CN is in Not Active state (NmtEventEnterCSNotActive), after I increased cycle time (on 0x1006 from 1ms to 20ms), CN is recognised but chaging status between PreOP1 and PreOP2 rapidly, keep restarting over and ove again. I also noticed on CN side, it shows up NmtEventEnableReadyToOperate and NmtEventNmtCycleError message between each rebooting. I checked the main.c of demo_cn_console and the length of cycle is 50000, so it should be 50ms or 50 us?

    Any idea are welcome, thanks in advance!

    Regards
    Jimmy

     
    • Wolfgang Seiss

      Wolfgang Seiss - 2016-01-20

      Hello Jimmy,

      As Kalycito have been posting, the CDC file is the output of the configuration tool (openCONFIGURATOR) and the input to the MN. The MN itself has got a module called "Configuration Manager (CFM)" that is responsible for distributing the network configuration to the CNs. So, you do not require to change the CN settings such as cycle time in the demo - this is done via the CFM and the CDC file.

      It is, however, important to have the correct XDD/XDC files as input for the openCONFIGURATOR. Otherwise, the resulting CDC file might be wrong. The XDD/XDC files are descriptions of the devices and therefore have to come from the device manufacturer.
      In your case, the XDD for the CN would come from the openPOWERLINK CN demo application. You'll find the XDD along with the objdict.h file in the objdict subdirectory of the openPOWERLINK stack.
      The XDD for the MN should be provided by IXXAT. If not, please get in contact with them and request the MN XDD.

      Please let us know about your progress!

      Best regards,
      Wolfgang

       
  • Powerlink-team Kalycito

    Hello Jimmy,

    Thank you for the interest in posting.

    Firstly, If possible can you tell us what exactly you are trying (ie. the end objective)?

    Regarding your questions:
    - The XDD/XDC file(s) is the input to openCONFIGURATOR where it describes the objects (with default value, actual value, limits for the values) available in the node (CN/MN from hardware perspecive).
    - The object dictionary describes the supported objects with default value and limits for the values for that node and is used during software compilation to create the objects memory.
    Please see http://openpowerlink.sourceforge.net/web/POWERLINK/Object%20Dictionary.html for more details.

    • openCONFIGURATOR generates CDC which includes the actual values for objects for each node in the network(MN and CNs), that has to be used for the current network configuration. This CDC is an input to the MN and the configuration manager in the MN downloads the updated object values for each CN in the network during POWERLINK initialization.
    • You might need to modify the default objdict.h available in the stack, based on the XDD/XDC you have for each CN and re-compile the stack.
    • You need not download anything separately for the CN.

    The CYCLE_LEN = 50000 is 50ms and it is the default value of any CN.
    The cycle time is updated by the MN during the configuration download as per the CDC generated from the openCONFIGURATOR.

    Regards,
    Powerlink-team
    Kalycito

     
  • Jimmy

    Jimmy - 2016-01-21

    Hey Guys,

    Thanks for repiles and making things clear.

    @Kalycito My goal is to transfer some data, like arrays and matrix data, between 1 MN and 1 CN, specifically, the PCI card and the demo_cn_console application. These data can either be real-time or non-real-time. So right now, I just want to make this network run, which means, the state of CN should stay in CS_OPERATIONAL.

    @Wolfgang The embedded Linux is already patched with rt linux patch. I noticed you worried about real-time features in another post :).

    I have modified the cdc file with 0x1006 -> 50ms. The state of CN is in PREOP2 and CN continuosly restart.

    I also noticed in the wireshark, that in synchronous stage, there is no PReq sending from MN but PRes. This is weird to me because I think PRes is the frame answered from CN, right?

    I also have some questions regarding the demo_cn_console. In the main.c, the parameters, like cycle time, asyn slot timeout, ..., are already defined as a constant value, which means even if I have a configuration for CN in cdc file, it won't make any difference? And when we talking about Pres timeout, we are refering to the initParam.presMaxLatency, right? Which has the default value of 50ms.

    I attached the cdc and wireshark tracing file. The cdc is provided by MN producer not from openCONFIGURATOR.

    Regards,
    Jimmy

     

    Last edit: Jimmy 2016-01-21
    • Powerlink-team Kalycito

      Hello Jimmy,

      Can you try with the CDC generated from "Demo_3CN" project available in the openPOWERLINK stack inside the "apps\common\openCONFIGURATOR_projects\Demo_3CN" directory.

      This project is created with openCONFIGURATOR v1.4.1.

      Regarding main.c:

      • The values available in the initParams are default values that are required during the device/firmware/software initialization.
      • The configuration values available in the CDC overwrites the initParam values.

      Regarding PResMaxLatency:

      • presMaxLatency provides the maximum time in ns, that is required by the CN to respond to PReq.
      • This is a constant value, therefore only possible to configure from main.c - initParam.
      • For PResTimeout the value from the CDC is used.
      • You can configure PRes timeout from CN properties from openCONFIGURATOR.

      Regards,
      Powerlink-team
      Kalycito

       
  • Jimmy

    Jimmy - 2016-01-23

    Hello Kalycito,

    I tried the mnobd.cdc file from Demo_3CN but things still the same. My CN is keeping on restarting.

    On CN side (demo_cn_console) state NmtEventNmtCycleError still shows up after NmtEventEnableReadyToOperate state. I checked frames on the wireshark, MN send reset request after MN send NmtEnableReadyToOperate request to CN, because CN does not respond to this.

    I don't where goes wrong so I attached the pcap file and hope you can check it too.

    Regards,
    Jimmy

     

Log in to post a comment.