svghmi/default.svg
author Edouard Tisserant <edouard@beremiz.fr>
Thu, 05 Dec 2024 13:56:59 +0100
changeset 4060 d2f5eb3c7d6e
parent 3274 16066300b254
permissions -rw-r--r--
py_ext: fix CSV Writer

fix POU logic :
- SAVE is a BOOL
- invocation of py_eval on rising edge of SAVE
- remove save python argument

fix python:
- use no encoding for file open (python2)
- re-use detected dialect if any
- use no "rt+" and truncate since no need to re-sniff dialect for output file
- return "OK" instead of "#SUCCESS", preventing POU logic to ACK result
- support creating new line if writing just after last line
- support appending data on short rows

fix example:
- use a HMI:Button to trigger CSV write instead of HMI:Input +1
- reload CSVs on on each new CSV opened in file browser
- add display of CSV write output
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     1
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     2
<!-- Created with Inkscape (http://www.inkscape.org/) -->
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     3
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     4
<svg
3274
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
     5
   xmlns:osb="http://www.openswatchbook.org/uri/2009/osb"
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     6
   xmlns:dc="http://purl.org/dc/elements/1.1/"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     7
   xmlns:cc="http://creativecommons.org/ns#"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     8
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
     9
   xmlns:svg="http://www.w3.org/2000/svg"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    10
   xmlns="http://www.w3.org/2000/svg"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    11
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    12
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
3274
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    13
   inkscape:version="0.92.5 (2060ec1f9f, 2020-04-08)"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    14
   sodipodi:docname="default.svg"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    15
   id="hmi0"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    16
   version="1.1"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    17
   viewBox="0 0 1280 720"
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    18
   height="720"
3274
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    19
   width="1280">
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    20
  <rect
3274
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    21
     inkscape:label="HMI:Page:Home"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    22
     y="0"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    23
     x="0"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    24
     height="720"
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    25
     width="1280"
3274
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    26
     id="rect1016"
16066300b254 SVGHMI: default library path, default page when starting a SVGHMI project, error page when no SVG present
Edouard Tisserant
parents: 2750
diff changeset
    27
     style="color:#000000;opacity:1;fill:#d6d6d6;fill-opacity:1" />
2750
2694170cd88e intermediate commit, work in progress
Edouard Tisserant
parents:
diff changeset
    28
</svg>