Hi,
I was asked by a customer if FlexSim supports gRCP.
Information on gRCP can be found below.
Customers seem to be wondering if they can use gRCP to communicate with FlexSim via an external program.
Can you give me some information?
Hi,
I was asked by a customer if FlexSim supports gRCP.
Information on gRCP can be found below.
Customers seem to be wondering if they can use gRCP to communicate with FlexSim via an external program.
Can you give me some information?
I successfully used C++ gRPC API to create a FlexSim module for our client. While I can't disclose implementation details, here are some tips:
1. The easiest way to build and install grpc libs on Windows is to use vcpkg. I recommend pinning vcpkg version to one of their recent tags, this will help to re-create build environment without regenerating protocol files every time.
If you have already checked out vcpkg git repo, do something like this:
git checkout 2021.05.21
.\bootstrap-vcpkg.bat -disableMetrics
.\vcpkg.exe update
.\vcpkg.exe upgrade --no-dry-run
and then `vcpkg.exe integrate install`.
2. C++ side you should already know how to create FlexSim modules and follow grpc tutorials which explain how to generate C++ code from the proto files. These files will be compiled and linked to your FlexSim module.
I generated C++ code by manually calling protoc.exe with grpc_cpp_plugin.
3. I derived a class from FlexSim::SimpleDataType. A static Init() method works as Flexscript "constructor" and initializes a tree node and adds class-specific data that node. One of the instance methods can create a GRPC channel. stub_ data is a member of my class. Then there are different methods which more or less correspond to methods described in the protocol files which I have used (they are specific to your protocol files). Init and other methods are bound and can be called from Flexscript.
As long as you don't want to use grpc in async mode, implementation is relatively straightforward (provided you can figure out how to read generated C++ for gRPC and know how to create SimpleDataTypes).
FlexSim does not natively support gRPC (Google Remote Procedure Call) for communication with external programs. However, it is possible to integrate FlexSim with gRPC by developing custom connectors or using APIs to establish communication. While FlexSim primarily utilizes other protocols for external communication, gRPC can be implemented with additional development effort. For testing and preparation, Study4Exam offers free practice questions for gRPC, which can help you better understand the protocol and its integration. Official resources like the FlexSim API documentation and the gRPC website (https://grpc.io/) can provide further insights on how to implement such integrations.
Can you give me some information?
Resources mentioned by @Adam Hales are incredibly helpful for my preparation. They provide valuable insights and hands-on experience, enhancing my understanding of gRPC. By utilizing these materials, I feel confident in my ability to effectively learn and apply the concepts, increasing my chances of achieving the gRPC certification on my first attempt.
gRCP has a C++ interface. Basics tutorial | C++ | gRPC
You can use the DLL Maker or Module SDK to execute C++ code from FlexSim. So yes, you can use gRCP to communicate with FlexSim via an external program.
Hi @Phil BoBo ,
Thank you for your reply.
It was very helpful to know that communication was possible.
17 People are following this question.
FlexSim can help you understand and improve any system or process. Transform your existing data into accurate predictions.
FlexSim is a fully 3D simulation software environment. FlexSim can be used to simulate any process in any industry.
FlexSim®, FlexSim Healthcare™, Problem Solved.®, the FlexSim logo, the FlexSim X-mark, and the FlexSim Healthcare logo with stylized Caduceus mark are trademarks of FlexSim Software Products, Inc. All rights reserved.
Privacy | Do not sell or share my personal information | Cookie preferences | Report noncompliance | Terms of use | Legal | © Autodesk Inc. All rights reserved