static void set_sim_state_c1_EVdemo_6(SFc1_EVdemo_6InstanceStruct *chartInstance,
  const mxArray *c1_st)
{
  const mxArray *c1_u;
  boolean_T *c1_BrakeSet;
  uint8_T *c1_Mode;
  c1_BrakeSet = (boolean_T *)ssGetOutputPortSignal(chartInstance->S, 2);
  c1_Mode = (uint8_T *)ssGetOutputPortSignal(chartInstance->S, 1);
  c1_u = sf_mex_dup(c1_st);
  *c1_BrakeSet = c1_d_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell
    (c1_u, 0)), "BrakeSet");
  *c1_Mode = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u,
    1)), "Mode");
  chartInstance->c1_is_active_c1_EVdemo_6 = c1_b_emlrt_marshallIn(chartInstance,
    sf_mex_dup(sf_mex_getcell(c1_u, 2)), "is_active_c1_EVdemo_6");
  chartInstance->c1_is_c1_EVdemo_6 = c1_b_emlrt_marshallIn(chartInstance,
    sf_mex_dup(sf_mex_getcell(c1_u, 3)), "is_c1_EVdemo_6");
  chartInstance->c1_temporalCounter_i1 = c1_b_emlrt_marshallIn(chartInstance,
    sf_mex_dup(sf_mex_getcell(c1_u, 4)), "temporalCounter_i1");
  sf_mex_assign(&chartInstance->c1_setSimStateSideEffectsInfo,
                c1_f_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell
    (c1_u, 5)), "setSimStateSideEffectsInfo"), TRUE);
  sf_mex_destroy(&c1_u);
  chartInstance->c1_doSetSimStateSideEffects = 1U;
  c1_update_debugger_state_c1_EVdemo_6(chartInstance);
  sf_mex_destroy(&c1_st);
}
Exemplo n.º 2
0
static void c1_emlrt_marshallIn(SFc1_newtons_cradleInstanceStruct *chartInstance,
  const mxArray *c1_u)
{
  real_T (*c1_p_out)[3];
  real_T (*c1_v_out)[3];
  real_T (*c1_p)[3];
  real_T (*c1_v)[3];
  c1_v = (real_T (*)[3])(ssGetContStates(chartInstance->S) + 3);
  c1_p = (real_T (*)[3])(ssGetContStates(chartInstance->S) + 0);
  c1_v_out = (real_T (*)[3])ssGetOutputPortSignal(chartInstance->S, 2);
  c1_p_out = (real_T (*)[3])ssGetOutputPortSignal(chartInstance->S, 1);
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 0)),
                        "p_out", *c1_p_out);
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 1)),
                        "v_out", *c1_v_out);
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 2)), "p",
                        *c1_p);
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 3)), "v",
                        *c1_v);
  chartInstance->c1_is_active_c1_newtons_cradle = c1_d_emlrt_marshallIn
    (chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 4)),
     "is_active_c1_newtons_cradle");
  chartInstance->c1_is_c1_newtons_cradle = c1_d_emlrt_marshallIn(chartInstance,
    sf_mex_dup(sf_mex_getcell(c1_u, 5)), "is_c1_newtons_cradle");
  sf_mex_assign(&chartInstance->c1_setSimStateSideEffectsInfo,
                c1_f_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell
    (c1_u, 6)), "setSimStateSideEffectsInfo"), TRUE);
  sf_mex_destroy(&c1_u);
}
Exemplo n.º 3
0
static void c1_emlrt_marshallIn(SFc1_QmodInstanceStruct *chartInstance, const
  mxArray *c1_y, const char_T *c1_identifier, real_T c1_b_y[3])
{
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_y), &c1_thisId, c1_b_y);
  sf_mex_destroy(&c1_y);
}
static void c1_emlrt_marshallIn(SFc1_QPSK_Transmit_v5_w_FIFOInstanceStruct
  *chartInstance, const mxArray *c1_b_buf, const char_T *c1_identifier, creal_T
  c1_y[17])
{
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_buf), &c1_thisId, c1_y);
  sf_mex_destroy(&c1_b_buf);
}
static void c1_emlrt_marshallIn(SFc1_VrSubsystemInstanceStruct *chartInstance,
  const mxArray *c1_b_y, const char_T *c1_identifier, real_T c1_c_y[128])
{
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_thisId.bParentIsCell = false;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_y), &c1_thisId, c1_c_y);
  sf_mex_destroy(&c1_b_y);
}
static real_T c1_emlrt_marshallIn(SFc1_mainInstanceStruct *chartInstance, const
  mxArray *c1_y, const char_T *c1_identifier)
{
  real_T c1_b_y;
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_y), &c1_thisId);
  sf_mex_destroy(&c1_y);
  return c1_b_y;
}
static real_T c1_emlrt_marshallIn
  (SFc1_motor_control_with_off_the_shelf_SVPWMInstanceStruct *chartInstance,
   const mxArray *c1_Vq, const char_T *c1_identifier)
{
  real_T c1_y;
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_Vq), &c1_thisId);
  sf_mex_destroy(&c1_Vq);
  return c1_y;
}
static real_T c1_emlrt_marshallIn(SFc1_TTR_RobustMPC_RTmdlInstanceStruct
  *chartInstance, const mxArray *c1_u_ctrl_out, const char_T *c1_identifier)
{
  real_T c1_y;
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_u_ctrl_out),
    &c1_thisId);
  sf_mex_destroy(&c1_u_ctrl_out);
  return c1_y;
}
Exemplo n.º 9
0
static int32_T c1_emlrt_marshallIn(SFc1_MON_sl_after_replacement3InstanceStruct *
  chartInstance, const mxArray *c1_b_sfEvent, const char_T *c1_identifier)
{
  int32_T c1_y;
  emlrtMsgIdentifier c1_thisId;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_thisId.bParentIsCell = false;
  c1_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_sfEvent),
    &c1_thisId);
  sf_mex_destroy(&c1_b_sfEvent);
  return c1_y;
}
Exemplo n.º 10
0
static void c1_sf_marshallIn(void *chartInstanceVoid, const mxArray
  *c1_mxArrayInData, const char_T *c1_varName, void *c1_outData)
{
  const mxArray *c1_y;
  const char_T *c1_identifier;
  emlrtMsgIdentifier c1_thisId;
  real_T c1_b_y;
  SFc1_mainInstanceStruct *chartInstance;
  chartInstance = (SFc1_mainInstanceStruct *)chartInstanceVoid;
  c1_y = sf_mex_dup(c1_mxArrayInData);
  c1_identifier = c1_varName;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_y), &c1_thisId);
  sf_mex_destroy(&c1_y);
  *(real_T *)c1_outData = c1_b_y;
  sf_mex_destroy(&c1_mxArrayInData);
}
Exemplo n.º 11
0
static void c1_sf_marshallIn(void *chartInstanceVoid, const mxArray
  *c1_mxArrayInData, const char_T *c1_varName, void *c1_outData)
{
  const mxArray *c1_b_sfEvent;
  const char_T *c1_identifier;
  emlrtMsgIdentifier c1_thisId;
  int32_T c1_y;
  SFc1_MON_sl_after_replacement3InstanceStruct *chartInstance;
  chartInstance = (SFc1_MON_sl_after_replacement3InstanceStruct *)
    chartInstanceVoid;
  c1_b_sfEvent = sf_mex_dup(c1_mxArrayInData);
  c1_identifier = c1_varName;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_thisId.bParentIsCell = false;
  c1_y = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_sfEvent),
    &c1_thisId);
  sf_mex_destroy(&c1_b_sfEvent);
  *(int32_T *)c1_outData = c1_y;
  sf_mex_destroy(&c1_mxArrayInData);
}
static void c1_sf_marshallIn(void *chartInstanceVoid, const mxArray
  *c1_mxArrayInData, const char_T *c1_varName, void *c1_outData)
{
  const mxArray *c1_Force;
  const char_T *c1_identifier;
  emlrtMsgIdentifier c1_thisId;
  real_T c1_y[3];
  int32_T c1_i8;
  SFc1_Model_justmodel2InstanceStruct *chartInstance;
  chartInstance = (SFc1_Model_justmodel2InstanceStruct *)chartInstanceVoid;
  c1_Force = sf_mex_dup(c1_mxArrayInData);
  c1_identifier = c1_varName;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_Force), &c1_thisId, c1_y);
  sf_mex_destroy(&c1_Force);
  for (c1_i8 = 0; c1_i8 < 3; c1_i8++) {
    (*(real_T (*)[3])c1_outData)[c1_i8] = c1_y[c1_i8];
  }

  sf_mex_destroy(&c1_mxArrayInData);
}
static void c1_sf_marshallIn(void *chartInstanceVoid, const mxArray
  *c1_mxArrayInData, const char_T *c1_varName, void *c1_outData)
{
  const mxArray *c1_b_buf;
  const char_T *c1_identifier;
  emlrtMsgIdentifier c1_thisId;
  creal_T c1_y[17];
  int32_T c1_i12;
  SFc1_QPSK_Transmit_v5_w_FIFOInstanceStruct *chartInstance;
  chartInstance = (SFc1_QPSK_Transmit_v5_w_FIFOInstanceStruct *)
    chartInstanceVoid;
  c1_b_buf = sf_mex_dup(c1_mxArrayInData);
  c1_identifier = c1_varName;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_buf), &c1_thisId, c1_y);
  sf_mex_destroy(&c1_b_buf);
  for (c1_i12 = 0; c1_i12 < 17; c1_i12++) {
    (*(creal_T (*)[17])c1_outData)[c1_i12] = c1_y[c1_i12];
  }

  sf_mex_destroy(&c1_mxArrayInData);
}
static void c1_sf_marshallIn(void *chartInstanceVoid, const mxArray
  *c1_mxArrayInData, const char_T *c1_varName, void *c1_outData)
{
  const mxArray *c1_b_y;
  const char_T *c1_identifier;
  emlrtMsgIdentifier c1_thisId;
  real_T c1_c_y[128];
  int32_T c1_i17;
  SFc1_VrSubsystemInstanceStruct *chartInstance;
  chartInstance = (SFc1_VrSubsystemInstanceStruct *)chartInstanceVoid;
  c1_b_y = sf_mex_dup(c1_mxArrayInData);
  c1_identifier = c1_varName;
  c1_thisId.fIdentifier = c1_identifier;
  c1_thisId.fParent = NULL;
  c1_thisId.bParentIsCell = false;
  c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup(c1_b_y), &c1_thisId, c1_c_y);
  sf_mex_destroy(&c1_b_y);
  for (c1_i17 = 0; c1_i17 < 128; c1_i17++) {
    (*(real_T (*)[128])c1_outData)[c1_i17] = c1_c_y[c1_i17];
  }

  sf_mex_destroy(&c1_mxArrayInData);
}
static void set_sim_state_c1_Engine_Vehicle_CVT_RS_System2
  (SFc1_Engine_Vehicle_CVT_RS_System2InstanceStruct *chartInstance, const
   mxArray *c1_st)
{
  const mxArray *c1_u;
  boolean_T c1_bv0[1];
  chartInstance->c1_doneDoubleBufferReInit = true;
  c1_u = sf_mex_dup(c1_st);
  *chartInstance->c1_ClutchON = c1_b_emlrt_marshallIn(chartInstance, sf_mex_dup
    (sf_mex_getcell(c1_u, 0)), "ClutchON");
  chartInstance->c1_is_active_c1_Engine_Vehicle_CVT_RS_System2 =
    c1_e_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 1)),
    "is_active_c1_Engine_Vehicle_CVT_RS_System2");
  c1_g_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell(c1_u, 2)),
                        "dataWrittenToVector", c1_bv0);
  chartInstance->c1_dataWrittenToVector[0] = c1_bv0[0];
  sf_mex_assign(&chartInstance->c1_setSimStateSideEffectsInfo,
                c1_i_emlrt_marshallIn(chartInstance, sf_mex_dup(sf_mex_getcell
    (c1_u, 3)), "setSimStateSideEffectsInfo"), true);
  sf_mex_destroy(&c1_u);
  chartInstance->c1_doSetSimStateSideEffects = 1U;
  c1_update_debugger_state_c1_Engine_Vehicle_CVT_RS_System2(chartInstance);
  sf_mex_destroy(&c1_st);
}