| 1 | /* |
| 2 | * Arduino_skal_data.cpp |
| 3 | * |
| 4 | * Academic License - for use in teaching, academic research, and meeting |
| 5 | * course requirements at degree granting institutions only. Not for |
| 6 | * government, commercial, or other organizational use. |
| 7 | * |
| 8 | * Code generation for model "Arduino_skal". |
| 9 | * |
| 10 | * Model version : 1.1 |
| 11 | * Simulink Coder version : 9.5 (R2021a) 14-Nov-2020 |
| 12 | * C++ source code generated on : Thu Apr 15 15:56:50 2021 |
| 13 | * |
| 14 | * Target selection: grt.tlc |
| 15 | * Note: GRT includes extra infrastructure and instrumentation for prototyping |
| 16 | * Embedded hardware selection: Intel->x86-64 (Windows64) |
| 17 | * Code generation objective: Debugging |
| 18 | * Validation result: Not run |
| 19 | */ |
| 20 | |
| 21 | #include "Arduino_skal.h" |
| 22 | #include "Arduino_skal_private.h" |
| 23 | |
| 24 | /* Block parameters (default storage) */ |
| 25 | P_Arduino_skal_T Arduino_skalModelClass::Arduino_skal_P = { |
| 26 | /* Variable: K |
| 27 | * Referenced by: '<Root>/Gain' |
| 28 | */ |
| 29 | { -31.622776601683942, -21.286439360075747, 80.789376267003959, |
| 30 | 13.42463576551093 }, |
| 31 | |
| 32 | /* Variable: Kr |
| 33 | * Referenced by: '<Root>/Kr' |
| 34 | */ |
| 35 | 1.0, |
| 36 | |
| 37 | /* Expression: 0 |
| 38 | * Referenced by: '<S53>/L*(y[k]-yhat[k|k-1])' |
| 39 | */ |
| 40 | 0.0, |
| 41 | |
| 42 | /* Expression: [1,1] |
| 43 | * Referenced by: '<Root>/Constant' |
| 44 | */ |
| 45 | { 1.0, 1.0 }, |
| 46 | |
| 47 | /* Expression: pInitialization.X0 |
| 48 | * Referenced by: '<S1>/X0' |
| 49 | */ |
| 50 | { 0.0, 0.0, 0.0, 0.0 }, |
| 51 | |
| 52 | /* Expression: pInitialization.A |
| 53 | * Referenced by: '<S1>/A' |
| 54 | */ |
| 55 | { 0.0, 0.0, 0.0, 0.0, 1.0, -0.20780947085442231, 0.0, -0.52810302415000854, |
| 56 | 0.0, 13.239785742831822, 0.0, 58.601480177829842, 0.0, 0.0, 1.0, 0.0 }, |
| 57 | |
| 58 | /* Expression: pInitialization.B |
| 59 | * Referenced by: '<S1>/B' |
| 60 | */ |
| 61 | { 0.0, 2.078094708544223, 0.0, 5.2810302415000852 }, |
| 62 | |
| 63 | /* Expression: pInitialization.C |
| 64 | * Referenced by: '<S1>/C' |
| 65 | */ |
| 66 | { 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0 }, |
| 67 | |
| 68 | /* Expression: pInitialization.Z |
| 69 | * Referenced by: '<S2>/CovarianceZ' |
| 70 | */ |
| 71 | { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, |
| 72 | 0.0 }, |
| 73 | |
| 74 | /* Expression: pInitialization.L |
| 75 | * Referenced by: '<S2>/KalmanGainL' |
| 76 | */ |
| 77 | { 2.829363352293504, 6.8371369304528766, 2.3809613355962305, |
| 78 | 17.882971156218495, 2.3809613355962278, 24.153756408336502, |
| 79 | 14.825995823889082, 112.73956452579047 }, |
| 80 | |
| 81 | /* Expression: pInitialization.D |
| 82 | * Referenced by: '<S1>/D' |
| 83 | */ |
| 84 | { 0.0, 0.0 }, |
| 85 | |
| 86 | /* Expression: 0 |
| 87 | * Referenced by: '<Root>/Step' |
| 88 | */ |
| 89 | 0.0, |
| 90 | |
| 91 | /* Expression: 0 |
| 92 | * Referenced by: '<Root>/Step' |
| 93 | */ |
| 94 | 0.0, |
| 95 | |
| 96 | /* Expression: 0 |
| 97 | * Referenced by: '<Root>/Step' |
| 98 | */ |
| 99 | 0.0, |
| 100 | |
| 101 | /* Expression: 11.5 |
| 102 | * Referenced by: '<Root>/Saturation' |
| 103 | */ |
| 104 | 11.5, |
| 105 | |
| 106 | /* Expression: -11.5 |
| 107 | * Referenced by: '<Root>/Saturation' |
| 108 | */ |
| 109 | -11.5, |
| 110 | |
| 111 | /* Expression: pInitialization.isSqrtUsed |
| 112 | * Referenced by: '<S51>/isSqrtUsed' |
| 113 | */ |
| 114 | 0, |
| 115 | |
| 116 | /* Expression: true() |
| 117 | * Referenced by: '<S1>/Enable' |
| 118 | */ |
| 119 | 1 |
| 120 | }; |
| 121 | |