LabViewXML.jl

Parse XML files created by LabVIEW
Author MLackner
Popularity
0 Stars
Updated Last
4 Years Ago
Started In
November 2020

Usage

In LabVIEW you can generate XML strings via the Flatten To XML VI. If we have an XML file generated by LabVIEW with the following content,

<Cluster>
    <Name></Name>
    <NumElts>2</NumElts>
    <I64>
        <Name>MyI64</Name>
        <Val>42</Val>
    </I64>
    <I8>
        <Name>MyI8</Name>
        <Val>4</Val>
    </I8>
</Cluster>

we can parse it with:

julia> import LabViewXML
julia> d = LabViewXML.readxml("/path/to/file.xml")
Dict{String,Any} with 2 entries:
  "MyI8"      => 4
  "MyI64"     => 42

The types will be parsed correctly:

julia> d["MyI8"] |> typeof
Int8

Clusters will be parsed as Dict.

Known Issues

The package was only tested with relatively simple XML files.

  • Only a limited number of LabVIEW types is supported at the moment.
  • The top level of the XML file has to be a <Cluster> element

Required Packages

Used By Packages

No packages found.