Subsystem.h 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /*
  2. * File: Subsystem.h
  3. *
  4. * Code generated for Simulink model 'Subsystem'.
  5. *
  6. * Model version : 1.2
  7. * Simulink Coder version : 9.4 (R2020b) 29-Jul-2020
  8. * C/C++ source code generated on : Fri Oct 14 20:06:32 2022
  9. *
  10. * Target selection: ert.tlc
  11. * Embedded hardware selection: ARM Compatible->ARM Cortex-M
  12. * Code generation objectives:
  13. * 1. Execution efficiency
  14. * 2. RAM efficiency
  15. * Validation result: Not run
  16. */
  17. #ifndef RTW_HEADER_Subsystem_h_
  18. #define RTW_HEADER_Subsystem_h_
  19. #ifndef Subsystem_COMMON_INCLUDES_
  20. #define Subsystem_COMMON_INCLUDES_
  21. #include "rtwtypes.h"
  22. #endif /* Subsystem_COMMON_INCLUDES_ */
  23. /* Model Code Variants */
  24. /* Macros for accessing real-time model data structure */
  25. /* Block signals and states (default storage) for system '<Root>' */
  26. typedef struct {
  27. real_T DiscreteTimeIntegrator_DSTATE;/* '<S1>/Discrete-Time Integrator' */
  28. real_T DiscreteTimeIntegrator1_DSTATE;/* '<S1>/Discrete-Time Integrator1' */
  29. } DW;
  30. /* External inputs (root inport signals with default storage) */
  31. typedef struct {
  32. real_T in; /* '<Root>/in' */
  33. real_T time; /* '<Root>/time' */
  34. } ExtU;
  35. /* External outputs (root outports fed by signals with default storage) */
  36. typedef struct {
  37. real_T target; /* '<Root>/target' */
  38. real_T diff; /* '<Root>/diff' */
  39. } ExtY;
  40. /* Block signals and states (default storage) */
  41. extern DW rtDW;
  42. /* External inputs (root inport signals with default storage) */
  43. extern ExtU rtU;
  44. /* External outputs (root outports fed by signals with default storage) */
  45. extern ExtY rtY;
  46. /* Model entry point functions */
  47. extern void Subsystem_initialize(void);
  48. extern void Subsystem_step(void);
  49. /*-
  50. * The generated code includes comments that allow you to trace directly
  51. * back to the appropriate location in the model. The basic format
  52. * is <system>/block_name, where system is the system number (uniquely
  53. * assigned by Simulink) and block_name is the name of the block.
  54. *
  55. * Note that this particular code originates from a subsystem build,
  56. * and has its own system numbers different from the parent model.
  57. * Refer to the system hierarchy for this subsystem below, and use the
  58. * MATLAB hilite_system command to trace the generated code back
  59. * to the parent model. For example,
  60. *
  61. * hilite_system('ADRC/Subsystem') - opens subsystem ADRC/Subsystem
  62. * hilite_system('ADRC/Subsystem/Kp') - opens and selects block Kp
  63. *
  64. * Here is the system hierarchy for this model
  65. *
  66. * '<Root>' : 'ADRC'
  67. * '<S1>' : 'ADRC/Subsystem'
  68. */
  69. #endif /* RTW_HEADER_Subsystem_h_ */
  70. /*
  71. * File trailer for generated code.
  72. *
  73. * [EOF]
  74. */