Skip to content

Commit ebd06d2

Browse files
Version 1.0.1
# Version 1.0.1 ## Bugfix - Saving and loading data to/from persistent data module did not work --------- Co-authored-by: Roy Gollub <roy.gollub@sick.de>
1 parent bd8f05f commit ebd06d2

6 files changed

Lines changed: 23 additions & 14 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22
All notable changes to this project will be documented in this file.
33

4+
## Release 1.0.1
5+
6+
### Bugfix
7+
- Saving and loading data to/from persistent data module did not work
8+
49
## Release 1.0.0
510
- Initial commit

CSK_Module_IODDInterpreter/project.mf.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,7 @@ Module can provide chunks of IODD file in JSON format to describe some datapoint
361361
</serves>
362362
</crown>
363363
<meta key="author">SICK AG</meta>
364-
<meta key="version">1.0.0</meta>
364+
<meta key="version">1.0.1</meta>
365365
<meta key="priority">low</meta>
366366
<meta key="copy-protected">false</meta>
367367
<meta key="read-protected">false</meta>

CSK_Module_IODDInterpreter/scripts/CSK_Module_IODDInterpreter.lua

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,9 @@ local function main()
6262
CSK_IODDInterpreter.addInstance()
6363
6464
CSK_IODDInterpreter.addIODDFile('public/IODD.xml')
65-
local success, ioddName = CSK_IODDInterpreter.findIODDMatchingProductName('Productname')
66-
local success, ioddName = CSK_IODDInterpreter.findIODDMatchingVendorIdDeviceIdVersion('VendorID', 'DeviceID', 'Version')
67-
if success then
65+
local success1, ioddName1 = CSK_IODDInterpreter.findIODDMatchingProductName('Productname')
66+
local success2, ioddName2 = CSK_IODDInterpreter.findIODDMatchingVendorIdDeviceIdVersion('VendorID', 'DeviceID', 'Version')
67+
if success1 and success1 then
6868
CSK_IODDInterpreter.setSelectedIODD(ioddName)
6969
-- Optional process data structure
7070
local processDataStructure = CSK_IODDInterpreter.getProcessDataConditionList()

CSK_Module_IODDInterpreter/scripts/Sensors/IODDInterpreter/IODDInterpreter_Controller.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,7 @@ Script.serveFunction("CSK_IODDInterpreter.setParameterName", setParameterName)
711711

712712
local function sendParameters()
713713
if ioddInterpreter_Model.persistentModuleAvailable then
714-
CSK_PersistentData.addParameter(ioddInterpreter_Model.ioddInterpreter_Model.helperFuncs.convertTable2Container(ioddInterpreter_Model.parameters), ioddInterpreter_Model.parametersName)
714+
CSK_PersistentData.addParameter(ioddInterpreter_Model.helperFuncs.convertTable2Container(ioddInterpreter_Model.parameters), ioddInterpreter_Model.parametersName)
715715
CSK_PersistentData.setModuleParameterName(nameOfModule, ioddInterpreter_Model.parametersName, ioddInterpreter_Model.parameterLoadOnReboot)
716716
_G.logger:info(nameOfModule .. ": Send IODDInterpreter parameters with name '" .. ioddInterpreter_Model.parametersName .. "' to CSK_PersistentData module.")
717717
CSK_PersistentData.saveData()
@@ -726,7 +726,7 @@ local function loadParameters()
726726
local data = CSK_PersistentData.getParameter(ioddInterpreter_Model.parametersName)
727727
if data then
728728
_G.logger:info(nameOfModule .. ": Loaded parameters from CSK_PersistentData module.")
729-
local parameterSet = ioddInterpreter_Model.ioddInterpreter_Model.helperFuncs.convertContainer2Table(data)
729+
local parameterSet = ioddInterpreter_Model.helperFuncs.convertContainer2Table(data)
730730
for instanceId, instanceInfo in pairs(parameterSet.instances) do
731731
ioddInterpreter_Model.parameters.instances[instanceId] = {}
732732
ioddInterpreter_Model.loadIODD(instanceId, instanceInfo.ioddName)

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ Following CSK modules are mostly necessary to make use of the features of this m
4242
|Device|Firmware version|Module version|
4343
|--|--|--|
4444
|SIM1012|v2.3.0|v1.0.0|
45+
|SIM1012|v2.3.0|v1.0.1|
46+
|SIM1012|v2.4.1|v1.0.0|
47+
|SIM1012|v2.4.1|v1.0.1|
48+
4549

4650
This application / module is part of the SICK AppSpace Coding Starter Kit developing approach.
4751
It is programmed in an object-oriented way. Some of the modules use kind of "classes" in Lua to make it possible to reuse code / classes in other projects.

docu/CSK_Module_IODDInterpreter.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<meta name="viewport" content="width=device-width, initial-scale=1.0">
77
<meta name="generator" content="Asciidoctor 2.0.12">
88
<meta name="author" content="SICK AG">
9-
<title>Documentation - CSK_Module_IODDInterpreter 1.0.0</title>
9+
<title>Documentation - CSK_Module_IODDInterpreter 1.0.1</title>
1010
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
1111
<style>
1212
/* Stylesheet for CodeRay to match GitHub theme | MIT License | http://foundation.zurb.com */
@@ -615,11 +615,11 @@
615615
</head>
616616
<body class="article toc2 toc-left">
617617
<div id="header">
618-
<h1>Documentation - CSK_Module_IODDInterpreter 1.0.0</h1>
618+
<h1>Documentation - CSK_Module_IODDInterpreter 1.0.1</h1>
619619
<div class="details">
620620
<span id="author" class="author">SICK AG</span><br>
621-
<span id="revnumber">version 1.0.0,</span>
622-
<span id="revdate">2024-01-25</span>
621+
<span id="revnumber">version 1.0.1,</span>
622+
<span id="revdate">2024-02-13</span>
623623
</div>
624624
<div id="toc" class="toc2">
625625
<div id="toctitle">Table of Contents</div>
@@ -735,11 +735,11 @@ <h2 id="_document_metadata">Document metadata</h2>
735735
</tr>
736736
<tr>
737737
<th class="tableblock halign-left valign-top"><p class="tableblock">Version</p></th>
738-
<td class="tableblock halign-left valign-top"><p class="tableblock">1.0.0</p></td>
738+
<td class="tableblock halign-left valign-top"><p class="tableblock">1.0.1</p></td>
739739
</tr>
740740
<tr>
741741
<th class="tableblock halign-left valign-top"><p class="tableblock">Date</p></th>
742-
<td class="tableblock halign-left valign-top"><p class="tableblock">2024-01-25</p></td>
742+
<td class="tableblock halign-left valign-top"><p class="tableblock">2024-02-13</p></td>
743743
</tr>
744744
<tr>
745745
<th class="tableblock halign-left valign-top"><p class="tableblock">Author</p></th>
@@ -4307,8 +4307,8 @@ <h4 id="_short_description_69">Short description</h4>
43074307
</div>
43084308
<div id="footer">
43094309
<div id="footer-text">
4310-
Version 1.0.0<br>
4311-
Last updated 2024-01-25 08:40:51 +0100
4310+
Version 1.0.1<br>
4311+
Last updated 2024-02-13 16:06:06 +0100
43124312
</div>
43134313
</div>
43144314
<script type="text/javascript">

0 commit comments

Comments
 (0)