diff --git a/bs_touchAndLcd/slprj/ert/_sharedutils/shared_file.dmr b/bs_touchAndLcd/slprj/ert/_sharedutils/shared_file.dmr
index fe96753..3d8ff7a 100644
Binary files a/bs_touchAndLcd/slprj/ert/_sharedutils/shared_file.dmr and b/bs_touchAndLcd/slprj/ert/_sharedutils/shared_file.dmr differ
diff --git a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/BlockTraceInfo.mat b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/BlockTraceInfo.mat
index 3fe90e8..99ee170 100644
Binary files a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/BlockTraceInfo.mat and b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/BlockTraceInfo.mat differ
diff --git a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/CompileInfo.xml b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/CompileInfo.xml
index faa6c32..6daa0c3 100644
--- a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/CompileInfo.xml
+++ b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/CompileInfo.xml
@@ -1,14 +1,14 @@
-
+
sJSjS2nhFB3Qcky7Q7UDQFE
sKuRTaq5s8EZI5Gj28zXs2E
-
+
[{"Name":"","Profile":""}]
socTouchDisplay
- [{"Name":"in_bTouchDetected","Profile":""},{"Name":"ip_u32TouchDuration_msec","Profile":""},{"Name":"ip_u32DisplayDuration_msec","Profile":""},{"Name":"Input","Profile":""},{"Name":"op_bDisplayStatus","Profile":""},{"Name":"op_bErrorStatus","Profile":""},{"Name":"op_u8HundredsPlace","Profile":""},{"Name":"op_u8TensPlace","Profile":""},{"Name":"op_u8OnesPlace","Profile":""}]
+ [{"Name":"in_bTouchDetected","Profile":""},{"Name":"ip_u32TouchDuration_msec","Profile":""},{"Name":"ip_u32DisplayDuration_msec","Profile":""},{"Name":"Input","Profile":""},{"Name":"ip_u32canId","Profile":""},{"Name":"op_bDisplayStatus","Profile":""},{"Name":"op_bErrorStatus","Profile":""},{"Name":"op_u8HundredsPlace","Profile":""},{"Name":"op_u8TensPlace","Profile":""},{"Name":"op_u8OnesPlace","Profile":""}]
-
+
socTouchDisplay
socTouchDisplay
@@ -16,13 +16,13 @@
socTouchDisplay.sldd
socTouchDisplay.sldd
socTouchDisplay.sldd
-
-
+
+
true
socTouchDisplay.sldd
DataDictionary
-
+
true
base workspace
BaseWorkspace
@@ -40,7 +40,7 @@
true
true
true
-
+
true
inf
-inf
@@ -53,10 +53,10 @@
0
-
-
+
+
-
+
true
inf
-inf
@@ -70,10 +70,10 @@
0
-
-
+
+
-
+
true
inf
-inf
@@ -87,10 +87,10 @@
0
-
-
+
+
-
+
true
inf
-inf
@@ -104,8 +104,25 @@
0
-
-
+
+
+
+
+ true
+ inf
+ -inf
+ 2
+ 4
+
+ true
+ D1
+ .1
+ 40
+ 0
+
+
+
+
false
true
@@ -113,6 +130,7 @@
false
false
false
+ false
false
false
false
@@ -120,12 +138,13 @@
false
2
-1.0
- 4
+ 5
0
+
false
false
false
@@ -136,7 +155,7 @@
-
+
true
inf
-inf
@@ -148,10 +167,10 @@
0
-
-
+
+
-
+
true
inf
-inf
@@ -164,10 +183,10 @@
0
-
-
+
+
-
+
inf
-inf
2
@@ -179,10 +198,10 @@
0
-
-
+
+
-
+
inf
-inf
3
@@ -194,10 +213,10 @@
0
-
-
+
+
-
+
inf
-inf
4
@@ -209,8 +228,8 @@
0
-
-
+
+
true
@@ -224,50 +243,50 @@
323
<?xml version="1.0"?>
<slexec_sto version="1.1" packageUris="http://schema.mathworks.com/mf0/slexec_mm_sto/R2023a_202208151321">
- <sto.Registry type="sto.Registry" uuid="3a3d3d52-cd9c-47c0-a0c8-32e7580def99">
+ <sto.Registry type="sto.Registry" uuid="cd25431f-875e-462e-90e6-77aba17625d3">
<executionSpec>Undetermined</executionSpec>
<identifier>socTouchDisplay</identifier>
- <clockRegistry type="sto.ClockRegistry" uuid="926692e5-6e1d-44ce-95bd-ec062455c3dd">
- <clocks type="sto.Timer" uuid="b6a56536-b6c2-4e08-a692-5478eb83994e">
+ <clockRegistry type="sto.ClockRegistry" uuid="dd27bfe6-2f41-4359-8706-c010ed9dc578">
+ <clocks type="sto.Timer" uuid="23b6ef5b-2cde-4de5-8f5c-41238b19192e">
<clockTickConstraint>PeriodicWithFixedResolution</clockTickConstraint>
<computedFundamentalDiscretePeriod>.1</computedFundamentalDiscretePeriod>
- <fastestDiscreteRate type="sto.ClassicPeriodicDiscreteRate" uuid="b24d7f8a-e80b-4bf6-a138-35e053d007e1"/>
+ <fastestDiscreteRate type="sto.ClassicPeriodicDiscreteRate" uuid="a4a85346-4500-496a-b655-7c0b2e0a41ce"/>
<isDefaultTimer>true</isDefaultTimer>
<resolution>.1</resolution>
<timeAdvanceMode>FixedStep</timeAdvanceMode>
<identifier>socTouchDisplay::defaultTimer</identifier>
- <rates type="sto.ClassicPeriodicDiscreteRate" uuid="b24d7f8a-e80b-4bf6-a138-35e053d007e1">
+ <rates type="sto.ClassicPeriodicDiscreteRate" uuid="a4a85346-4500-496a-b655-7c0b2e0a41ce">
<annotation>D1</annotation>
<clockId>socTouchDisplay::defaultTimer</clockId>
<description>Discrete 1</description>
<taskId>_task0</taskId>
- <rateSpec type="sto.RateSpec" uuid="04741580-1702-4d99-a71f-5c59fff197c6">
+ <rateSpec type="sto.RateSpec" uuid="e2802860-1cd7-4f78-a3ea-f71eeea3095b">
<period>.1</period>
<rateType>ClassicPeriodicDiscrete</rateType>
</rateSpec>
</rates>
- <baseRate type="sto.ClassicPeriodicDiscreteRate" uuid="66637882-0267-41e0-a267-d06135e27d03">
+ <baseRate type="sto.ClassicPeriodicDiscreteRate" uuid="83ac6bc7-b933-4c64-aaa4-c68795b13cf0">
<annotation>D1</annotation>
<clockId>socTouchDisplay::defaultTimer</clockId>
<description>Discrete 1</description>
<taskId>_task0</taskId>
- <rateSpec type="sto.RateSpec" uuid="a1392d16-b148-4f54-a21b-6f8b08d0035f">
+ <rateSpec type="sto.RateSpec" uuid="a04f93e4-1521-445e-8894-e52d5e91ab8e">
<period>.1</period>
<rateType>ClassicPeriodicDiscrete</rateType>
</rateSpec>
</baseRate>
</clocks>
- <clocks type="sto.Event" uuid="e41a78c8-b216-4f36-9dee-4f997b4b1c11">
+ <clocks type="sto.Event" uuid="885722a5-c5f4-4bd2-9701-8e7be9b9e22e">
<eventType>PARAMETER_CHANGE_EVENT</eventType>
<cNum>1</cNum>
<clockType>Event</clockType>
<identifier>ParameterChangeEvent</identifier>
- <rates type="sto.ModelWideEventRate" uuid="90d6839c-de09-4d36-8a0c-4a5a598feba9">
+ <rates type="sto.ModelWideEventRate" uuid="936e84dc-3ded-47f7-8ab3-c85ff31937e5">
<clockId>ParameterChangeEvent</clockId>
<rateIdx>-1</rateIdx>
<taskId>ModelWideParameterChangeEvent</taskId>
<useForExecution>NotForExecution</useForExecution>
- <rateSpec type="sto.RateSpec" uuid="1ff799ef-cf4a-4029-870d-05c901611246">
+ <rateSpec type="sto.RateSpec" uuid="19ce4db5-4ab9-480c-b5ec-8fffafc7135e">
<period>inf</period>
<rateType>ModelWideParameterChangeEvent</rateType>
</rateSpec>
@@ -275,15 +294,15 @@
</clocks>
<timeAdvanceMode>FixedStep</timeAdvanceMode>
</clockRegistry>
- <taskRegistry type="sto.TaskRegistry" uuid="51c7559b-0d95-45c2-89b5-e8ca1b1a2a36">
- <rootTaskHierarchyElements type="sto.Task" uuid="83d195cc-1e47-4c1f-bf41-cf7515d90315">
+ <taskRegistry type="sto.TaskRegistry" uuid="0d993ee2-3b65-4573-8898-5196aac386ca">
+ <rootTaskHierarchyElements type="sto.Task" uuid="7a8d6f06-f507-4752-b49d-2d40b196b835">
<isExplicit>true</isExplicit>
- <rates type="sto.ModelWideEventRate" uuid="ddbb3b2c-a7d0-41a7-9985-12f1dbe63b55">
+ <rates type="sto.ModelWideEventRate" uuid="e25b0b14-78dd-4492-8e0f-646a47ceb794">
<clockId>ParameterChangeEvent</clockId>
<rateIdx>-1</rateIdx>
<taskId>ModelWideParameterChangeEvent</taskId>
<useForExecution>NotForExecution</useForExecution>
- <rateSpec type="sto.RateSpec" uuid="9773adec-69fb-499f-b3d5-c885d4c27f15">
+ <rateSpec type="sto.RateSpec" uuid="f3a4db8e-6eb5-4170-b182-f2fb8ee48e34">
<period>inf</period>
<rateType>ModelWideParameterChangeEvent</rateType>
</rateSpec>
@@ -294,15 +313,15 @@
<identifier>ModelWideParameterChangeEvent</identifier>
<priority>-1</priority>
</rootTaskHierarchyElements>
- <rootTaskHierarchyElements type="sto.Task" uuid="8d35a7a1-6a0f-4104-8229-9f1d048673ef">
+ <rootTaskHierarchyElements type="sto.Task" uuid="d3bf08c5-2444-421e-8164-08c71bb6edf8">
<isExecutable>true</isExecutable>
<orderIndex>1</orderIndex>
- <rates type="sto.ClassicPeriodicDiscreteRate" uuid="cc569252-814e-451a-b975-9d4d66331c6d">
+ <rates type="sto.ClassicPeriodicDiscreteRate" uuid="f3a57984-7593-41ca-8198-978ffde0f85d">
<annotation>D1</annotation>
<clockId>socTouchDisplay::defaultTimer</clockId>
<description>Discrete 1</description>
<taskId>_task0</taskId>
- <rateSpec type="sto.RateSpec" uuid="b90a1e82-5f37-4e57-8497-d7a2efda69c7">
+ <rateSpec type="sto.RateSpec" uuid="d6123553-da2e-4156-bc60-26c4ac2e0a35">
<period>.1</period>
<rateType>ClassicPeriodicDiscrete</rateType>
</rateSpec>
@@ -313,11 +332,11 @@
<identifier>_task0</identifier>
<priority>40</priority>
</rootTaskHierarchyElements>
- <taskDependencyGraph type="sto.SerializedTaskConnectionList" uuid="2e3cd3f0-1e21-43b0-9c9c-83e394120168">
+ <taskDependencyGraph type="sto.SerializedTaskConnectionList" uuid="f2944dc6-df54-41da-8274-72899cb2e2c9">
<clockIdentifier>socTouchDisplay::defaultTimer</clockIdentifier>
<taskIdentifier>_task0</taskIdentifier>
</taskDependencyGraph>
- <taskDependencyGraph type="sto.SerializedTaskConnectionList" uuid="dd557f49-849f-47e0-be4f-d57d5f19b2d6">
+ <taskDependencyGraph type="sto.SerializedTaskConnectionList" uuid="e0cf3055-a235-4970-a1cf-fff869fdec18">
<clockIdentifier>ParameterChangeEvent</clockIdentifier>
<taskIdentifier>ModelWideParameterChangeEvent</taskIdentifier>
</taskDependencyGraph>
@@ -326,10 +345,10 @@
</sto.Registry>
</slexec_sto>
true
-
-
-
-
+
+
+
+
true
.1
2
@@ -339,7 +358,7 @@
1
FixedStepDiscrete
SOLVER_TYPE_FIXEDSTEP
-
+
8
64
32
@@ -355,13 +374,14 @@
64
-
-
-
+
+
+
0
1
2
3
+ 4
0
1
2
@@ -371,87 +391,95 @@
1
2
3
+ 4
0
1
2
3
4
-
-
-
-
+
+
+
+
true
true
true
true
true
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
+
+
+
+
+
1.0
.1
0.0
in_bTouchDetected
-
+
1.0
.1
0.0
ip_u32TouchDuration_msec
-
+
1.0
.1
0.0
ip_u32DisplayDuration_msec
-
+
10.0
.1
0.0
CAN_MESSAGE_BUS
Input
+
+ 1.0
+ .1
+ 0.0
+ uint32
+ ip_u32canId
+
socTouchDisplay
-
+
1.0
.1
0.0
boolean
op_bDisplayStatus
-
+
1.0
.1
0.0
boolean
op_bErrorStatus
-
+
1.0
.1
0.0
uint8
op_u8HundredsPlace
-
+
1.0
.1
0.0
uint8
op_u8TensPlace
-
+
1.0
.1
0.0
@@ -461,7 +489,7 @@
ROOT
-
+
@@ -489,6 +517,10 @@
portip_u32TouchDuration_msec
RootInport
+
+ portip_u32canId
+ RootInport
+
portop_bDisplayStatus
RootOutport
@@ -575,19 +607,19 @@
-
-
-
+
+
+
sltpEvents
-
+
sltpTaskGroups
-
-
-
+
+
+
D1
-
+
socTouchDisplay::defaultTimer
_task0
@@ -596,6 +628,6 @@
sltpTasks
-
+
\ No newline at end of file
diff --git a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/binfo.mat b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/binfo.mat
index 69adcb5..f70e749 100644
Binary files a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/binfo.mat and b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/binfo.mat differ
diff --git a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/minfo.mat b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/minfo.mat
index 8217a33..c87adbe 100644
Binary files a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/minfo.mat and b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/minfo.mat differ
diff --git a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/scv b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/scv
index 396e8c4..421544f 100644
Binary files a/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/scv and b/bs_touchAndLcd/slprj/ert/socTouchDisplay/tmwinternal/scv differ
diff --git a/bs_touchAndLcd/socTouchDisplay.slx b/bs_touchAndLcd/socTouchDisplay.slx
index 63ff07d..e2a29b8 100644
Binary files a/bs_touchAndLcd/socTouchDisplay.slx and b/bs_touchAndLcd/socTouchDisplay.slx differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/buildInfo.mat b/bs_touchAndLcd/socTouchDisplay_ert_rtw/buildInfo.mat
index 1183c40..9931635 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/buildInfo.mat and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/buildInfo.mat differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/codeInfo.mat b/bs_touchAndLcd/socTouchDisplay_ert_rtw/codeInfo.mat
index 1142149..208d3cc 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/codeInfo.mat and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/codeInfo.mat differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/codedescriptor.dmr b/bs_touchAndLcd/socTouchDisplay_ert_rtw/codedescriptor.dmr
index ec771fb..cb0aec4 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/codedescriptor.dmr and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/codedescriptor.dmr differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/compileInfo.mat b/bs_touchAndLcd/socTouchDisplay_ert_rtw/compileInfo.mat
index 7c8f4da..6a7279d 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/compileInfo.mat and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/compileInfo.mat differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/ert_main.c b/bs_touchAndLcd/socTouchDisplay_ert_rtw/ert_main.c
index 070f9a0..974572e 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/ert_main.c
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/ert_main.c
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.c b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.c
deleted file mode 100644
index d209c32..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.c
+++ /dev/null
@@ -1,96 +0,0 @@
-/*
- * File: rtGetInf.c
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#include "rtwtypes.h"
-#include "rtGetInf.h"
-#include
-#include "rt_nonfinite.h"
-#define NumBitsPerChar 8U
-
-/*
- * Initialize rtInf needed by the generated code.
- * Inf is initialized as non-signaling. Assumes IEEE.
- */
-real_T rtGetInf(void)
-{
- size_t bitsPerReal = sizeof(real_T) * (NumBitsPerChar);
- real_T inf = 0.0;
- if (bitsPerReal == 32U) {
- inf = rtGetInfF();
- } else {
- union {
- LittleEndianIEEEDouble bitVal;
- real_T fltVal;
- } tmpVal;
-
- tmpVal.bitVal.words.wordH = 0x7FF00000U;
- tmpVal.bitVal.words.wordL = 0x00000000U;
- inf = tmpVal.fltVal;
- }
-
- return inf;
-}
-
-/*
- * Initialize rtInfF needed by the generated code.
- * Inf is initialized as non-signaling. Assumes IEEE.
- */
-real32_T rtGetInfF(void)
-{
- IEEESingle infF;
- infF.wordL.wordLuint = 0x7F800000U;
- return infF.wordL.wordLreal;
-}
-
-/*
- * Initialize rtMinusInf needed by the generated code.
- * Inf is initialized as non-signaling. Assumes IEEE.
- */
-real_T rtGetMinusInf(void)
-{
- size_t bitsPerReal = sizeof(real_T) * (NumBitsPerChar);
- real_T minf = 0.0;
- if (bitsPerReal == 32U) {
- minf = rtGetMinusInfF();
- } else {
- union {
- LittleEndianIEEEDouble bitVal;
- real_T fltVal;
- } tmpVal;
-
- tmpVal.bitVal.words.wordH = 0xFFF00000U;
- tmpVal.bitVal.words.wordL = 0x00000000U;
- minf = tmpVal.fltVal;
- }
-
- return minf;
-}
-
-/*
- * Initialize rtMinusInfF needed by the generated code.
- * Inf is initialized as non-signaling. Assumes IEEE.
- */
-real32_T rtGetMinusInfF(void)
-{
- IEEESingle minfF;
- minfF.wordL.wordLuint = 0xFF800000U;
- return minfF.wordL.wordLreal;
-}
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.h
deleted file mode 100644
index 9f967f2..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetInf.h
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * File: rtGetInf.h
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#ifndef RTW_HEADER_rtGetInf_h_
-#define RTW_HEADER_rtGetInf_h_
-#include "rt_nonfinite.h"
-#include "rtwtypes.h"
-
-extern real_T rtGetInf(void);
-extern real32_T rtGetInfF(void);
-extern real_T rtGetMinusInf(void);
-extern real32_T rtGetMinusInfF(void);
-
-#endif /* RTW_HEADER_rtGetInf_h_ */
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.c b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.c
deleted file mode 100644
index 1138165..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * File: rtGetNaN.c
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#include "rtwtypes.h"
-#include "rtGetNaN.h"
-#include
-#include "rt_nonfinite.h"
-#define NumBitsPerChar 8U
-
-/*
- * Initialize rtNaN needed by the generated code.
- * NaN is initialized as non-signaling. Assumes IEEE.
- */
-real_T rtGetNaN(void)
-{
- size_t bitsPerReal = sizeof(real_T) * (NumBitsPerChar);
- real_T nan = 0.0;
- if (bitsPerReal == 32U) {
- nan = rtGetNaNF();
- } else {
- union {
- LittleEndianIEEEDouble bitVal;
- real_T fltVal;
- } tmpVal;
-
- tmpVal.bitVal.words.wordH = 0xFFF80000U;
- tmpVal.bitVal.words.wordL = 0x00000000U;
- nan = tmpVal.fltVal;
- }
-
- return nan;
-}
-
-/*
- * Initialize rtNaNF needed by the generated code.
- * NaN is initialized as non-signaling. Assumes IEEE.
- */
-real32_T rtGetNaNF(void)
-{
- IEEESingle nanF = { { 0.0F } };
-
- nanF.wordL.wordLuint = 0xFFC00000U;
- return nanF.wordL.wordLreal;
-}
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.h
deleted file mode 100644
index e6f8ec3..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtGetNaN.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * File: rtGetNaN.h
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#ifndef RTW_HEADER_rtGetNaN_h_
-#define RTW_HEADER_rtGetNaN_h_
-#include "rt_nonfinite.h"
-#include "rtwtypes.h"
-
-extern real_T rtGetNaN(void);
-extern real32_T rtGetNaNF(void);
-
-#endif /* RTW_HEADER_rtGetNaN_h_ */
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.c b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.c
deleted file mode 100644
index cee5a89..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.c
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * File: rt_nonfinite.c
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#include "rtGetNaN.h"
-#include "rtGetInf.h"
-#include
-#include "rtwtypes.h"
-#include "rt_nonfinite.h"
-#define NumBitsPerChar 8U
-
-real_T rtInf;
-real_T rtMinusInf;
-real_T rtNaN;
-real32_T rtInfF;
-real32_T rtMinusInfF;
-real32_T rtNaNF;
-
-/*
- * Initialize the rtInf, rtMinusInf, and rtNaN needed by the
- * generated code. NaN is initialized as non-signaling. Assumes IEEE.
- */
-void rt_InitInfAndNaN(size_t realSize)
-{
- (void) (realSize);
- rtNaN = rtGetNaN();
- rtNaNF = rtGetNaNF();
- rtInf = rtGetInf();
- rtInfF = rtGetInfF();
- rtMinusInf = rtGetMinusInf();
- rtMinusInfF = rtGetMinusInfF();
-}
-
-/* Test if value is infinite */
-boolean_T rtIsInf(real_T value)
-{
- return (boolean_T)((value==rtInf || value==rtMinusInf) ? 1U : 0U);
-}
-
-/* Test if single-precision value is infinite */
-boolean_T rtIsInfF(real32_T value)
-{
- return (boolean_T)(((value)==rtInfF || (value)==rtMinusInfF) ? 1U : 0U);
-}
-
-/* Test if value is not a number */
-boolean_T rtIsNaN(real_T value)
-{
- boolean_T result = (boolean_T) 0;
- size_t bitsPerReal = sizeof(real_T) * (NumBitsPerChar);
- if (bitsPerReal == 32U) {
- result = rtIsNaNF((real32_T)value);
- } else {
- union {
- LittleEndianIEEEDouble bitVal;
- real_T fltVal;
- } tmpVal;
-
- tmpVal.fltVal = value;
- result = (boolean_T)((tmpVal.bitVal.words.wordH & 0x7FF00000) == 0x7FF00000 &&
- ( (tmpVal.bitVal.words.wordH & 0x000FFFFF) != 0 ||
- (tmpVal.bitVal.words.wordL != 0) ));
- }
-
- return result;
-}
-
-/* Test if single-precision value is not a number */
-boolean_T rtIsNaNF(real32_T value)
-{
- IEEESingle tmp;
- tmp.wordL.wordLreal = value;
- return (boolean_T)( (tmp.wordL.wordLuint & 0x7F800000) == 0x7F800000 &&
- (tmp.wordL.wordLuint & 0x007FFFFF) != 0 );
-}
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.h
deleted file mode 100644
index d0aac5e..0000000
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rt_nonfinite.h
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * File: rt_nonfinite.h
- *
- * Code generated for Simulink model 'socTouchDisplay'.
- *
- * Model version : 1.104
- * Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
- *
- * Target selection: ert.tlc
- * Embedded hardware selection: Intel->x86-64 (Windows64)
- * Code generation objectives: Unspecified
- * Validation result: Not run
- */
-
-#ifndef RTW_HEADER_rt_nonfinite_h_
-#define RTW_HEADER_rt_nonfinite_h_
-#include
-#include "rtwtypes.h"
-#define NOT_USING_NONFINITE_LITERALS 1
-
-extern real_T rtInf;
-extern real_T rtMinusInf;
-extern real_T rtNaN;
-extern real32_T rtInfF;
-extern real32_T rtMinusInfF;
-extern real32_T rtNaNF;
-extern void rt_InitInfAndNaN(size_t realSize);
-extern boolean_T rtIsInf(real_T value);
-extern boolean_T rtIsInfF(real32_T value);
-extern boolean_T rtIsNaN(real_T value);
-extern boolean_T rtIsNaNF(real32_T value);
-typedef struct {
- struct {
- uint32_T wordH;
- uint32_T wordL;
- } words;
-} BigEndianIEEEDouble;
-
-typedef struct {
- struct {
- uint32_T wordL;
- uint32_T wordH;
- } words;
-} LittleEndianIEEEDouble;
-
-typedef struct {
- union {
- real32_T wordLreal;
- uint32_T wordLuint;
- } wordL;
-} IEEESingle;
-
-#endif /* RTW_HEADER_rt_nonfinite_h_ */
-
-/*
- * File trailer for generated code.
- *
- * [EOF]
- */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypes.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypes.h
index ca7aee2..5d570f9 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypes.h
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypes.h
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypeschksum.mat b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypeschksum.mat
index 354ad20..6f4dd72 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypeschksum.mat and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/rtwtypeschksum.mat differ
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.c b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.c
index d919bf0..746e117 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.c
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.c
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
@@ -16,7 +16,6 @@
#include "socTouchDisplay.h"
#include "rtwtypes.h"
#include
-#include "rt_nonfinite.h"
#include "socTouchDisplay_private.h"
/* Named constants for Chart: '/Chart' */
@@ -48,11 +47,12 @@ RT_MODEL_socTouchDisplay_T *const socTouchDisplay_M = &socTouchDisplay_M_;
/* Model step function */
void socTouchDisplay_step(void)
{
- real_T tmp;
+ int32_T i;
int32_T s3_iter;
- uint32_T tmp_0;
+ uint32_T tmp;
uint8_T rtb_Cast;
boolean_T Memory_PreviousInput;
+ boolean_T rtb_Equal;
boolean_T rtb_Memory;
/* Outputs for Iterator SubSystem: '/canMsgDecode' incorporates:
@@ -71,842 +71,38 @@ void socTouchDisplay_step(void)
&socTouchDisplay_B.Selector.Length, &socTouchDisplay_B.Selector.Data[0],
&socTouchDisplay_B.SFunction);
- /* Memory: '/Memory' */
- rtb_Memory = Memory_PreviousInput;
-
- /* S-Function (scanunpack): '/CAN Unpack' */
- {
- /* S-Function (scanunpack): '/CAN Unpack' */
- if ((8 == socTouchDisplay_B.SFunction.Length) &&
- (socTouchDisplay_B.SFunction.ID != INVALID_CAN_ID) ) {
- if ((220839530 == socTouchDisplay_B.SFunction.ID) && (1U ==
- socTouchDisplay_B.SFunction.Extended) ) {
- {
- /* --------------- START Unpacking signal 16 ------------------
- * startBit = 0
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- {
- real_T outValue = 0;
-
- {
- uint8_T unpackedValue = 0;
-
- {
- uint8_T tempValue = (uint8_T) (0);
-
- {
- tempValue = tempValue | (uint8_T)
- (socTouchDisplay_B.SFunction.Data[0]);
- }
-
- unpackedValue = tempValue;
- }
-
- outValue = (real_T) (unpackedValue);
- }
-
- {
- real_T result = (real_T) outValue;
- socTouchDisplay_B.CANUnpack_o17 = result;
- }
- }
-
- /* --------------- START Unpacking signal 0 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 1 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 2 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 3 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 4 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 5 ------------------
- * startBit = 56
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 6 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 7 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 8 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 9 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 10 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 11 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 12 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 13 ------------------
- * startBit = 56
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 14 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 15 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 17 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 18 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 19 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 20 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 21 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 22 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 23 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 24 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 25 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 26 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 27 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 28 ------------------
- * startBit = 8
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 29 ------------------
- * startBit = 9
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 30 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 31 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 32 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 33 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 34 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 35 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 36 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 37 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 38 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 39 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 40 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 41 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 42 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 43 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 44 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 45 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 46 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 47 ------------------
- * startBit = 9
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 48 ------------------
- * startBit = 8
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 49 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 50 ------------------
- * startBit = 10
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 51 ------------------
- * startBit = 11
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 52 ------------------
- * startBit = 13
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 53 ------------------
- * startBit = 14
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 54 ------------------
- * startBit = 15
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 55 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /* Perform the mode dependency check to value */
- if (socTouchDisplay_B.CANUnpack_o17 == 2.0) {
- {
- real_T outValue = 0;
-
- {
- uint8_T unpackedValue = 0;
-
- {
- uint8_T tempValue = (uint8_T) (0);
-
- {
- tempValue = tempValue | (uint8_T)
- (socTouchDisplay_B.SFunction.Data[2]);
- }
-
- unpackedValue = tempValue;
- }
-
- outValue = (real_T) (unpackedValue);
- }
-
- {
- real_T result = (real_T) outValue;
- socTouchDisplay_B.CANUnpack_o56 = result;
- }
- }
- }
-
- /* --------------- START Unpacking signal 56 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 57 ------------------
- * startBit = 12
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
- }
- }
+ /* RelationalOperator: '/Equal' incorporates:
+ * Inport: '/ip_u32canId'
+ */
+ rtb_Equal = (socTouchDisplay_B.SFunction.ID == socTouchDisplay_U.ip_u32canId);
+
+ /* Outputs for Enabled SubSystem: '/Enabled Subsystem' incorporates:
+ * EnablePort: '/Enable'
+ */
+ /* Logic: '/AND' incorporates:
+ * Constant: '/Constant'
+ * RelationalOperator: '/Equal1'
+ */
+ if ((socTouchDisplay_B.SFunction.Data[0] == 2) && rtb_Equal) {
+ for (i = 0; i < 8; i++) {
+ /* SignalConversion generated from: '/In1' */
+ socTouchDisplay_B.In1[i] = socTouchDisplay_B.SFunction.Data[i];
}
}
+ /* End of Logic: '/AND' */
+ /* End of Outputs for SubSystem: '/Enabled Subsystem' */
+
/* DataTypeConversion: '/Cast' */
- tmp = floor(socTouchDisplay_B.CANUnpack_o56);
- if (rtIsNaN(tmp) || rtIsInf(tmp)) {
- tmp = 0.0;
- } else {
- tmp = fmod(tmp, 256.0);
- }
+ rtb_Cast = socTouchDisplay_B.In1[2];
- if (tmp < 0.0) {
- rtb_Cast = (uint8_T)-(int8_T)(uint8_T)-tmp;
- } else {
- rtb_Cast = (uint8_T)tmp;
- }
-
- /* End of DataTypeConversion: '/Cast' */
+ /* Memory: '/Memory' */
+ rtb_Memory = Memory_PreviousInput;
/* Update for Memory: '/Memory' incorporates:
* Logic: '/OR'
- * RelationalOperator: '/Equal'
*/
- Memory_PreviousInput = ((socTouchDisplay_B.SFunction.ID == 220839530U) ||
- Memory_PreviousInput);
+ Memory_PreviousInput = (rtb_Equal || Memory_PreviousInput);
}
/* End of Outputs for SubSystem: '/canMsgDecode' */
@@ -1012,9 +208,9 @@ void socTouchDisplay_step(void)
socTouchDisplay_DW.durationCounter_2 = 0U;
}
- tmp_0 = (uint32_T)ceil(socTouchDisplay_U.ip_u32TouchDuration_msec);
- if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_2 * 100) >
- tmp_0) && Memory_PreviousInput) {
+ tmp = (uint32_T)ceil(socTouchDisplay_U.ip_u32TouchDuration_msec);
+ if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_2 * 100) > tmp)
+ && Memory_PreviousInput) {
socTouchDisplay_DW.temporalCounter_i1 = 0U;
socTouchDisplay_DW.is_c3_socTouchDisplay = socTouchDisplay_IN_displaySoc;
@@ -1026,7 +222,7 @@ void socTouchDisplay_step(void)
}
if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_1_g * 100) >
- tmp_0) && (!Memory_PreviousInput)) {
+ tmp) && (!Memory_PreviousInput)) {
socTouchDisplay_DW.temporalCounter_i1 = 0U;
socTouchDisplay_DW.is_c3_socTouchDisplay =
socTouchDisplay_IN_displayError;
@@ -1114,18 +310,7 @@ void socTouchDisplay_step(void)
/* Model initialize function */
void socTouchDisplay_initialize(void)
{
- /* Registration code */
-
- /* initialize non-finites */
- rt_InitInfAndNaN(sizeof(real_T));
-
- /* SystemInitialize for Iterator SubSystem: '/canMsgDecode' */
-
- /* Start for S-Function (scanunpack): '/CAN Unpack' */
-
- /*-----------S-Function Block: /CAN Unpack -----------------*/
-
- /* End of SystemInitialize for SubSystem: '/canMsgDecode' */
+ /* (no initialization code required) */
}
/* Model terminate function */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.h
index 8782958..aba0a60 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.h
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.h
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
@@ -18,11 +18,9 @@
#ifndef socTouchDisplay_COMMON_INCLUDES_
#define socTouchDisplay_COMMON_INCLUDES_
#include "rtwtypes.h"
-#include "can_message.h"
#endif /* socTouchDisplay_COMMON_INCLUDES_ */
#include "socTouchDisplay_types.h"
-#include "rt_nonfinite.h"
#include "ivec_rte_dummy.h"
/* Macros for accessing real-time model data structure */
@@ -38,64 +36,7 @@
typedef struct {
CAN_MESSAGE_BUS Selector; /* '/Selector' */
CAN_MESSAGE_BUS SFunction; /* '/S-Function' */
- real_T CANUnpack_o1; /* '/CAN Unpack' */
- real_T CANUnpack_o2; /* '/CAN Unpack' */
- real_T CANUnpack_o3; /* '/CAN Unpack' */
- real_T CANUnpack_o4; /* '/CAN Unpack' */
- real_T CANUnpack_o5; /* '/CAN Unpack' */
- real_T CANUnpack_o6; /* '/CAN Unpack' */
- real_T CANUnpack_o7; /* '/CAN Unpack' */
- real_T CANUnpack_o8; /* '/CAN Unpack' */
- real_T CANUnpack_o9; /* '/CAN Unpack' */
- real_T CANUnpack_o10; /* '/CAN Unpack' */
- real_T CANUnpack_o11; /* '/CAN Unpack' */
- real_T CANUnpack_o12; /* '/CAN Unpack' */
- real_T CANUnpack_o13; /* '/CAN Unpack' */
- real_T CANUnpack_o14; /* '/CAN Unpack' */
- real_T CANUnpack_o15; /* '/CAN Unpack' */
- real_T CANUnpack_o16; /* '/CAN Unpack' */
- real_T CANUnpack_o17; /* '/CAN Unpack' */
- real_T CANUnpack_o18; /* '/CAN Unpack' */
- real_T CANUnpack_o19; /* '/CAN Unpack' */
- real_T CANUnpack_o20; /* '/CAN Unpack' */
- real_T CANUnpack_o21; /* '/CAN Unpack' */
- real_T CANUnpack_o22; /* '/CAN Unpack' */
- real_T CANUnpack_o23; /* '/CAN Unpack' */
- real_T CANUnpack_o24; /* '/CAN Unpack' */
- real_T CANUnpack_o25; /* '/CAN Unpack' */
- real_T CANUnpack_o26; /* '/CAN Unpack' */
- real_T CANUnpack_o27; /* '/CAN Unpack' */
- real_T CANUnpack_o28; /* '/CAN Unpack' */
- real_T CANUnpack_o29; /* '/CAN Unpack' */
- real_T CANUnpack_o30; /* '/CAN Unpack' */
- real_T CANUnpack_o31; /* '/CAN Unpack' */
- real_T CANUnpack_o32; /* '/CAN Unpack' */
- real_T CANUnpack_o33; /* '/CAN Unpack' */
- real_T CANUnpack_o34; /* '/CAN Unpack' */
- real_T CANUnpack_o35; /* '/CAN Unpack' */
- real_T CANUnpack_o36; /* '/CAN Unpack' */
- real_T CANUnpack_o37; /* '/CAN Unpack' */
- real_T CANUnpack_o38; /* '/CAN Unpack' */
- real_T CANUnpack_o39; /* '/CAN Unpack' */
- real_T CANUnpack_o40; /* '/CAN Unpack' */
- real_T CANUnpack_o41; /* '/CAN Unpack' */
- real_T CANUnpack_o42; /* '/CAN Unpack' */
- real_T CANUnpack_o43; /* '/CAN Unpack' */
- real_T CANUnpack_o44; /* '/CAN Unpack' */
- real_T CANUnpack_o45; /* '/CAN Unpack' */
- real_T CANUnpack_o46; /* '/CAN Unpack' */
- real_T CANUnpack_o47; /* '/CAN Unpack' */
- real_T CANUnpack_o48; /* '/CAN Unpack' */
- real_T CANUnpack_o49; /* '/CAN Unpack' */
- real_T CANUnpack_o50; /* '/CAN Unpack' */
- real_T CANUnpack_o51; /* '/CAN Unpack' */
- real_T CANUnpack_o52; /* '/CAN Unpack' */
- real_T CANUnpack_o53; /* '/CAN Unpack' */
- real_T CANUnpack_o54; /* '/CAN Unpack' */
- real_T CANUnpack_o55; /* '/CAN Unpack' */
- real_T CANUnpack_o56; /* '/CAN Unpack' */
- real_T CANUnpack_o57; /* '/CAN Unpack' */
- real_T CANUnpack_o58; /* '/CAN Unpack' */
+ uint8_T In1[8]; /* '/In1' */
} B_socTouchDisplay_T;
/* Block states (default storage) for system '' */
@@ -105,8 +46,6 @@ typedef struct {
uint32_T temporalCounter_i1; /* '/Chart' */
uint32_T durationCounter_1_g; /* '/Chart' */
uint32_T durationCounter_2; /* '/Chart' */
- int_T CANUnpack_ModeSignalID; /* '/CAN Unpack' */
- int_T CANUnpack_StatusPortID; /* '/CAN Unpack' */
uint8_T is_active_c1_socTouchDisplay;/* '/Chart1' */
uint8_T is_c1_socTouchDisplay; /* '/Chart1' */
uint8_T is_active_c3_socTouchDisplay;/* '/Chart' */
@@ -119,6 +58,7 @@ typedef struct {
real_T ip_u32TouchDuration_msec; /* '/ip_u32TouchDuration_msec' */
real_T ip_u32DisplayDuration_msec; /* '/ip_u32DisplayDuration_msec' */
CAN_MESSAGE_BUS Input[MAX_CAN_MESSAGE_INSTANCE];/* '/Input' */
+ uint32_T ip_u32canId; /* '/ip_u32canId' */
} ExtU_socTouchDisplay_T;
/* External outputs (root outports fed by signals with default storage) */
@@ -182,6 +122,7 @@ extern RT_MODEL_socTouchDisplay_T *const socTouchDisplay_M;
* '' : 'socTouchDisplay/Chart1'
* '' : 'socTouchDisplay/canMsgDecode'
* '' : 'socTouchDisplay/displayData'
+ * '' : 'socTouchDisplay/canMsgDecode/Enabled Subsystem'
*/
#endif /* RTW_HEADER_socTouchDisplay_h_ */
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.mk b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.mk
index da141bf..196814f 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.mk
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.mk
@@ -2,7 +2,7 @@
## Makefile generated for component 'socTouchDisplay'.
##
## Makefile : socTouchDisplay.mk
-## Generated on : Mon Oct 28 16:04:26 2024
+## Generated on : Thu Nov 07 22:32:48 2024
## Final product: $(RELATIVE_PATH_TO_ANCHOR)/socTouchDisplay.exe
## Product type : executable
##
@@ -23,7 +23,7 @@ MAKEFILE = socTouchDisplay.mk
MATLAB_ROOT = C:/PROGRA~1/MATLAB/R2023b
MATLAB_BIN = C:/PROGRA~1/MATLAB/R2023b/bin
MATLAB_ARCH_BIN = $(MATLAB_BIN)/win64
-START_DIR = D:/MATLAB/bs_touchAndLcd
+START_DIR = D:/AAR/cantouart_ti/bs_touchAndLcd
SOLVER =
SOLVER_OBJ =
CLASSIC_INTERFACE = 0
@@ -183,7 +183,7 @@ DEFINES = $(DEFINES_BUILD_ARGS) $(DEFINES_CUSTOM) $(DEFINES_OPTS) $(DEFINES_STAN
## SOURCE FILES
###########################################################################
-SRCS = $(START_DIR)/socTouchDisplay_ert_rtw/rtGetInf.c $(START_DIR)/socTouchDisplay_ert_rtw/rtGetNaN.c $(START_DIR)/socTouchDisplay_ert_rtw/rt_nonfinite.c $(START_DIR)/socTouchDisplay_ert_rtw/socTouchDisplay.c
+SRCS = $(START_DIR)/socTouchDisplay_ert_rtw/socTouchDisplay.c
MAIN_SRC = $(START_DIR)/socTouchDisplay_ert_rtw/ert_main.c
@@ -193,7 +193,7 @@ ALL_SRCS = $(SRCS) $(MAIN_SRC)
## OBJECTS
###########################################################################
-OBJS = rtGetInf.obj rtGetNaN.obj rt_nonfinite.obj socTouchDisplay.obj
+OBJS = socTouchDisplay.obj
MAIN_OBJ = ert_main.obj
@@ -515,18 +515,6 @@ ert_main.obj : $(START_DIR)/socTouchDisplay_ert_rtw/ert_main.c
$(CC) $(CFLAGS) -o "$@" "$<"
-rtGetInf.obj : $(START_DIR)/socTouchDisplay_ert_rtw/rtGetInf.c
- $(CC) $(CFLAGS) -o "$@" "$<"
-
-
-rtGetNaN.obj : $(START_DIR)/socTouchDisplay_ert_rtw/rtGetNaN.c
- $(CC) $(CFLAGS) -o "$@" "$<"
-
-
-rt_nonfinite.obj : $(START_DIR)/socTouchDisplay_ert_rtw/rt_nonfinite.c
- $(CC) $(CFLAGS) -o "$@" "$<"
-
-
socTouchDisplay.obj : $(START_DIR)/socTouchDisplay_ert_rtw/socTouchDisplay.c
$(CC) $(CFLAGS) -o "$@" "$<"
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.rsp b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.rsp
index 65ca82f..764f2a3 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.rsp
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay.rsp
@@ -1,5 +1,2 @@
ert_main.obj
-rtGetInf.obj
-rtGetNaN.obj
-rt_nonfinite.obj
socTouchDisplay.obj
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_comp.rsp b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_comp.rsp
index 10bda03..38460a8 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_comp.rsp
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_comp.rsp
@@ -1,8 +1,7 @@
--ID:/MATLAB/bs_touchAndLcd
--ID:/MATLAB/bs_touchAndLcd/socTouchDisplay_ert_rtw
+-ID:/AAR/cantouart_ti/bs_touchAndLcd
+-ID:/AAR/cantouart_ti/bs_touchAndLcd/socTouchDisplay_ert_rtw
-IC:/Program\ Files/MATLAB/R2023b/extern/include
-IC:/Program\ Files/MATLAB/R2023b/simulink/include
-IC:/Program\ Files/MATLAB/R2023b/rtw/c/src
-IC:/Program\ Files/MATLAB/R2023b/rtw/c/src/ext_mode/common
-IC:/Program\ Files/MATLAB/R2023b/rtw/c/ert
--IC:/Program\ Files/MATLAB/R2023b/toolbox/shared/can/src/scanutil
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_private.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_private.h
index 911ccfe..9b74ee1 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_private.h
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_private.h
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_types.h b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_types.h
index 7153d59..07a7b29 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_types.h
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/socTouchDisplay_types.h
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/simulink_cache.xml b/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/simulink_cache.xml
index e20125f..0b3422a 100644
--- a/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/simulink_cache.xml
+++ b/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/simulink_cache.xml
@@ -1,6 +1,6 @@
-
- 2oxCrrkWYAfYsid2BKElsqmUm/b9blgB8ROjvTY5kkSHI15WRdu5OidAq6Boxegx/r4DqPRAm5D7oEE/jWVWyQ==
+
+ 8bTFSfmqHVlYhNqKtSda3c/Kq/qLr9+hTAYNegrcsTT+6h7F5vQznuwmUe5uezw4aTCxAwaPBDr/BUHto5jDVQ==
\ No newline at end of file
diff --git a/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/tr b/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/tr
index c8a891e..4a193df 100644
Binary files a/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/tr and b/bs_touchAndLcd/socTouchDisplay_ert_rtw/tmwinternal/tr differ
diff --git a/ivec_APP/inc/socTouchDisplay.h b/ivec_APP/inc/socTouchDisplay.h
index 8782958..aba0a60 100644
--- a/ivec_APP/inc/socTouchDisplay.h
+++ b/ivec_APP/inc/socTouchDisplay.h
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
@@ -18,11 +18,9 @@
#ifndef socTouchDisplay_COMMON_INCLUDES_
#define socTouchDisplay_COMMON_INCLUDES_
#include "rtwtypes.h"
-#include "can_message.h"
#endif /* socTouchDisplay_COMMON_INCLUDES_ */
#include "socTouchDisplay_types.h"
-#include "rt_nonfinite.h"
#include "ivec_rte_dummy.h"
/* Macros for accessing real-time model data structure */
@@ -38,64 +36,7 @@
typedef struct {
CAN_MESSAGE_BUS Selector; /* '/Selector' */
CAN_MESSAGE_BUS SFunction; /* '/S-Function' */
- real_T CANUnpack_o1; /* '/CAN Unpack' */
- real_T CANUnpack_o2; /* '/CAN Unpack' */
- real_T CANUnpack_o3; /* '/CAN Unpack' */
- real_T CANUnpack_o4; /* '/CAN Unpack' */
- real_T CANUnpack_o5; /* '/CAN Unpack' */
- real_T CANUnpack_o6; /* '/CAN Unpack' */
- real_T CANUnpack_o7; /* '/CAN Unpack' */
- real_T CANUnpack_o8; /* '/CAN Unpack' */
- real_T CANUnpack_o9; /* '/CAN Unpack' */
- real_T CANUnpack_o10; /* '/CAN Unpack' */
- real_T CANUnpack_o11; /* '/CAN Unpack' */
- real_T CANUnpack_o12; /* '/CAN Unpack' */
- real_T CANUnpack_o13; /* '/CAN Unpack' */
- real_T CANUnpack_o14; /* '/CAN Unpack' */
- real_T CANUnpack_o15; /* '/CAN Unpack' */
- real_T CANUnpack_o16; /* '/CAN Unpack' */
- real_T CANUnpack_o17; /* '/CAN Unpack' */
- real_T CANUnpack_o18; /* '/CAN Unpack' */
- real_T CANUnpack_o19; /* '/CAN Unpack' */
- real_T CANUnpack_o20; /* '/CAN Unpack' */
- real_T CANUnpack_o21; /* '/CAN Unpack' */
- real_T CANUnpack_o22; /* '/CAN Unpack' */
- real_T CANUnpack_o23; /* '/CAN Unpack' */
- real_T CANUnpack_o24; /* '/CAN Unpack' */
- real_T CANUnpack_o25; /* '/CAN Unpack' */
- real_T CANUnpack_o26; /* '/CAN Unpack' */
- real_T CANUnpack_o27; /* '/CAN Unpack' */
- real_T CANUnpack_o28; /* '/CAN Unpack' */
- real_T CANUnpack_o29; /* '/CAN Unpack' */
- real_T CANUnpack_o30; /* '/CAN Unpack' */
- real_T CANUnpack_o31; /* '/CAN Unpack' */
- real_T CANUnpack_o32; /* '/CAN Unpack' */
- real_T CANUnpack_o33; /* '/CAN Unpack' */
- real_T CANUnpack_o34; /* '/CAN Unpack' */
- real_T CANUnpack_o35; /* '/CAN Unpack' */
- real_T CANUnpack_o36; /* '/CAN Unpack' */
- real_T CANUnpack_o37; /* '/CAN Unpack' */
- real_T CANUnpack_o38; /* '/CAN Unpack' */
- real_T CANUnpack_o39; /* '/CAN Unpack' */
- real_T CANUnpack_o40; /* '/CAN Unpack' */
- real_T CANUnpack_o41; /* '/CAN Unpack' */
- real_T CANUnpack_o42; /* '/CAN Unpack' */
- real_T CANUnpack_o43; /* '/CAN Unpack' */
- real_T CANUnpack_o44; /* '/CAN Unpack' */
- real_T CANUnpack_o45; /* '/CAN Unpack' */
- real_T CANUnpack_o46; /* '/CAN Unpack' */
- real_T CANUnpack_o47; /* '/CAN Unpack' */
- real_T CANUnpack_o48; /* '/CAN Unpack' */
- real_T CANUnpack_o49; /* '/CAN Unpack' */
- real_T CANUnpack_o50; /* '/CAN Unpack' */
- real_T CANUnpack_o51; /* '/CAN Unpack' */
- real_T CANUnpack_o52; /* '/CAN Unpack' */
- real_T CANUnpack_o53; /* '/CAN Unpack' */
- real_T CANUnpack_o54; /* '/CAN Unpack' */
- real_T CANUnpack_o55; /* '/CAN Unpack' */
- real_T CANUnpack_o56; /* '/CAN Unpack' */
- real_T CANUnpack_o57; /* '/CAN Unpack' */
- real_T CANUnpack_o58; /* '/CAN Unpack' */
+ uint8_T In1[8]; /* '/In1' */
} B_socTouchDisplay_T;
/* Block states (default storage) for system '' */
@@ -105,8 +46,6 @@ typedef struct {
uint32_T temporalCounter_i1; /* '/Chart' */
uint32_T durationCounter_1_g; /* '/Chart' */
uint32_T durationCounter_2; /* '/Chart' */
- int_T CANUnpack_ModeSignalID; /* '/CAN Unpack' */
- int_T CANUnpack_StatusPortID; /* '/CAN Unpack' */
uint8_T is_active_c1_socTouchDisplay;/* '/Chart1' */
uint8_T is_c1_socTouchDisplay; /* '/Chart1' */
uint8_T is_active_c3_socTouchDisplay;/* '/Chart' */
@@ -119,6 +58,7 @@ typedef struct {
real_T ip_u32TouchDuration_msec; /* '/ip_u32TouchDuration_msec' */
real_T ip_u32DisplayDuration_msec; /* '/ip_u32DisplayDuration_msec' */
CAN_MESSAGE_BUS Input[MAX_CAN_MESSAGE_INSTANCE];/* '/Input' */
+ uint32_T ip_u32canId; /* '/ip_u32canId' */
} ExtU_socTouchDisplay_T;
/* External outputs (root outports fed by signals with default storage) */
@@ -182,6 +122,7 @@ extern RT_MODEL_socTouchDisplay_T *const socTouchDisplay_M;
* '' : 'socTouchDisplay/Chart1'
* '' : 'socTouchDisplay/canMsgDecode'
* '' : 'socTouchDisplay/displayData'
+ * '' : 'socTouchDisplay/canMsgDecode/Enabled Subsystem'
*/
#endif /* RTW_HEADER_socTouchDisplay_h_ */
diff --git a/ivec_APP/src/socTouchDisplay.c b/ivec_APP/src/socTouchDisplay.c
index d919bf0..746e117 100644
--- a/ivec_APP/src/socTouchDisplay.c
+++ b/ivec_APP/src/socTouchDisplay.c
@@ -3,9 +3,9 @@
*
* Code generated for Simulink model 'socTouchDisplay'.
*
- * Model version : 1.104
+ * Model version : 1.111
* Simulink Coder version : 23.2 (R2023b) 01-Aug-2023
- * C/C++ source code generated on : Mon Oct 28 16:04:13 2024
+ * C/C++ source code generated on : Thu Nov 7 22:32:36 2024
*
* Target selection: ert.tlc
* Embedded hardware selection: Intel->x86-64 (Windows64)
@@ -16,7 +16,6 @@
#include "socTouchDisplay.h"
#include "rtwtypes.h"
#include
-#include "rt_nonfinite.h"
#include "socTouchDisplay_private.h"
/* Named constants for Chart: '/Chart' */
@@ -48,11 +47,12 @@ RT_MODEL_socTouchDisplay_T *const socTouchDisplay_M = &socTouchDisplay_M_;
/* Model step function */
void socTouchDisplay_step(void)
{
- real_T tmp;
+ int32_T i;
int32_T s3_iter;
- uint32_T tmp_0;
+ uint32_T tmp;
uint8_T rtb_Cast;
boolean_T Memory_PreviousInput;
+ boolean_T rtb_Equal;
boolean_T rtb_Memory;
/* Outputs for Iterator SubSystem: '/canMsgDecode' incorporates:
@@ -71,842 +71,38 @@ void socTouchDisplay_step(void)
&socTouchDisplay_B.Selector.Length, &socTouchDisplay_B.Selector.Data[0],
&socTouchDisplay_B.SFunction);
- /* Memory: '/Memory' */
- rtb_Memory = Memory_PreviousInput;
-
- /* S-Function (scanunpack): '/CAN Unpack' */
- {
- /* S-Function (scanunpack): '/CAN Unpack' */
- if ((8 == socTouchDisplay_B.SFunction.Length) &&
- (socTouchDisplay_B.SFunction.ID != INVALID_CAN_ID) ) {
- if ((220839530 == socTouchDisplay_B.SFunction.ID) && (1U ==
- socTouchDisplay_B.SFunction.Extended) ) {
- {
- /* --------------- START Unpacking signal 16 ------------------
- * startBit = 0
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- {
- real_T outValue = 0;
-
- {
- uint8_T unpackedValue = 0;
-
- {
- uint8_T tempValue = (uint8_T) (0);
-
- {
- tempValue = tempValue | (uint8_T)
- (socTouchDisplay_B.SFunction.Data[0]);
- }
-
- unpackedValue = tempValue;
- }
-
- outValue = (real_T) (unpackedValue);
- }
-
- {
- real_T result = (real_T) outValue;
- socTouchDisplay_B.CANUnpack_o17 = result;
- }
- }
-
- /* --------------- START Unpacking signal 0 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 1 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 2 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 3 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 4 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 5 ------------------
- * startBit = 56
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 6 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 7 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 8 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 9 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 10 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 11 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 12 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 13 ------------------
- * startBit = 56
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 14 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 15 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 17 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 18 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 19 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 20 ------------------
- * startBit = 48
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 21 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 22 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 23 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 24 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 25 ------------------
- * startBit = 24
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 26 ------------------
- * startBit = 32
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 27 ------------------
- * startBit = 40
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 28 ------------------
- * startBit = 8
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 29 ------------------
- * startBit = 9
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 30 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 31 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 32 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 33 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 34 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 35 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 36 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 37 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 38 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 39 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 40 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 41 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 42 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 43 ------------------
- * startBit = 16
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 44 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 45 ------------------
- * startBit = 48
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 46 ------------------
- * startBit = 32
- * length = 16
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 47 ------------------
- * startBit = 9
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 48 ------------------
- * startBit = 8
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 49 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = SIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 50 ------------------
- * startBit = 10
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 51 ------------------
- * startBit = 11
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 52 ------------------
- * startBit = 13
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 53 ------------------
- * startBit = 14
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 54 ------------------
- * startBit = 15
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 55 ------------------
- * startBit = 16
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /* Perform the mode dependency check to value */
- if (socTouchDisplay_B.CANUnpack_o17 == 2.0) {
- {
- real_T outValue = 0;
-
- {
- uint8_T unpackedValue = 0;
-
- {
- uint8_T tempValue = (uint8_T) (0);
-
- {
- tempValue = tempValue | (uint8_T)
- (socTouchDisplay_B.SFunction.Data[2]);
- }
-
- unpackedValue = tempValue;
- }
-
- outValue = (real_T) (unpackedValue);
- }
-
- {
- real_T result = (real_T) outValue;
- socTouchDisplay_B.CANUnpack_o56 = result;
- }
- }
- }
-
- /* --------------- START Unpacking signal 56 ------------------
- * startBit = 8
- * length = 8
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
-
- /* --------------- START Unpacking signal 57 ------------------
- * startBit = 12
- * length = 1
- * desiredSignalByteLayout = BIGENDIAN
- * dataType = UNSIGNED
- * factor = 1.0
- * offset = 0.0
- * -----------------------------------------------------------------------*/
- /*
- * Signal is not connected or connected to terminator.
- * No unpacking code generated.
- */
- }
- }
+ /* RelationalOperator: '/Equal' incorporates:
+ * Inport: '/ip_u32canId'
+ */
+ rtb_Equal = (socTouchDisplay_B.SFunction.ID == socTouchDisplay_U.ip_u32canId);
+
+ /* Outputs for Enabled SubSystem: '/Enabled Subsystem' incorporates:
+ * EnablePort: '/Enable'
+ */
+ /* Logic: '/AND' incorporates:
+ * Constant: '/Constant'
+ * RelationalOperator: '/Equal1'
+ */
+ if ((socTouchDisplay_B.SFunction.Data[0] == 2) && rtb_Equal) {
+ for (i = 0; i < 8; i++) {
+ /* SignalConversion generated from: '/In1' */
+ socTouchDisplay_B.In1[i] = socTouchDisplay_B.SFunction.Data[i];
}
}
+ /* End of Logic: '/AND' */
+ /* End of Outputs for SubSystem: '/Enabled Subsystem' */
+
/* DataTypeConversion: '/Cast' */
- tmp = floor(socTouchDisplay_B.CANUnpack_o56);
- if (rtIsNaN(tmp) || rtIsInf(tmp)) {
- tmp = 0.0;
- } else {
- tmp = fmod(tmp, 256.0);
- }
+ rtb_Cast = socTouchDisplay_B.In1[2];
- if (tmp < 0.0) {
- rtb_Cast = (uint8_T)-(int8_T)(uint8_T)-tmp;
- } else {
- rtb_Cast = (uint8_T)tmp;
- }
-
- /* End of DataTypeConversion: '/Cast' */
+ /* Memory: '/Memory' */
+ rtb_Memory = Memory_PreviousInput;
/* Update for Memory: '/Memory' incorporates:
* Logic: '/OR'
- * RelationalOperator: '/Equal'
*/
- Memory_PreviousInput = ((socTouchDisplay_B.SFunction.ID == 220839530U) ||
- Memory_PreviousInput);
+ Memory_PreviousInput = (rtb_Equal || Memory_PreviousInput);
}
/* End of Outputs for SubSystem: '/canMsgDecode' */
@@ -1012,9 +208,9 @@ void socTouchDisplay_step(void)
socTouchDisplay_DW.durationCounter_2 = 0U;
}
- tmp_0 = (uint32_T)ceil(socTouchDisplay_U.ip_u32TouchDuration_msec);
- if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_2 * 100) >
- tmp_0) && Memory_PreviousInput) {
+ tmp = (uint32_T)ceil(socTouchDisplay_U.ip_u32TouchDuration_msec);
+ if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_2 * 100) > tmp)
+ && Memory_PreviousInput) {
socTouchDisplay_DW.temporalCounter_i1 = 0U;
socTouchDisplay_DW.is_c3_socTouchDisplay = socTouchDisplay_IN_displaySoc;
@@ -1026,7 +222,7 @@ void socTouchDisplay_step(void)
}
if (((uint32_T)((int32_T)socTouchDisplay_DW.durationCounter_1_g * 100) >
- tmp_0) && (!Memory_PreviousInput)) {
+ tmp) && (!Memory_PreviousInput)) {
socTouchDisplay_DW.temporalCounter_i1 = 0U;
socTouchDisplay_DW.is_c3_socTouchDisplay =
socTouchDisplay_IN_displayError;
@@ -1114,18 +310,7 @@ void socTouchDisplay_step(void)
/* Model initialize function */
void socTouchDisplay_initialize(void)
{
- /* Registration code */
-
- /* initialize non-finites */
- rt_InitInfAndNaN(sizeof(real_T));
-
- /* SystemInitialize for Iterator SubSystem: '/canMsgDecode' */
-
- /* Start for S-Function (scanunpack): '/CAN Unpack' */
-
- /*-----------S-Function Block: /CAN Unpack -----------------*/
-
- /* End of SystemInitialize for SubSystem: '/canMsgDecode' */
+ /* (no initialization code required) */
}
/* Model terminate function */
diff --git a/ivec_RTE/src/ivec_rte.c b/ivec_RTE/src/ivec_rte.c
index d132721..28ac0bf 100644
--- a/ivec_RTE/src/ivec_rte.c
+++ b/ivec_RTE/src/ivec_rte.c
@@ -18,6 +18,7 @@ McalUartHandle_s g_xUartHandle;
uint32_t g_u32UartSpeed = 0;
uint16_t g_u16CanSpeed = 0;
uint8_t g_pu8Buf[MAX_PACKET_LENGTH] = {0};
+volatile uint32_t g_u32CanId = 0x1fffffff;
static uint8_t __gprv_u8Idx = 0;
static uint8_t __gprv_u8Buf = 0;
@@ -88,6 +89,7 @@ void vRTE_MatlabRun(void)
socTouchDisplay_U.in_bTouchDetected = (u32MCAL_gpioRead(GPIOB, DL_GPIO_PIN_17) == DL_GPIO_PIN_17) ? 1 : 0;
socTouchDisplay_U.ip_u32DisplayDuration_msec = 2000;
socTouchDisplay_U.ip_u32TouchDuration_msec = 100;
+ socTouchDisplay_U.ip_u32canId = g_u32CanId;
socTouchDisplay_step();
@@ -158,6 +160,10 @@ void vRTE_UARTDataProcess(void)
g_u16CanSpeed = (uint16_t)baudrate;
// xECU_CanReInit(CANFD0, g_u16CanSpeed);
}
+ else if (mode == 100)
+ {
+ g_u32CanId = baudrate;
+ }
vMCAL_DelayTicks(100);
vECU_InitiateUartToCanTransmit(&g_xUartHandle, 0x01, g_pu8Buf, 0);
}
@@ -186,7 +192,7 @@ void vRTE_CANDataProcess(void)
socTouchDisplay_U.Input[__gprv_u8Idx].Length = xBuff.length;
memcpy(&socTouchDisplay_U.Input[__gprv_u8Idx].Data[0], &xBuff.data[0], 8);
__gprv_u8Idx = (__gprv_u8Idx + 1) % MAX_CAN_MESSAGE_INSTANCE;
- if(l_u8TxBurstMessages < 24)
+ if(l_u8TxBurstMessages < 16)
l_u8TxBurstMessages++;
else
break;