25#define _CRT_SECURE_NO_WARNINGS
26#pragma warning(disable:4820 4514 5045)
37#define UNREFERENCED_PARAMETER(P) (P)
62 for (i = 0; i < nCategories; i++) {
63 if (categories[i] == NULL) {
66 }
else if (strcmp(categories[i],
"logStatusError") == 0) {
68 }
else if (strcmp(categories[i],
"logEvents") == 0) {
71 sumo2fmi_logError(comp,
"Log category[%d] must be one of logEvents or logStatusError but was %s", i, categories[i]);
110 if (fmuResourceLocation) {
144 freeMemoryFunc((
void*)comp);
222 if (nvr > 0 && (!vr || !value)) {
230 for (i = 0; i < nvr; i++) {
232 status = s > status ? s : status;
258 if (nvr > 0 && (!vr || !value)) {
275 for (i = 0; i < nvr; i++) {
278 if (value[i] == NULL) {
282 status = s > status ? s : status;
328 for (i = 0; i < nvr; i++) {
330 status = s > status ? s : status;
418 for (i = 0; i < nvr; i++) {
431 if (communicationStepSize <= 0) {
435 return sumo2fmi_step(comp, currentCommunicationPoint + communicationStepSize);
#define UNREFERENCED_PARAMETER(P)
const char * fmi2GetVersion(void)
const char * fmi2GetTypesPlatform(void)
#define fmi2GetStringStatus
#define fmi2SetRealInputDerivatives
#define fmi2SerializeFMUstate
#define fmi2SerializedFMUstateSize
#define fmi2ExitInitializationMode
#define fmi2GetBooleanStatus
#define fmi2GetRealOutputDerivatives
#define fmi2EnterInitializationMode
#define fmi2DeSerializeFMUstate
#define fmi2GetRealStatus
#define fmi2GetIntegerStatus
#define fmi2SetDebugLogging
#define fmi2GetDirectionalDerivative
#define fmi2SetupExperiment
void libsumo_load(char *callOptions)
void * componentEnvironment
char * getterParameters
Parameters stored for the next (libsumo) getter call. Workaround for FMIv2 not allowing input values ...
const char * resourceLocation
allocateMemoryType allocateMemory
const char * instanceName
freeMemoryType freeMemory
char * libsumoCallOptions
fmi2CallbackAllocateMemory allocateMemory
fmi2CallbackLogger logger
fmi2CallbackFreeMemory freeMemory
fmi2ComponentEnvironment componentEnvironment
fmi2Status sumo2fmi_getString(ModelInstance *comp, const fmi2ValueReference vr, fmi2String *value)
void sumo2fmi_set_startValues(ModelInstance *comp)
fmi2Status sumo2fmi_step(ModelInstance *comp, double tNext)
fmi2Status sumo2fmi_getInteger(ModelInstance *comp, const fmi2ValueReference vr, int *value)
void sumo2fmi_logError(ModelInstance *comp, const char *message,...)
fmi2Status sumo2fmi_setString(ModelInstance *comp, fmi2ValueReference vr, fmi2String value)
void sumo2fmi_logEvent(ModelInstance *comp, const char *message,...)
void *(* allocateMemoryType)(size_t nobj, size_t size)
void(* freeMemoryType)(void *obj)
void(* loggerType)(void *componentEnvironment, const char *instanceName, int status, const char *category, const char *message,...)