fmi-standard | Specification of the Functional Mock-Up Interface (FMI) | Mock library
kandi X-RAY | fmi-standard Summary
kandi X-RAY | fmi-standard Summary
Specification of the Functional Mock-Up Interface (FMI)
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of fmi-standard
fmi-standard Key Features
fmi-standard Examples and Code Snippets
Community Discussions
Trending Discussions on fmi-standard
QUESTION
This is my function. I am trying to export this code to fmu. I am using fmusdk.
For each cycle(time step),
- my
input
should be changed to the value given during simulation. myexecute()
should be called.- the values of
input
andpout
should be stored during simulation, so that we can plot the values after the simulation.
I tried the examples(BouncingBall and values) given in fmusdk. I have created corresponding fmus and imported them in Amesim. They are working fine. But i am unable to figure out how to do the same for my C file/function
...ANSWER
Answered 2017-Jul-07 at 11:32Consider the C file given below similar to the files you mentioned bouncingBall.c or valus.c . Since you have referred the function myexecute
from another c file, replace yourCFile.c
and/or yourHFile.h
with the correct files.
Also your modelDescription.xml should be in sync with this C file. For ex) guid
value should be the same in both files. Also the value reference for the scalar variables should be the same. Analyse and
#define pin_ 0
. Similarly for pout
. Create a folder structure similar to bouncingBall. Create a separate batch file, since we have to include additional files(yourCFile.c
and/or yourHFile.h
)
QUESTION
I have a publicly-available FMU for which I am trying to link the embedded .so file with the rest of my program. (This is contained within the .fmu file if you view as an archive.) During the linking phase I am getting the following undefined reference errors:
RoomHeating_OM_RH.so: undefined reference to '__longjmp_chk@GLIBC_2.11'
RoomHeating_OM_RH.so: undefined reference to '__fread_chk@GLIBC_2.7'
If I look at the content of RoomHeating_OM_RH.so with a tool like nm -a
, I see lots of undefined references of this form that aren't causing errors at link time. Here are a couple such lines from the nm -a
output:
U __vsnprintf_chk@@GLIBC_2.3.4
U _setjmp@@GLIBC_2.0
However, the ones that are causing errors are differentiated from the rest of them by the fact that they have newer versions of GLIBC in the name. Here's what I have in my /lib dir for the libc library (yes I realize these are old versions, but it's what I am stuck with for now):
/lib/libc-2.5.so
/lib/libc.so.6
So my guess is that I don't have a new enough version of libc to link against. Is it a requirement that the version of libc be exactly what the .so file calls out? Or does it only need to be equal to or newer than the version called out? Furthermore, does the FMI specification even cover this aspect of compatibility? Or does it assume that IF .so files are provided in the FMU that they MUST be compiled using the same or older versions of libraries as will be installed on the target machine?
...ANSWER
Answered 2017-Apr-11 at 05:37So my guess is that I don't have a new enough version of libc to link against.
Correct.
Is it a requirement that the version of libc be exactly what the .so file calls out?
No. You need GLIBC-2.11 or newer. See this answer for explanation.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install fmi-standard
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page