Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • E escet
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare
    • Locked Files
  • Issues 92
    • Issues 92
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
  • Merge requests 5
    • Merge requests 5
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Releases
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Eclipse ProjectsEclipse Projects
  • Eclipse ESCET (Supervisory Control Engineering Toolkit)
  • escet
  • Issues
  • #75
Closed
Open
Issue created May 03, 2021 by Ferdie Reijnen@freijnenDeveloper

Creation of PlcTask from PLCOpen XML fails in TwinCAT

When importing a PLCOpen XML file in TwinCAT that is generated with the PLC code generator, TwinCAT fails.

Severity	Code	Description	Project	File	Line	Suppression State
Error		Creation of object 'PlcTask' failed.
Reason: The string 't#10ms' is not a valid TimeSpan value.			0	

All other files (GVL's, POU's, and DUT's) are imported correctly.

I also tried importing the XML file in CODESYS, but I could not get that to work for the PlcTask object.

We can obtain inspiration from what ESCET generates:

<task interval="t#10ms" name="PlcTask" priority="20">
  <pouInstance name="MAIN" typeName="MAIN"/>
</task>

versus TwinCAT:

<task name="PlcTask" interval="PT0S" priority="20">
  <pouInstance name="MAIN" typeName="">
    <documentation>
      <xhtml xmlns="http://www.w3.org/1999/xhtml" />
    </documentation>
  </pouInstance>
  <addData>
    <data name="http://www.3s-software.com/plcopenxml/tasksettings" handleUnknown="implementation">
      <TaskSettings KindOfTask="Cyclic" Interval="10000" IntervalUnit="us">
        <Watchdog Enabled="false" TimeUnit="ms" />
      </TaskSettings>
    </data>
    <data name="http://www.3s-software.com/plcopenxml/objectid" handleUnknown="discard">
      <ObjectId>a0704795-6c85-4284-a1d2-39a3c7febdd7</ObjectId>
    </data>
  </addData>
</task>

Official specification can be found here: https://plcopen.org/technical-activities/xml-exchange

Edited May 03, 2021 by Dennis Hendriks
Assignee
Assign to
Time tracking

Copyright © Eclipse Foundation, Inc. All Rights Reserved.     Privacy Policy | Terms of Use | Copyright Agent