Home Forums GENERAL Co Simulation Library

Viewing 15 reply threads
  • Author
    Posts
    • #33212
      Ranjeet Kumar
      Participant

      Hi everyone,
      Could anyone explain the application of Co Simulation Library in optisystem.
      How could i use it and where.
      If possible please upload osd and cpp dll file of the design. Which type of file is loaded in cpp component.
      Is it support C program code or other.
      seeking for quick response from you.

    • #33239

      HI RANJEET
      As far as i know Cpp component will allow for the direct co-simulation of customized models (using dynamic link libraries) with any other OptiSystem component. It includes an open signal architecture interface to allow users to input and/or output any of OptiSystem’s signal types and complex waveform data arrays. I am posting a link where you can get a clear idea about how to use C++ modules. I hope it helps you.
      https://optiwave.com/pdf/OptiSystem_14_New_Features.pdf?683531
      Thanks & regards

    • #33243
      SAHIL SINGH
      Participant

      Hi Ranjeet,

      I agree with the point of view of Fayiqa about the direct Co-smulation of customised models with any other optisystem component…
      Infact i was also going through the same link as posted by fayiqa… Try to go through the link.. Hope it helps..

      Regards

      Sahil Singh

    • #33246
      Aabid Baba
      Participant

      Hello Ranjeet,
      As far as C++ co-simulation with Optisystem is concerned , I think it is same as co-simulation with Matlab. All you need to do is just write a C++ code for any component you wish to use just like we use to do in Matlab and then proceed similarly as we do in interfacing the Matlab with Optisystem. I feel there shouldn’t be any problem in doing that and i think the link provided by Fayiqa just serves your purpose. you can refer to it to learn about it. I hope you find it useful.
      Regards

    • #33248
      SAHIL SINGH
      Participant

      Hi aabid baba,

      Indeed i agree with your view… Thanks for the information..

      Regards

      Sahil Singh

    • #33268
      MHD NA
      Participant

      i know Cpp component will allow for the direct co-simulation of customized models (using dynamic link libraries) with any other OptiSystem component. It includes an open signal architecture interface to allow users to input and/or output any of OptiSystem’s signal types and complex waveform data arrays.

      • #33276

        HI MHD
        Well you are copying and pasting the above comments…It’s a duplicate comment you are posting…You can join the discussions by putting forth your own views and experiences so that we learn those things…This form is about sharing information and more importantly knowledge..i hope you don’t copy paste the same which is posted in above comments…atleast try to add new points..
        Thank and regards

    • #33283

      Hi All

      As of now i have worked on Matlab co-simulation and i believe that C++ co-simulation is equivalent to the MATLAB co-simulations. All you need to do is write a c-code and then call the same code by giving the specific path of that code including its file name as well. In that manner u can co-simulate the c-code. for your reference i am attaching a pdf that is on this c++ component in optisystem and it in details mentions about its usage. hope it helps.

      • #33312
        Aabid Baba
        Participant

        Hello Burhan num mina llah,
        Thank you for sharing important notes regarding co-simulation of C++ with Optisystem. It is worth mentioning here that be it Matlab code now or C++ code , we can easily interface both with Optisystem now. It has made Optisystem very flexible now. If i remember rightly, burhan num you had to convert Simulink block into Matlab asnd you were able to convert it into C++ only but now your problrm will be solved as you rightly said , you can co-simulate it with Optisystem.
        Regards

    • #33287

      Hi Ranjeet

      adding to the above comment i infact think that since we can generate C++ code out of simulink model and also the matlab code could be converted into c++ code so i believe vice versa would be possible as well. i am refeering a link please see we have discussed about generation of C++ code from simulink model. may be this might help u.

      https://www.google.co.in/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&uact=8&ved=0ahUKEwiP58GKk8_LAhWCv44KHWI1AFMQFggcMAA&url=http%3A%2F%2Foptiwave.com%2Fforums%2Ftopic%2Fsimulink-code-generation%2F&usg=AFQjCNEaaCec1fwQZfDcNIywv22C46SW9w

      Regards

      Burhan

    • #33313
      SAHIL SINGH
      Participant

      Hello Burhan num mina llah,

      Thank you for sharing such valuable information regarding co-simulation of C++ with Optisystem…. Indeed the link provided by you is very helpful..

      Regards

      Sahil Singh

    • #33327

      Hello Aabid baba

      Yeah since you are to some extent aware of my project i was to opt for that method of co-simulation but i managed to have a matlab code now and i am co-simulating that now but i had researched about this simulink and matlab co-simulation. That is why i was bale to provide this basic information. Anyways it feels good if somebody gets the help they require as i better know how it feels when u desperately require help and forum plays the role for us. I highly Appreciate this concept of help.

      Regards

      Burhan

      • #33339
        Aabid Baba
        Participant

        Hi Burhan num mina llah,
        Yes i had some idea as we have had a discussion regarding it sometime ago and that’s the reason i mentioned it. Anyways, it good to share things and learn new things. I appreciate your efforts.
        Regards

    • #33360

      HI ALL..
      Thanks burhan for sharing such valuable inputs…..I think Burhan has put forth an important observation and i think it should be clear to ranjeet now how he can co-simualte C++ with optisystem..i had mentioned it should not be problem at first place but now the discussion has already…i hope it will clear now..
      Thanks & regards

    • #33383
      SAHIL SINGH
      Participant

      HI ALL..

      Infact very valuable information put forward by Burhan regarding how to co-simualte C++ with optisystem… Highly appreciate your efforts…

      Thanks & regards

      Sahil Singh

    • #33444

      Hi All

      You are welcome. This is what this forum is meant to be for . We learn and provide information to others as well. Such discussions are always appreciated.

      Regards

      Burhan

    • #33516
      Ranjeet Kumar
      Participant

      Thank you everyone for sharing such important and wonderful information.
      as from above links i have come across the following informations:

      OptiSystem’s Cpp Component allows users to create their own custom components in C++ for use in OptiSystem in a similar manner to the MATLAB component. The user can also create their own internal graphs and results that can be displayed within OptiSystem.
      The project is large with many classes available to the user. Due to the number of configuration settings involved, it is recommended to create a copy of this default project and add code to it for each component the user wishes to define. The user may add as many classes as they wish to this project but it is not recommended that they remove or alter the classes already provided other than at the defined entry point: Calculate_API() in class DS_SystemManager.cpp.
      The component can be configured in two modes:
      Release mode. The component project is compiled as a dynamic link library (.dll). OptiSystem will load this “.dll” in during runtime. The signal data is passed directly from OptiSystem to the “.dll” and then, after processing, from the “.dll” back to OptiSystem. This is the mode to use when you wish to run OptiSystem and your C++ component within it.
      Debug mode. The component project is compiled as a stand-alone application (.exe). Running the component project from within the developer environment will allow the user to enter the code, set breakpoints and examine their data. OptiSystem creates copies of the signal data in various text files which will be loaded by the project. The project knows where to obtain these files and their formatting by an XML data file it loads at runtime.
      The project has been set up so that very little changes must be made to switch between the two modes. The user will not need to alter any of their code, just change some configuration settings and add a line of code to tell the project where to find the XML file mentioned above. The two different modes are explained in detail in Tutorial 1: Binary Signal Manipulation.
      The most effective way to learn how to use the Cpp component is to follow the tutorials in the documentation. They will teach the user how to access and manipulate the basic data structures, configure the project for release and debug mode, and use many of the convenience functions built into the project. It is recommended that the user create a copy of the default project available at http:/optiwave.com/?p=28551 for each tutorial, then follow along for the manipulations of the C++ code and the creation of the OptiSystem project.

      http:/optiwave.com/?p=28551

    • #33531

      Hi Ranjeet

      i appreciate your such an elaborate explanation. it shows how we can interface a c++ component or we can say a code with the rest of the components in optisystem. It would be quite easy for u infact now to co-simulate the code now. appreciated!

      Regards

      Burhan

    • #33535
      SAHIL SINGH
      Participant

      Hi Ranjeet

      I completely agree with Burhan Num Mina Llah and really appreciate your such an elaborate explanation. … It would be quite easy now for u to co-simulate the code.Thanks for such valuable information…

      Regards

      Sahil Singh

Viewing 15 reply threads
  • You must be logged in to reply to this topic.