m2_ctrl_fsm/positionner/
mod.rs1use simulink_binder::import;
2
3import! {M2_POS_Control,
4r##"
5#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
6/*
7 * File: M2_POS_Control.h
8 *
9 * Code generated for Simulink model 'M2_POS_Control'.
10 *
11 * Model version : 1.1023
12 * Simulink Coder version : 9.0 (R2018b) 24-May-2018
13 * C/C++ source code generated on : Tue Mar 15 15:30:19 2022
14 *
15 * Target selection: ert.tlc
16 * Embedded hardware selection: Intel->x86-64 (Linux 64)
17 * Code generation objectives: Unspecified
18 * Validation result: Not run
19 */
20
21#ifndef RTW_HEADER_M2_POS_Control_h_
22#define RTW_HEADER_M2_POS_Control_h_
23#include <string.h>
24#include <stddef.h>
25#ifndef M2_POS_Control_COMMON_INCLUDES_
26# define M2_POS_Control_COMMON_INCLUDES_
27#include "rtwtypes.h"
28#endif /* M2_POS_Control_COMMON_INCLUDES_ */
29
30#include "M2_POS_Control_types.h"
31
32/* Macros for accessing real-time model data structure */
33#ifndef rtmGetErrorStatus
34# define rtmGetErrorStatus(rtm) ((rtm)->errorStatus)
35#endif
36
37#ifndef rtmSetErrorStatus
38# define rtmSetErrorStatus(rtm, val) ((rtm)->errorStatus = (val))
39#endif
40
41/* Block states (default storage) for system '<Root>' */
42typedef struct {
43 real_T FBcontroller_states[126]; /* '<S1>/FB controller' */
44} DW_M2_POS_Control_T;
45
46/* Constant parameters (default storage) */
47typedef struct {
48 /* Expression: m2pos.Km2p_dec
49 * Referenced by: '<S1>/Gain'
50 */
51 real_T Gain_Gain[1764];
52
53 /* Expression: kron(eye(42),[1;-1])
54 * Referenced by: '<S1>/kron(eye(42),[1;-1])'
55 */
56 real_T kroneye4211_Gain[3528];
57} ConstP_M2_POS_Control_T;
58
59/* External inputs (root inport signals with default storage) */
60typedef struct {
61 real_T M2_pos_cmd[42]; /* '<Root>/M2_pos_cmd' */
62 real_T M2_pos_FB[84]; /* '<Root>/M2_pos_FB' */
63} ExtU_M2_POS_Control_T;
64
65/* External outputs (root outports fed by signals with default storage) */
66typedef struct {
67 real_T M2_pos_act_F[84]; /* '<Root>/M2_pos_act_F' */
68} ExtY_M2_POS_Control_T;
69
70/* Real-time Model Data Structure */
71struct tag_RTM_M2_POS_Control_T {
72 const char_T * volatile errorStatus;
73};
74
75/* Block states (default storage) */
76extern DW_M2_POS_Control_T M2_POS_Control_DW;
77
78/* External inputs (root inport signals with default storage) */
79extern ExtU_M2_POS_Control_T M2_POS_Control_U;
80
81/* External outputs (root outports fed by signals with default storage) */
82extern ExtY_M2_POS_Control_T M2_POS_Control_Y;
83
84/* Constant parameters (default storage) */
85extern const ConstP_M2_POS_Control_T M2_POS_Control_ConstP;
86
87/* Model entry point functions */
88extern void M2_POS_Control_initialize(void);
89extern void M2_POS_Control_step(void);
90extern void M2_POS_Control_terminate(void);
91
92/* Real-time Model object */
93extern RT_MODEL_M2_POS_Control_T *const M2_POS_Control_M;
94
95/*-
96 * These blocks were eliminated from the model due to optimizations:
97 *
98 * Block '<S1>/m2_pos_en' : Eliminated nontunable gain of 1
99 */
100
101/*-
102 * The generated code includes comments that allow you to trace directly
103 * back to the appropriate location in the model. The basic format
104 * is <system>/block_name, where system is the system number (uniquely
105 * assigned by Simulink) and block_name is the name of the block.
106 *
107 * Note that this particular code originates from a subsystem build,
108 * and has its own system numbers different from the parent model.
109 * Refer to the system hierarchy for this subsystem below, and use the
110 * MATLAB hilite_system command to trace the generated code back
111 * to the parent model. For example,
112 *
113 * hilite_system('ims_Build5pt1f/M2_POS_Control') - opens subsystem ims_Build5pt1f/M2_POS_Control
114 * hilite_system('ims_Build5pt1f/M2_POS_Control/Kp') - opens and selects block Kp
115 *
116 * Here is the system hierarchy for this model
117 *
118 * '<Root>' : 'ims_Build5pt1f'
119 * '<S1>' : 'ims_Build5pt1f/M2_POS_Control'
120 */
121#endif /* RTW_HEADER_M2_POS_Control_h_ */
122
123/*
124 * File trailer for generated code.
125 *
126 * [EOF]
127 */
128"##}